php example uapi?
Hello.
I am new and trying to use the uapi php functionality to create email filters. The examples given in the documentation uapi(
'Email', 'store_filter',
array(
'filtername' => 'coffee',
'account' => 'name@thedomain.com',
'action1' => 'deliver',
'dest1' => 'anothername@thedomain.com',
'part1' => '$header_subject:',
'match1' => 'contains',
'val1' => 'curds',
'opt1' => 'or',
'part2' => '$message_body',
'match2' => 'is',
'val2' => 'whey',
)
);
?>
-
If you are going to be doing this from the command-line, why not just use the /usr/local/cpanel/bin/uapi binary? 0 -
You raise an option which I have tried and the binary on the command line works, but I need to pass variables set by administrator to the binary, so I figured a php script will do that. Also, I've tried calling the binary from a bash script and can't get that to work either. Any options viable for passing variables I'll consider. Thank you! 0 -
Also, I've tried calling the binary from a bash script and can't get that to work either.
Hello, Could you let us know the specific command you used? Did you utilize URI-encode values? Thank you.0
Please sign in to leave a comment.
Comments
3 comments