Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2

Thread: Blur

  1. #1
    New Coder
    Join Date
    May 2011
    Posts
    10
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Blur

    Not sure were to post this or if ill get any love, but here it goes,

    I need help, i need alot, i have a site, its smarty, php, and mysql backed,

    i need to know how on earth i use ajax or javascript or whatever to do the following.

    When i type a username' into the field, once i click off it, i believe onblur is to be used? it will check the database and place text next to it saying hey that username is taken! if it is? anyone give a brother a hand?

  • #2
    Senior Coder
    Join Date
    Feb 2011
    Location
    Your Monitor
    Posts
    4,338
    Thanks
    60
    Thanked 527 Times in 514 Posts
    Blog Entries
    4
    Well basically you write your php script to do its checks and then output available or taken. Thats pretty simple as its like any other php script.

    It's the javascript that is a tad more tricky as you have to get it working in all browsers etc. IF you google AJAX you'll find a heap of examples.
    See my new CodingForums Blog: http://www.codingforums.com/blogs/tangoforce/

    Many useful explanations and tips including: Cannot modify headers - already sent, The IE if (isset($_POST['submit'])) bug explained, unexpected T_CONSTANT_ENCAPSED_STRING, debugging tips and much more!


  •  

    Posting Permissions

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