Welcome Guest, Not a member yet? Register   Sign In
Form not submitting data
#1

(This post was last modified: 09-05-2018, 12:54 PM by majortom84.)

I have this working in another Controller so I am not sure why it is not working in this one.

Controller:
Code:
public function contact(){

        if( empty( $this->input->post() ) ){
            $this->data['title'] .= ' - Contact';
            
            $this->load->view('templates-portfolio/header', $this->data);
            $this->load->view('portfolio/contact');
            $this->load->view('templates-portfolio/footer');
        }
        else{
            var_dump( $this->input->post() ); die();
        }
        
    } // end function contact

View:
Code:
<div class="container-contact">
            <?php echo form_open('portfolio/contact'); ?> <!-- the action is the controller media and the function process -->
    
            <div class="grid-container">
                <div class="grid-x grid-padding-x">
                    
                    <div class="large-12 cell">
                        <label>
                            Hello, Tell me a bit about yourself.
                            <textarea autofocus placeholder="" rows="5"></textarea>
                        </label>
                    </div>
                    
                    <div class="medium-6 large-6 cell">
                        <label>Name
                            <input type="text" placeholder="Name">
                        </label>
                    </div>
    
                    <div class="medium-6 large-6 cell">
                        <label>Email
                            <input type="email" placeholder="Email">
                        </label>
                    </div>
                    
                    <button type="submit" class="hollow button submit">Submit</button>
                    
                </div>
            </div>
    
            <?php echo form_close(); ?>

Testing in postman works, just not seeing anything in CI on backend
Reply


Messages In This Thread
Form not submitting data - by majortom84 - 09-05-2018, 12:51 PM
RE: Form not submitting data - by kierownik - 09-05-2018, 04:22 PM
RE: Form not submitting data - by majortom84 - 09-06-2018, 06:36 AM
RE: Form not submitting data - by php_rocs - 09-05-2018, 04:23 PM
RE: Form not submitting data - by neuron - 09-05-2018, 11:06 PM
RE: Form not submitting data - by neuron - 09-05-2018, 10:58 PM
RE: Form not submitting data - by Wouter60 - 09-06-2018, 02:48 AM
RE: Form not submitting data - by InsiteFX - 09-06-2018, 09:13 AM



Theme © iAndrew 2016 - Forum software by © MyBB