CodeIgniter Forums
Form in CI: POST and GET - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20)
+--- Forum: Archived General Discussion (https://forum.codeigniter.com/forumdisplay.php?fid=21)
+--- Thread: Form in CI: POST and GET (/showthread.php?tid=20340)

Pages: 1 2


Form in CI: POST and GET - El Forum - 07-07-2009

[eluser]Phil Sturgeon[/eluser]
Accept URI segments AND post variables. When you post to the form use POST and as you are accepting links such as /search/queryterm then people can still make Firefox search plugins etc.

Code:
$query = $this->input->post('q') ? $this->input->post('q') : $this->uri->segment(3, '');



Form in CI: POST and GET - El Forum - 01-12-2010

[eluser]viisik[/eluser]
[quote author="cold_fusion" date="1246936349"]Im rebuilding my site using CI and sooner or later i will have to rebuild basic search form current live site (link in my signature) shows you how that looks. only 2 fields:
category and city. if i use GET, i will end up having "?company=Something&city=Somecity"
and im not using querystrings in my CI development

i want my form after submitting to get me somewhere like this:
"mysite.com/index.php/show/company/city" how do i accomplish that?
is using POST solution? if i wasnt clear enough, just ask and i'll try to be more specific!
thanks in advance[/quote]

How to you manage banners on your site - have you integrated some banner management system with your site - like OpenX or others


Form in CI: POST and GET - El Forum - 01-12-2010

[eluser]developer10[/eluser]
[quote author="viisik" date="1263334611"][quote author="cold_fusion" date="1246936349"]Im rebuilding my site using CI and sooner or later i will have to rebuild basic search form current live site (link in my signature) shows you how that looks. only 2 fields:
category and city. if i use GET, i will end up having "?company=Something&city=Somecity"
and im not using querystrings in my CI development

i want my form after submitting to get me somewhere like this:
"mysite.com/index.php/show/company/city" how do i accomplish that?
is using POST solution? if i wasnt clear enough, just ask and i'll try to be more specific!
thanks in advance[/quote]

How to you manage banners on your site - have you integrated some banner management system with your site - like OpenX or others[/quote]

currently i have no banner management system. by the way, if you're talking about the site in my signature, it is not CI driven yet, im working
on it.