This should be simple but Simple left the building.

Discussion in 'Javascript' started by ft310, Jun 29, 2008.

  1. ft310

    ft310 Guest

    Te whole point is to provide the User a disclaimer and it they except
    to continue on with the original (?) format.

    The 'calling' web page generates something like "http://rhodeisland-
    aa.org/tester/meetings/disclaima.htm?mtgnum=35" This indicates the
    test system is being used 'tester' and the individual meeting is #35.
    The output generated by this web page is the User clicks "Continue" is
    "http://rhodeisland-aa.org/tester/meetings/geo_md.htm?mtgnum=35" This
    output is not happening -- in fact in most cases the 404 error page is
    called.

    The script follows
    <body onload="onopen ;">
    <table class="inwin">
    <tr>
    <td colspan="2" width="240px">
    TESTING<br>
    <b>You are leaving an area over which RhodeIsland-AA.org has
    total content control and entering
    a web page which may have content over which we have limited
    control.</b>
    TESTING<br>
    </td>
    </tr>
    <tr>
    <td class="inwinopt" width="120px" align="center">

    <form method='POST' action='' name='gonogo'>
    <input type='submit' value='Continue' name='Continue'
    style='width: 90; height: 50; FONT-FAMILY: Arial; color : blue ; FONT-
    SIZE: 12pt; FONT-WEIGHT: bold'>
    <input type='hidden' name='mtgnum' size="4" value='0'>
    </form>
    </td>
    <td class='inwinopt' width='120px' align='center'>
    <a id='CanAnchor' href='#' onClick='retreat() ;'>Cancel</a>
    </td>
    </tr>
    </table>

    <script type="text/javascript">
    function onopen()
    {
    var forwardpath = self.location.href ;
    document.gonogo.action = forwardpath.substring(0,
    forwardpath.indexOf('disclaima.htm')) + 'geo_md.htm' +
    forwardpath.substring(forwardpath.indexOf('?')) ;
    alert (forwardpath.substring(0,
    forwardpath.indexOf('disclaima.htm')) + 'geo_md.htm' +
    forwardpath.substring(forwardpath.indexOf('?'))) ;
    document.gonogo.mtgnum.value =
    forwardpath.substring(forwardpath.indexOf('=') + 1) ;
    alert (document.gonogo.action + ' ' +
    document.gonogo.mtgnum.value) ;
    return true ;
    }
    </script>


    </body>

    </html>

    I am out of ideas and will appreciate some. In the meantime, thanks
    for your time.
    ft310, Jun 29, 2008
    #1
    1. Advertising

  2. ft310

    Evertjan. Guest

    ft310 wrote on 29 jun 2008 in comp.lang.javascript:

    > Te whole point is to provide the User a disclaimer and it they except
    > to continue on with the original (?) format.


    ['format'?]

    Better do this with serverside scripting,
    but if you do this clientside,
    no need to call a seperate page.

    ==============================
    <head>
    <script type='text/javascript'>
    function ok(d){
    d.parentNode.style.display='none';
    document.getElementById('m').style.display='block';
    };
    </script>
    </head>

    <body>
    <div id='disclaimer'>
    DISCLAIMER<br><br>
    Blah<br><br>
    <button onclick='ok(this)'>Click me if you agree</button>
    </div>
    <div id ='m' style='display:none;'>
    Main page<br><br>
    Main page<br><br>
    Main page<br><br>
    Main page<br><br>
    Main page<br><br>
    </div>
    ==============================


    --
    Evertjan.
    The Netherlands.
    (Please change the x'es to dots in my emailaddress)
    Evertjan., Jun 29, 2008
    #2
    1. Advertising

  3. ft310

    SAM Guest

    ft310 a écrit :
    > Te whole point is to provide the User a disclaimer and it they except
    > to continue on with the original (?) format.
    >
    > The 'calling' web page generates something like "http://rhodeisland-
    > aa.org/tester/meetings/disclaima.htm?mtgnum=35" This indicates the
    > test system is being used 'tester' and the individual meeting is #35.
    > The output generated by this web page is the User clicks "Continue" is
    > "http://rhodeisland-aa.org/tester/meetings/geo_md.htm?mtgnum=35" This
    > output is not happening -- in fact in most cases the 404 error page is
    > called.



    <html>
    <body onload="onopen();">
    <table class="inwin">
    <tr>
    <td colspan="2" width="240px">
    TESTING<br>
    <b>You are leaving an area over which RhodeIsland-AA.org has
    total content control and entering a web page which may
    have content over which we have limited control.</b>
    TESTING<br>
    </td>
    </tr>
    <tr>
    <td class="inwinopt" width="120px" align="center">

    <form method='POST' action='' name='gonogo'>
    <input type='submit' value='Continue' name='Continue'
    style='width: 90px; height: 50px;
    font: Arial 12px bold; color: blue'>
    <input type='hidden' name='mtgnum' value='0'>
    </form>
    </td>
    <td class='inwinopt' width='120px' align='center'>
    <a id='CanAnchor' href='#' onclick='retreat() ;'>Cancel</a>
    </td>
    </tr>
    </table>

    <script type="text/javascript">
    function onopen()
    {
    var forwardurl = self.location.toString(),
    forwardpath = forwardurl.substring(0,
    forwardurl.lastIndexOf('/')+1),
    forwardfollow = forwardurl.split('=')[1];
    document.gonogo.mtgnum.value = forwardfollow;
    document.gonogo.action = forwardpath + 'geo_md.htm';

    alert ('action = ' +document.gonogo.action +
    '\ntgnum = ' + document.gonogo.mtgnum.value) ;
    }

    /********** variante **********/
    function onOpen() {
    var forwardurl = self.location.toString(),
    forwardfile = forwardurl.split('?')[0],
    forwardfollow = forwardurl.split('=')[1];
    forwardfile = forwardfile.replace('disclaima','geo_md');
    document.gonogo.mtgnum.value = forwardfollow;
    document.gonogo.action = forwardfile;

    alert ('action = ' +document.gonogo.action +
    '\ntgnum = ' + document.gonogo.mtgnum.value) ;
    }
    </script>
    </body>
    </html>


    --
    sm
    SAM, Jun 29, 2008
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. news.frontiernet.net
    Replies:
    2
    Views:
    409
    news.frontiernet.net
    Apr 16, 2004
  2. =?iso-8859-1?q?Jean-Fran=E7ois_Michaud?=

    Help on table align on left of page vs left hanging indent

    =?iso-8859-1?q?Jean-Fran=E7ois_Michaud?=, Jul 10, 2007, in forum: XML
    Replies:
    2
    Views:
    977
    =?iso-8859-1?q?Jean-Fran=E7ois_Michaud?=
    Jul 16, 2007
  3. pc
    Replies:
    2
    Views:
    1,281
    crisgoogle
    Jun 8, 2011
  4. lawrence
    Replies:
    13
    Views:
    280
    Thomas 'PointedEars' Lahn
    Sep 4, 2004
  5. Bob
    Replies:
    9
    Views:
    120
    Anno Siegel
    Feb 9, 2005
Loading...

Share This Page