Hi,
Don't let you fool by the title and answer something like forward(REFERER), there is something more ;).
Here is the problem:
So does someone have a better idea than saving that object and forwarding to the edit.php file?
I've tried with saving the data in a stdclass and then doing the usual elgg_view, page_draw but it doesn't want to do that, it's sending me to the homepage.
Thanks for your explanation because I'm tired to look through the search function and through search engines.
Vic
info@elgg.org
Security issues should be reported to security@elgg.org!
©2014 the Elgg Foundation
Elgg is a registered trademark of Thematic Networks.
Cover image by RaĆ¼l Utrera is used under Creative Commons license.
Icons by Flaticon and FontAwesome.
- Matt Beckett@Beck24
Matt Beckett - 0 likes
- Vinciane Amorini@Vicrabb
Vinciane Amorini - 0 likes
You must log in to post replies.In 1.8 there is a built in system for it called "Sticky Forms"
Info on that can be found here: http://blog.elgg.org/pg/blog/cash/read/169/elgg-18-sticky-forms
For 1.7 there's nothing standard, but it's very easy to do using session variables.
In your action where you're processing the inputs, set them as session variables like this:
This way you can do your sanity checks, and if anything fails send them back with
and the session will keep the data.
If the data all passes, at the end of your action before sending them away you just unset the session variable (just the part you set, not the entire session!!!)
On your form you will have inputs, before calling the view (if using views to generate the inputs) or displaying the html determine what the default value will be:
I hope that helps.
Thanks, I'll try that solution I'm wondering why I didn't think about the sessions but it's probably because when I learned PHP, the guy never spoke about them.