CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums
Results 1 to 2 of 2

Thread: get and set values to html controls via

  1. #1
    Join Date
    Oct 2007

    get and set values to html controls via

    Hi all,

    I have an application in (in localhost) which fetches html and php code from the login page from The body part goes like this:

    <div id="book">
    <div id="sidebar"><a href="" class="go_home"> </a><div id="sidebar_content"><script type="text/javascript">
    function quicklogin() {  document.cookie = "test_cookie=1;";}</script>
    <div id="squicklogin">
    <form method="post" name="loginform" action="" onsubmit="quicklogin();"><input type="hidden" name="challenge" value="a677af57d3b86876454bdefb6a4c7012" />
    <input type="hidden" name="md5pass" />
    <label><span>Email:</span><input type="text" class="inputtext" name="email" value="" id="email" size="20" onkeypress="login_form_change()" /></label><input type="hidden" name="noerror" value="1" />
    <label><span>Password:</span><input class="inputtext" type="password" name="pass" id="pass" size="20" /></label>
    Its in text/html format. I want to pass hard-coded values to "email" and "pass" fields during runtime. Is it possible?

    Thanks in advance
    Last edited by PeejAvery; October 29th, 2007 at 06:38 AM. Reason: Added code tags

  2. #2
    PeejAvery's Avatar
    PeejAvery is offline Super Moderator Power Poster
    Join Date
    May 2002

    Re: get and set values to html controls via

    You can write it from the server using Response.Write().

    <input type="text" class="inputtext" name="email" value="<% Response.Write(...) %>" id="email" size="20" onkeypress="login_form_change()" />
    If the post was helpful...Rate it! Remember to use [code] or [php] tags.

Posting Permissions

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

Windows Mobile Development Center

Click Here to Expand Forum to Full Width

On-Demand Webinars (sponsored)