Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
Exclude the php tags. You're creating fatal erroring PHP by doing that. Ensure debug mode is enabled and maximum error reporting is set within Joomla global configuration during your tests otherwise you'll never know if your code is erroring or not. Enabling debug mode will also allow echo output during redirects as CB has built in functionality to pause a redirect to output the buffer.I also tried putting the following code in a test Auto Action to see the results on a test table I setup within the Joomla database:
Yes, it works but you need to understand how eval works. It takes a string and treats it like PHP. It's not the same as just writing PHP in a PHP file and letting PHP run it. Some hosts flat out have eval disabled as well. I always recommend create_function over eval, but eval is provided as create_function sometimes isn't an option.I know that I could use the Query Type rather than Code - PHP eval but I am questioning whether the PHP eval feature works.
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
You don't need to do anything special to use create_function, it's just another Method in the dropdown. It isolates your code from the surrounding code. eval doesn't, which is why you're having this issue as detailed above.BTW, if I knew how to accomplish this Auto Action using the PHP create function and then accessing my script through that, I would happily do it. Unfortunately I am self taught and my knowledge only goes so far.
Please Log in or Create an account to join the conversation.