We use cookies to improve your experience. No personal information is gathered and we don't serve ads. Cookies Policy.

ExpressionEngine Logo ExpressionEngine
Features Pricing Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University
Log In or Sign Up
Log In Sign Up
ExpressionEngine Logo
Features Pro new Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University Blog
  • Home
  • Forums

action versus page requests

Development and Programming

BlackHelix's avatar
BlackHelix
226 posts
17 years ago
BlackHelix's avatar BlackHelix

So I’m preparing to write a module, and I was looking through the EE control flow. If you submit a form, it appears that it is an action request. Which, of course, it what it should be, right?

So what is displayed after the action request is processed? Judging from the code, if it’s an action request…. the templating engine doesn’t run? Yet I’ve seen an action request show a template.

I’m sure I’m missing something crucial here, but what is the proper thing to do to take input from a form and continue on in your module?

       
Paul Burdick's avatar
Paul Burdick
480 posts
17 years ago
Paul Burdick's avatar Paul Burdick

Yes, modules should use an action request when submitting forms. Like every rule there are exceptions, but this is what we suggest.

When a form is submitted, for example the Comment form, typically there is a hidden value that points to where one should return via a redirect. And in certain cases, like a preview, we will use the contents of a template to output a page for an action request. I would suggest you look at mod.comment.php as it is a pretty straight forward usage of actions.

       

Reply

Sign In To Reply

ExpressionEngine Home Features Pro Contact Version Support
Learn Docs University Forums
Resources Support Add-Ons Partners Blog
Privacy Terms Trademark Use License

Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.