Note that there are some explanatory texts on larger screens.

plurals
  1. POCant get POST data in codeigniter controller
    primarykey
    data
    text
    <p>For some reason I cant seem to get to post data in a codeigniter controller. I broke it down to a very simple form to test it out, still no luck. If I use method="get" it works fine. Anyways, below is the form, the controller/function, and my .htaccess. Any help would be much appreciated. Also, I saw a few other similar questions on here, but none of them seemed to have an answer that worked for me.</p> <p>form:</p> <pre><code>&lt;form id="bundleOrderInfo" name="bundleOrderInfo" action="&lt;?php echo(base_url()); ?&gt;catalog/bundleSubmit" method="post"&gt; &lt;input type="text" name ="test" id="test" value="blahblah"&gt;&lt;/input&gt; &lt;input type="submit"&gt;&lt;/input&gt; &lt;/form&gt; </code></pre> <p>controller/function:</p> <pre><code> public function bundleSubmit() { $this-&gt;output-&gt;enable_profiler(); $this-&gt;load-&gt;model('catalog_model'); $data['availableCategories']=$this-&gt;catalog_model-&gt;getCategories(); $data['availableItems'] = $this-&gt;catalog_model-&gt;getByCategory($data['availableCategories']); $testing = $this-&gt;catalog_model-&gt;formData(); $this-&gt;load-&gt;view('templates/header'); $this-&gt;load-&gt;view('templates/menu',$data); print_r($_POST); } </code></pre> <p>.htaccess:</p> <pre><code>&lt;IfModule mod_rewrite.c&gt; RewriteEngine On RewriteBase / RewriteCond %{REQUEST_URI} ^system.* RewriteRule ^(.*)$ /ITPortal/index.php?/$1 [L] RewriteCond %{REQUEST_URI} ^application.* RewriteRule ^(.*)$ /index.php?/$1 [L] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule ^(.*)$ ITPortal/index.php?/$1 [L] &lt;/IfModule&gt; &lt;IfModule !mod_rewrite.c&gt; ErrorDocument 404 /ITPortal/index.php &lt;/IfModule&gt; </code></pre>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload