Ajax Talk - Asynchronous javascript and xml discussion board
 FAQ   Search    Usergroups      Register   Profile   Check your messages   Log in 
Signup now to enjoy a range of free membership advantages !!
Ajax Talk - Moderators Wanted

Post new topic   Reply to topic    Ajaxtalk.com Forum Index -> AJAX Help
View previous topic :: View next topic  
Author Message
New one
New one

Joined: 05 Jan 2008
Posts: 1

PostPosted: Sat Jan 05, 2008 3:43 am    Post subject: PHP JAVASCRIPT MYSQL FORM UPDATE Reply with quote

Hi I am a total nube with ajax (in fact just broke the ice with it today) I have created a link to mysql database and can view these records as well. I am trying to create a form that will edit the details that are displayed as well.

This will update when i hit the Update button but only the first line is this a common problem. Any help would be great.

Here is the html and function from my ajax app i can post more if it is useful.


while($row = mysql_fetch_array($result))
echo "<form name='meals".$row['ID']."'>";
echo "<input type='text' id='itemID' value='".$row['ID']."'/> ";
echo "<input type='text' id='mealName' value='". $row['mealName'] ."' /><input type='button' onClick='updateRequest();' value='Update' /> <a href='javascript:deleteRequest('".$row['ID']."');'>Delete</a>";
echo "<br/>";
echo "</form>";



function updateRequest() {
var url="update.php";
//xmlHttp.open('get', 'update.php?' + mealName + '&ID=' + ID);
var mealName = document.getElementById('mealName').value;
var ID = document.getElementById('itemID').value;



xmlHttp.onreadystatechange = handleResponse;

Thanks Sad
Back to top
View user's profile Send private message
Light Frequent Poster
Light Frequent Poster

Joined: 07 Sep 2007
Posts: 7

PostPosted: Tue Jan 08, 2008 5:24 pm    Post subject: Reply with quote

can you also post the update.php file?

This is where your SQL update should happen and it's key in this development.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Ajaxtalk.com Forum Index -> AJAX Help All times are GMT
Page 1 of 1

Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
 XML & Copyright Notice 

Powered by phpBB © 2001, 2005 phpBB Group

What is according to Wikipedia: Ajax Web2.0 XML E4X

Link to our site:


del.icio.us digg spurl wists simpy newsvine blinklist furl blogmarks yahoo! myweb smarking ma.gnolia segnalo reddit fark technorati cosmos

Normal Bookmark

Partner Button Links:
Codecrunch.com: Webmaster Tutorials    One Ajax

Partner Text Links:
quomon | web20log | ajaxmatters | tableless | 456bereastreet | music charts | gift ideas | competitions | free xbox 360 | link trade ?

it consultancy & project management lead generation zoekmachine optimalisatie steal these buttons seo expert