Jump to content

Recommended Posts

Trying to figure out how to do a dynamic update when the user changes the data on my web page's

form.  Pretty new to php here, but lots of experience with programming.

 

My web server host (1and1 hosting) provides mysql support, so with the database I've created, 1and1

requires I use PHP to access the mysql database.

 

But from what I understand,  any php code gets preprocessed and converted to html

before the page loads.  So if the user changes the input data on my form, how the

heck do I follow my web server host's requirement that I make php calls to send the new

user data dynamically to the mysql database? 

Link to comment
https://forums.phpfreaks.com/topic/233599-best-way-to-use-php-with-mysql/
Share on other sites

Okay, I forgot the most important part, this is written in Javascript, ie.

I'm using javascript for the user-input form on my web page.

 

I have read about using php to access the mysql database and have

successfully embedded php code withing the php script tags <?php

and ?> in my javascript -- but when nothing happened it became clear that all php

runs before the page loads.

 

So here I am needing to read/write to my MySQL database from

my Javascript code, and 1and1 is telling "you have to use php

to access the database."

 

So what am I missing?  Is there something about javascript (and

using php) that allows dynamic mysql database calls?

  • 4 weeks later...
This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.