php coding for inserting into a db from an html form

I am currently trying to learn how to write php scripts and I am having a problem. I have written the html code for a form to gather input. My next step was to write the php code to access and insert into the db and named it “insert.php”. When I click on the submit button on the form I get a response back from the computer like “Would you like to save insert.php or open it?” Is there someone who can tell me why I am getting this crazy message?

I really appreciate any help I can get.

because browsers don’t know what to do with php pages without php being installed first. If you’re working on this on your own pc, then i’d suggest downloading and installing WAMP or XAMP, both create local webservers with php, phpmyadmin and MySQL, and wamp comes with any number of plugins depending on what you’re doing. xamp might have them too, haven’t used it in a long time.

Sponsor our Newsletter | Privacy Policy | Terms of Service