catch previous url

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Ragni Srivastava
    New Member
    • Jul 2008
    • 3

    catch previous url

    Hi
    I want help on my project It has a table which visible on click and It has 2 button send, and cancle. Send button redirect second page and return with status "Y" in this ok after sending a message second table is visible which has Ok button. Now my Problem is that I want when button Ok is click url remove status "y" from IT.
    How Is it Possible??????? ???????????/
    Just to give example first url is
    www.xyz.com?pro dId=20&colorID= 30&size=20 after redirect it come like this
    www.xyz.com?pro dId=20&colorID= 30&size=20&Stat ys="Y"

    I want when I click Ok it catch first URl.
  • DrBunchman
    Recognized Expert Contributor
    • Jan 2008
    • 979

    #2
    You can't remove anything from the URL but you can redirect to the first URL which will have the same effect. Either use Javascript in the buttons onclick event or set the target of the form that contains the Ok button to the first URL.

    Dr B

    Comment

    • Ragni Srivastava
      New Member
      • Jul 2008
      • 3

      #3
      how to change in Url

      Hi
      I have a program which redirect same url with status ' Y '
      and display a message now my proble is That I want when user click Ok button it remove only 'Y' from Url For detail I give u a Example
      suppose I have tow page
      First page is like

      its action on other page

      and It show a table which visible a table which has a button Ok
      i want when use click button ok tabel visible property is hidden
      I use to call javascript function

      Code:
      function  divHid()
      {
      document.getElementById('div1').style.visibility='Hidden';
      }
      Its working Ok
      but I want to catch First page url also because url is still

      like this
      How to remove status=Y form URl or
      catch first page url that is


      Plz guide me
      u can mail me on my mail Id
      (e-Mail address removed by DrBunchman)
      Thanks and Redirect
      Ragni
      Last edited by DrBunchman; Oct 4 '08, 08:20 AM. Reason: Removed e-mail address and added code tags

      Comment

      • Ragni Srivastava
        New Member
        • Jul 2008
        • 3

        #4
        Originally posted by DrBunchman
        You can't remove anything from the URL but you can redirect to the first URL which will have the same effect. Either use Javascript in the buttons onclick event or set the target of the form that contains the Ok button to the first URL.

        Dr B
        thanks for reply but page is not redirect
        i use javascript code
        Code:
        function  divHid()
        {
        document.getElementById('div1').style.visibility='Hidden';
        //	myUrl="purchase/productdetail_EMail.asp?cgmain=" & mprimarycatId & "%26cgsub=" & msubcatId & "%26prodid=" & mprodId
        //alert(purchase/productdetail_EMail.asp?cgmain="& mprimarycatId & "%26cgsub=" & msubcatId & "%26prodid=" & mprodId);
        //document.getElementById('div1').action=("purchase/productdetail_EMail.asp?cgmain="& mprimarycatId & "%26cgsub=" & msubcatId & "%26prodid=" & mprodId);
        
        }
        all comented line I use but not redirect page
        I also use
        <%Response.Redi rect (myUrl)%>
        in Javascript function divHid()
        but button stop working how to redirect that page
        Last edited by DrBunchman; Oct 4 '08, 08:28 AM. Reason: Added [Code] Tags - Please use the '#' button

        Comment

        • DrBunchman
          Recognized Expert Contributor
          • Jan 2008
          • 979

          #5
          Ragni,

          Please don't double post your questions - it is against the rules laid out in the Posting Guidelines and I have merged your other thread on this topic with this one. Also please don't print your email address in your posts - it is for your own protection against spamming.

          You can use a javascript redirect in your function if you wish to change the URL of the page like this:

          Code:
          window.location.href="http://www.whatever.com/";
          However i'm not sure that is exactly what you want. Having the 'Y' in the querystring is triggering some kind of action on the page - is that correct? Why do you then want to remove it?

          Dr B

          Comment

          Working...