Results 1 to 5 of 5

Thread: popup input to sql?

  1. #1
    Join Date
    Apr 2010

    popup input to sql?

    Hi Guys.
    I need a javascript prompt popup which allows the user to input 1 line of text, when they submit it, it will update a sql table using php.

    The reason is for a user to decline a job, when they click 'reject job' it will popup and ask for a reason.
    The reason will be stored in mysql.

    Please help!
    Last edited by adamck; 02-14-2011 at 05:50 AM.

  2. #2
    Join Date
    Feb 2011

    Re:Popup input to SQL

    Yo can use prompt function. From it you can take the input and then update the database accordingly
    like that:
    prompt("Please enter your name","Your name");

  3. #3
    Join Date
    Apr 2010
    I can make the promp ok, and i can pull the variable using this tutorial

    how do i send the variable to php/sql without refreshing the page?
    This is the part im stuck with

    I want
    User presses button - popup requests a comment and presses ok - comment is then entered into sql table - user is back where he started.

  4. #4
    Join Date
    Jan 2006
    Indiana, USA
    The only way to do it without submitting the page is with AJAX techniques. Otherwise, you'll have to submit the page to send the data to the server.

  5. #5
    Join Date
    Apr 2010
    i am aware of this.
    I was hoping for some code example of this i could then try or play with?

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
HTML5 Development Center

Recent Articles