POST METHOD PROBLEM (If input http://,ftp://) |
[eluser]Unknown[/eluser]
After I input http:// in textfield or textarea. I can't echo that variable(show nothing). please kindly check code as below. It's work when i test on localhost . But when i test on external server It's not work. And when i tested without CI (only php) like below It's work also. Code: <form method="post" action="doTest.php"> doTest.php Code: <? environment:Codeigniter, Godaddy(php5.4 cpanel) Thank you in advance. This is my code in CI: Simple Code: Controller (Welcome) Code: public function test() View (test.php): Code: <form action='../welcome/doTest' method="post"> work List: aaaaa 'http://' (single quote added) htp :// not work: http:// http://www.example.com ftp:// sorry for poor english, Thank you in advance.
[eluser]InsiteFX[/eluser]
It's Controller/Method. Code: <form action='../welcome/doTest' method="post">
[eluser]Unknown[/eluser]
[quote author="InsiteFX" date="1407588668"]It's Controller/Method. Code: <form action='../welcome/doTest' method="post"> I try to use Code: <form action='welcome/doTest' method="post"> Actually, I tested Code: <form action='<?=base_url('welcome/doTest');?> method="post"> It will send to http://mydomain.com/welcome/doTest It's work if I use normal text like: aaa, text But if input protocol name like http://, ftp:// It's not work.
[eluser]Flemming[/eluser]
this seems like a similar problem to the one described here: https://ellislab.com/forums/viewthread/246197/ I think the issue could be with mod_security on your live server?
[eluser]InsiteFX[/eluser]
it may need the index.php to work switch base_url() with site_url() Code: <form action="<?php echo site_url('welcome/doTest'); ?>" method="post"> |
Welcome Guest, Not a member yet? Register Sign In |