Results 1 to 6 of 6

Thread: Popup box issue

  1. #1
    Join Date
    Nov 2011
    Posts
    4
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Popup box issue

    I decided to create a popup box for my ghost website so I can add those who want a bio on their page.

    I got the code from here.

    http://www.dynamicdrive.com/dynamicindex11/abox2.htm

    I am running a test page here:

    http://www.ghostchasersofpa.com/bio%20T.htm

    Click for Bio

    I disabled the auto load in the code on the generator as I want them to click on the bio button to popup up the box so everyone’s bio don’t just popup.

    Now here is the issue the script will not work unless I click compatibility mode then the box will pop up.

    But if I go to http://www.dynamicdrive.com/dynamicindex11/abox2.htm

    It will work without the compatibility mode when I click Show box again 1 or 2..

    I tried comparing what I have and what Dynamic Drive has by viewing the source code and most of the general HTML script looks correct.

    Any help would be appreciated!

    Thanks

  2. #2
    Join Date
    Oct 2009
    Posts
    845
    Thanks
    14
    Thanked 189 Times in 188 Posts

    Default

    The doctype declaration should be the first thing on the page, above the html and head tags, take a look here.
    Maybe it will work if you corrected that !

  3. #3
    Join Date
    Nov 2011
    Posts
    4
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    azoomer:

    I originally had it up there; it did not make a difference.

    I was trying to compare and try what Dynamic Drives source code was on this link

    http://www.dynamicdrive.com/dynamicindex11/abox2.htm as this page is working. View their Source Code.

    The only way I can get the webpage to work at home using I-E 8 is select Compatibility Mode.

    I go to work and they are using I-E 7 it still will not work.


    " BUT " if I access this link http://www.dynamicdrive.com/dynamicindex11/abox2.htm

    from home or work the Popups works with and with the buttons Show box again 1 or 2..

    and at home I do not have to enable Compatibility Mode to access the page to get it to work.

    “”””” This page http://www.dynamicdrive.com/dynamicindex11/abox2.htm Has to be using some type of scripting that I am not seeing in the code to allow other browser versions to work. I tried other scripts from other web sources and did not have any luck. “””””””””

    You can also try my test page I made from the instructions on http://www.dynamicdrive.com/dynamicindex11/abox2.htm .

    http://www.ghostchasersofpa.com/Test.htm

    FYI am using Frontpage in HTML mode to build the page.

    Thanks

  4. #4
    Join Date
    Oct 2009
    Posts
    845
    Thanks
    14
    Thanked 189 Times in 188 Posts

    Default

    to make your test page work, you would need to add some more (as explained on the demo page). see the highlighted below
    Code:
    <html><head>
    <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
    <title>Bio</title>
    <script language="JavaScript" src="Test_files/popup.js">
    //Popup box II (By Brian Gosselin at http://scriptasylum.com/bgaudiodr)
    //Modified slightly By Dynamic Drive
    //For full source, visit http://www.dynamicdrive.com
    </script>
    </head><body>
    <script>
    window.onload=function(){
    new popUp(100, 100, 300, 175, "Bio1", "Put all of your content text in here.<br><br>You can also place HTML code in here too, such as a picture: <img src=\"max.gif\">. Notice how a backslash must proceed every quotation (\") that appears in your HTML content.", "white", "black", "bold 10pt sans-serif", "Title Bar", "navy", "white", "#dddddd", "gray", "black", true, true, true, true, false);
    
    new popUp(500, 100, 300, 175, "Bio2", "Put all of your content text in here.<br><br>You can also place HTML code in here too, such as a picture: <img src=\"max.gif\">. Notice how a backslash must proceed every quotation (\") that appears in your HTML content.", "white", "black", "bold 10pt sans-serif", "Title Bar", "navy", "white", "#dddddd", "gray", "black", true, true, true, true, false);
    }
    </script>
    <p>
    <script type="text/javascript"></script>
    </p>
    <!--webbot bot="HTMLMarkup" endspan -->
    <p>&nbsp;</p>
    <p align="left"><strong></strong><a href="javascript:showbox('Bio1')">Bio</a> | <a href="javascript:showbox('Bio2')">Bio</a></p>
    </body></html>
    But in any case I would suggest you find another script that is more up to date. This script is 10 years old and could probably cause you some headaches in the long run.

  5. #5
    Join Date
    Nov 2011
    Posts
    4
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    azoomer:

    Ok now I am “"REALLY"“ scratching my head!

    First if I view source to http://www.ghostchasersofpa.com/Test.htm

    I show <script language=JavaScript src="http://www.ghostchasersofpa.com/popup.js">

    Above you pasted the source code with
    <script language="JavaScript" src="Test_files/popup.js">

    I do not have Test_files directory in my hosting so I clueless to where this came in.


    """" NOW """"I decided to make a another test page .

    This time I took the same 3 pieces The HEADER script **** The BODY script and The LINK buttons, " BUT " from the source code on the demo page of http://www.dynamicdrive.com/dynamicindex11/abox2.htm

    I called it http://www.ghostchasersofpa.com/Test1.htm

    Now it works.

    When I made the script on http://www.ghostchasersofpa.com/Test.htm and on http://www.ghostchasersofpa.com/bio 1.htm I used the generator on the demo page to give me the code.

    Now when I made http://www.ghostchasersofpa.com/Test1.htm I removed what I had between my body tags <body> </body> and copied what was on the source code of the demo page.

    Now the error that is on http://www.ghostchasersofpa.com/Test.htm says Line: 38 char: 1 error: object required. code: 0 http://www.ghostchasersofpa.com/Test.htm


    Hopefully between the two test pages

    http://www.ghostchasersofpa.com/Test.htm Not working
    and
    http://www.ghostchasersofpa.com/Test1.htm Working

    You can tell in the code what is messed up

    Only thing I changed was between the body tags.

  6. #6
    Join Date
    Nov 2011
    Posts
    4
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    OK,

    I think I have it solved.

    <script type="text/javascript">
    <!--window.onload=function(){
    new popUp(350, 200, 370, 175, "Bio1", "Test 1", "white", "black", "9pt sans-serif", "Example 2", "navy", "white", "#dddddd", "gray", "black", false, true, true, true, false);

    new popUp(10, 120, 250, 150, "Div1", "Test 2", "white", "#00385c", "14pt serif", "Example 1", "#00385c", "white", "lightgrey", "#00568c", "black", false, true, false, true, false);
    }
    // --></script>

    I took notice that the demo page had this code "<script type="text/javascript"> was before <!--window.onload=function(){

    It was not on my page so I added it to the other test pages and it worked.

    Go Fiqure. Now hope thiere is no other missing codes. LOL

Bookmarks

Posting Permissions

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