Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

Welcome to the new platform of Programmer's Heaven! We apologize for the inconvenience caused, if you visited us from a broken link of the previous version. The main reason to move to a new platform is to provide more effective and collaborative experience to you all. Please feel free to experience the new platform and use its exciting features. Contact us for any issue that you need to get clarified. We are more than happy to help you.

Pre Populating a HTML Form From the URL

Hi, This is my first post.

We are running a case management system and on one of our screens we link to a engineers site where there is a HTML form. We simply open this site using a URL.

My question is...Is there anyway to send information to a HTML form using the URL. For example "HTTP://www.myform.htm" (then put information you want to populate the form with here) I know how to do this using ASP but i just need to do it using standard HTML with a URL.

Thanks for any feedback,



Comments

  • zibadianzibadian Posts: 6,349Member
    : Hi, This is my first post.
    :
    : We are running a case management system and on one of our screens we link to a engineers site where there is a HTML form. We simply open this site using a URL.
    :
    : My question is...Is there anyway to send information to a HTML form using the URL. For example "HTTP://www.myform.htm" (then put information you want to populate the form with here) I know how to do this using ASP but i just need to do it using standard HTML with a URL.
    :
    : Thanks for any feedback,
    :
    :
    I don't think it is possible with only HTML, but you can use javascript for it. With the right script you can place the initial values using an URL query: http://www.mysite.com?username=someone&domain=private

  • mac_doggiemac_doggie Posts: 488Member
    : Hi, This is my first post.
    :
    : We are running a case management system and on one of our screens we link to a engineers site where there is a HTML form. We simply open this site using a URL.
    :
    : My question is...Is there anyway to send information to a HTML form using the URL. For example "HTTP://www.myform.htm" (then put information you want to populate the form with here) I know how to do this using ASP but i just need to do it using standard HTML with a URL.
    :
    : Thanks for any feedback,
    :
    :
    :
    :
    Try this...
    Put in the parameters ?name=MyName&email=MyEmail@server.com
    to your URL
    [code]

    var params = document.location.search.substr(1,document.location.search.length).split('&');
    var arguments = Array();
    for(var i=0;i<params.length;i++) {
    var arg = params[i].split("=");
    arguments[arg[0]] = arg[1];
    }
    alert(arguments['name']);
    alert(arguments['email']);
    [/code]

    ;-)
    -mac-
    mailto:mac_doggie@hotmail.com
    the Netherlands...


Sign In or Register to comment.