0

I have a plugin that loops through some code and builds an array of results then redirects the user to a results page. How can I pass the results to the redirected page without using the URL segment? The results can be converted to JSON if needed.

0

Parse those variables! Then just dump them out in template tags.

https://ellislab.com/expressionengine/user-guide/development/usage/template.html#parsing-variables

You use the template class to pass your variables through the EE template engine, then you can just make a loop out of your results in your template:

{exp:my_plugin parameterone="666"}
    A result:
    {result_array}
        {result_variable_one}
        {result_variable_two}
    {/result_array}
{/exp:my_plugin}
| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.