What is JotForm?
JotForm is a free online form builder which helps you create online forms without writing a single line of code. No sign-up required.

At JotForm, we want to make sure that you’re getting the online form builder help that you need. Our friendly customer support team is available 24/7.

We believe that if one user has a question, there could be more users who may have the same question. This is why many of our support forum threads are public and available to be searched and viewed. If you’d like help immediately, feel free to search for a similar question, or submit your question or concern.


  • Profile Image

    Check for username availability

    Asked by verex18 on January 08, 2013 at 12:01 AM

     Im using your form as a registration form.
     So i needed the form to check the username to prevent duplicate entries in my database before the user click the submit button.

    Basically like this.  

    http://www.bitrepository.com/demo/username-checker/

    I have been able to integrate it with my database but when I try to use your form to replace the  form in the tutorial. It just doesn't work. 

  • Profile Image
    JotForm Support

    Answered by Welvin on January 08, 2013 at 12:35 AM

    Hi,

    I am not quite sure if this is possible with some other scripting. Let me try to get my colleagues attention for possible workaround but I cannot promise your anything about this.

    Thanks

  • Profile Image

    Answered by verex18 on January 08, 2013 at 12:52 AM

    Thanks, I've search the net  about using the prototype library but nothing comes out.

  • Profile Image
    JotForm Support

    Answered by Welvin on January 08, 2013 at 01:09 AM

    Hi,

    How about this guides:

    http://benohead.com/check-username-availability-using-jquery-and-php/

    http://stackoverflow.com/questions/5839554/check-the-username-availability-and-update-the-fields-and-also-the-username-with

    http://www.codeforest.net/username-availability-check-using-php-and-jquery

     

    Thanks

  • Profile Image

    Answered by verex18 on January 08, 2013 at 02:04 AM

    I 've tried but somehow the form becomes dormant. There are no changes.  Is this because of the css of the form

  • Profile Image
    JotForm Support

    Answered by Welvin on January 08, 2013 at 02:36 AM

    Anyway, I have contacted my colleague about this. Hopefully, he will help us find a way to make this possible but again, I can't promise anything.

    Cheers!

  • Profile Image

    Answered by verex18 on January 08, 2013 at 02:55 AM

    Thanks for your help.

  • Profile Image
    JotForm Support

    Answered by liyam on January 08, 2013 at 09:43 AM

    Hello verex18.  Basically, this requires a database look-up for search. And unfortunately, this is a process that's quite impossible within JotForm.  

    But here's an alternative solution:  You will need to have your own website, or at least a (PHP/MySQL enabled) free hosting acccount.  If you don't have one yet, I can recommend you a few free webhosting sites such as Awardspace or 000webhost.com. With this, we'll have to host your form on your website, modify it to have a look-up so that if the username exists, it will not make a submission. Otherwise, it will submit.

    We can start by sharing with us here your form ID or the link to the form you're working on.  Then I can make a functional demo form out of it.

    We'll wait for your response.

    Thanks.

  • Profile Image

    Answered by verex18 on January 08, 2013 at 07:27 PM

    I've been able to  check my database for duplicate username using this tutorial.

    http://www.91weblessons.com/live-username-availability-check-with-ajax-and-php/

     

    But, trying to replace the textfield with your form doesn't seem to work.

    This is the form that Im using

    http://form.jotform.me/form/30068690273455? 

  • Profile Image
    JotForm Support

    Answered by jonathan on January 08, 2013 at 08:08 PM

    Thank you for the updates.

    Liyam will attend on your concern as soon as he can. Since it was already agreed that he will be assisting you on this, I guess its best to wait for his reply.

    Thanks.

  • Profile Image
    JotForm Support

    Answered by liyam on January 08, 2013 at 08:20 PM

    Thanks, Jonathan. 

    Thank you also, verex18, for sharing the link to the form. The issue that's happening is probably due to the conflict between Prototype and jQuery libraries (I'm sensing jquery on the code from the tutorial).

    You can make use of jquery's jQuery.noConflict(); function, doing something like this:

        var j = jQuery.noConflict();

    Then replace all $ signs on your jquery ajax code to j should fix it.

    I'll also work on a demo that uses the tutorial that you shared.  I'll get back to you on this.

  • Profile Image

    Answered by verex18 on January 08, 2013 at 08:34 PM

    Thanks, 

    I've tried using

    var j = jQuery.noConflict();

    and after tickering here and there. I think I've made it work

  • Profile Image

    Answered by jeanettebmz on January 08, 2013 at 08:49 PM

    I am very glad that Lyam's adviced helped you to accomplish what you were looking for!

    cheers!

  • Profile Image
    JotForm Support

    Answered by liyam on January 08, 2013 at 11:39 PM

    I guess there's no need for me to continue with a demo script.  :P

    So, just in case you get to encounter problems, just let us know.

    Thanks.