Title: PHP With Forms
Last modified: August 21, 2016

---

# PHP With Forms

 *  [casdrubo](https://wordpress.org/support/users/casdrubo/)
 * (@casdrubo)
 * [13 years, 1 month ago](https://wordpress.org/support/topic/php-with-forms/)
 * Good Morning,
 * I just installed your plugin and having it working fine with some sample code
   you provided.
 * I have very little/zero PHP experience so forgive me if I’m asking some pretty
   obvious questions.
 * I have some php code that will allow me to send my html form to a mysql database.
   In the html form I am referencing “gamesheet.php” and the php script is called“
   gamesheet.php”.
 * How can I make the html form execute using php code written with the “insert 
   php” plug-in?
 * **SAMPLE HTML Header:**
    <h2>Home Team</h2> <form action=”gamesheet.php” method
   =”POST”>Team Name:
 * [http://wordpress.org/extend/plugins/insert-php/](http://wordpress.org/extend/plugins/insert-php/)

Viewing 1 replies (of 1 total)

 *  [WillBontrager](https://wordpress.org/support/users/willbontrager/)
 * (@willbontrager)
 * [13 years, 1 month ago](https://wordpress.org/support/topic/php-with-forms/#post-3703486)
 * If I understand your question correctly, this is what you have:
 * ~ A form.
 * ~ A separate PHP script to process the form when it is submitted. The PHP script
   updates a MySQL database that is not the same database as WordPress uses.
 * My recommendation is to install the PHP script separately. Then put the form 
   on a WordPress post or page.
 * The form can then submit to the PHP script directly (the form tag’s action attribute
   value being the absolute URL to gamesheet.php, like [http://example.com/gamesheet.php](http://example.com/gamesheet.php)).
 * Then you won’t need to embed the script into a WordPress post or page. Less hassle
   🙂
 * Let me know if I didn’t understand your question.
 * Will

Viewing 1 replies (of 1 total)

The topic ‘PHP With Forms’ is closed to new replies.

 * ![](https://ps.w.org/insert-php/assets/icon-256x256.gif?rev=3523853)
 * [Woody Code Snippets – Insert PHP, CSS, JS, and Header/Footer Scripts](https://wordpress.org/plugins/insert-php/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/insert-php/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/insert-php/)
 * [Active Topics](https://wordpress.org/support/plugin/insert-php/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/insert-php/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/insert-php/reviews/)

 * 1 reply
 * 2 participants
 * Last reply from: [WillBontrager](https://wordpress.org/support/users/willbontrager/)
 * Last activity: [13 years, 1 month ago](https://wordpress.org/support/topic/php-with-forms/#post-3703486)
 * Status: not resolved