RedirectContent with $params?

Talk about writing modules and plugins for CMS Made Simple, or about specific core functionality. This board is for PHP programmers that are contributing to CMSMS not for site developers
Post Reply
Sonya

RedirectContent with $params?

Post by Sonya »

Hello,

is there any function to redirect to other page (like RedirectContent($id)) with parameters?

I need to redirect to another page and passing through $message variable into redirected template. Something like this:

Code: Select all

$this->RedirectContent($id, $params, $message);
I do need to redirect to another page and cannot just use ProcessTemplate() to avoid double submission of form. I need the complete reload of the page but with parameters.

Thank you,
Sonya
calguy1000
Support Guru
Support Guru
Posts: 8169
Joined: Tue Oct 19, 2004 6:44 pm
Location: Fernie British Columbia, Canada

Re: RedirectContent with $params?

Post by calguy1000 »

No, there isn't a method for that, you'll have to write one.

it isn't that hard though, you just have to build the URL and then call redirect()
Follow me on twitter
Please post system information from "Extensions >> System Information" (there is a bbcode option) on all posts asking for assistance.
--------------------
If you can't bother explaining your problem well, you shouldn't expect much in the way of assistance.
Sonya

Re: RedirectContent with $params?

Post by Sonya »

Hello calguy1000,

thank you for your answert.
calguy1000 wrote: it isn't that hard though, you just have to build the URL and then call redirect()
Do you mean redirect with GET-Paramter? I have to pass a message in cyrillic letters and it looks ugly if two or more sentences are url-encoded and sticked to url.  :-[
User avatar
duclet
Forum Members
Forum Members
Posts: 187
Joined: Fri Jun 23, 2006 12:55 pm

Re: RedirectContent with $params?

Post by duclet »

Here is an idea. Have a page that receives the data, store it to session and then redirect to whatever page that is the recipient. That page can get the data from the session and unset it when it is done. Obviously not the greatest of solutions since I can already think of a problem with it but it should be able to do the trick.
Post Reply

Return to “Developers Discussion”