SitePoint Sponsor

User Tag List

Results 1 to 4 of 4
  1. #1
    SitePoint Member
    Join Date
    Jun 2009
    Posts
    21
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    PopUp HTML Code problems in I.E.8

    OK-
    this code is working just fine on Firefox. this is what's suppose to happen:

    you go to the website, a pop-up comes up, you click the pop-up and another window opens up to register for site..

    see it here www . christiancouriernewspaper . com / popuptest.html (try in both firefox and internet explorer)

    here is my code...

    Code:
    <html>
    <head>
    <title>The Christian Courier - a ministry preserved in Christ</title>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
    <meta http-equiv="Refresh" content="10;URL=http://www.ChristianCourierNewspaper.com/blogbase">
    <style type="text/css">
    .sub {  font-family: "MS Sans Serif", Arial, Helvetica, sans-serif; font-size: 12px; font-weight: bold; color: #666666}
    .bod {  font-family: "MS Sans Serif", Arial, Helvetica, sans-serif; font-size: 10px; color: #000000}
    .subwh {  font-family: "MS Sans Serif", Arial, Helvetica, sans-serif; font-size: 14px; font-weight: bold; color: #FFFFFF}
    .bodwh {  font-family: "MS Sans Serif", Arial, Helvetica, sans-serif; font-size: 10px; color: #FFFFFF; font-weight: bold}
    </style>
    <style>
    	.dhmcss  {width:100%;background:#FFFFFF ;COLOR: #808080; FONT-FAMILY: verdana,arial,helvetica; FONT-SIZE: 10pt; FONT-WEIGHT: bold; padding-left:5;padding-right:5;padding-top:4;padding-bottom:4; TEXT-DECORATION: none; }
    	.dhmcssover  {width:100%;background:#EC941C ;COLOR: #FFFFFF; FONT-FAMILY: verdana,arial,helvetica; FONT-SIZE: 10pt; FONT-WEIGHT: bold;  padding-left:5;padding-right:5;padding-top:4;padding-bottom:4; TEXT-DECORATION: none; }
    	.dhmcssdown  {width:100%;background:#ACDCA5 ;COLOR: #000000; FONT-FAMILY: verdana,arial,helvetica; FONT-SIZE: 10pt; FONT-WEIGHT: bold;  padding-left:5;padding-right:5;padding-top:4;padding-bottom:4; TEXT-DECORATION: none; }
    </STYLE>
    
    <SCRIPT language=JavaScript>
    <!--
    var expDays = 100; // number of days the cookie should last
    
    function GetCookie (name) {
    var arg = name + "=";
    var alen = arg.length;
    var clen = document.cookie.length;
    var i = 0;
    while (i < clen) {
    var j = i + alen;
    if (document.cookie.substring(i, j) == arg)
    return getCookieVal (j);
    i = document.cookie.indexOf(" ", i) + 1;
    if (i == 0) break;
    }
    return null;
    }
    
    function SetCookie (name, value,expires) {
    var argv = SetCookie.arguments;
    var argc = SetCookie.arguments.length;
    var expires = (argc > 2) ? argv[2] : null;
    var path = (argc > 3) ? argv[3] : null;
    var domain = (argc > 4) ? argv[4] : null;
    var secure = (argc > 5) ? argv[5] : false;
    document.cookie = name + "=" + escape (value) +
    ((expires == null) ? "" : ("; expires=" + expires.toGMTString())) +
    ((path == null) ? "" : ("; path=" + path)) +
    ((domain == null) ? "" : ("; domain=" + domain)) +
    ((secure == true) ? "; secure" : "");
    }
    
    function DeleteCookie (name) {
    var exp = new Date();
    exp.setTime (exp.getTime() - 1);
    var cval = GetCookie (name);
    document.cookie = name + "=" + cval + "; expires=" + exp.toGMTString();
    }
    var exp = new Date();
    exp.setTime(exp.getTime() + (expDays*24*60*60*1000));
    
    function getCookieVal(offset) {
    var endstr = document.cookie.indexOf (";", offset);
    if (endstr == -1)
    endstr = document.cookie.length;
    return unescape(document.cookie.substring(offset, endstr));
    }
    
    function checkCount() {
    var count = GetCookie('poponce');
    if (count == null) {
    count++;
    SetCookie('poponce', count, exp);
    
    // Action to take
    dothis()
    }
    }
    
    function dothis(){
    var windowprops = "left=50,top=150,width=550,height=450,location=no,toolbar=no,menubar=no,scrollbars=no"; window.open("http://www.christiancouriernewspaper.com/register.html", "Christian Courier e-Paper Registration", windowprops); // Use to load a page
    }
    // -->
    </SCRIPT>
    
    
    </head>
    
    
    <BODY>
    <BODY OnLoad="checkCount()"> 
    
    <body bgcolor="#ECEDEC" text="#000000" link="#666666" vlink="#666666" alink="#CCCCCC" leftmargin="1" topmargin="1" marginwidth="1" marginheight="1">
    
    
    
    <!--function slide(dir){
    	if (dir == "1" && loc.style.pixelLeft < (screen.width-300)/2){
    		loc.style.pixelLeft+=5; 
    		move=setTimeout("slide(dir)",50);
            }
    	if (dir == "0" && loc.style.pixelTop < (screen.height-300)/2){
    		loc.style.pixelTop+=5; 
    		move=setTimeout("slide(dir)",50);
            }
    }
    if (navigator.appName=="Microsoft Internet Explorer") slide(dir);-->
    
    <div align="center">
      <table width="770" border="0" cellspacing="0" cellpadding="0" height="471">
        <tr valign="top"> 
          <td width="1024" height="471" align="right">
                    <table border="1" width="100%" id="table2">
    					<tr>
    						<td align="center" bgcolor="#FFFFFF">
    <!--						<p class="sub" align="center"><font color="#000000">____________________</p></font><div id="BigAdsdv" style="position:relative;width:700px;height:350px;overflow:hidden;padding:0px;margin:0px;border-style:solid;border-width:0px;border-color:#FFFFFF;z-index:1;FILTER: progid:DXImageTransform.Microsoft.Fade(Overlap=1.00,duration=3,enabled=false);"></img> -->
    						<p>
    		<img border="0" src="Logo_15_Wrapped_2009.png" width="291" height="135" align="left"></p>
    <p>&nbsp;</p>
    <p>
    				<img border="0" src="MPj04026520000[1].jpg" width="304" height="248" align="right"></p>
    <p><u><font size="4" color="#0000FF"><b>America's Longest Running Christian 
    Newspaper</b></font></u></p>
    <p><b><u><font size="4" color="#0000FF">
    						<br>
    						</font></u></b><font size="4" color="#0000FF">
    						------------------------- Info: 414.344.7300 
    						---------------</font><font size="2"><br>
    <br>
    <br>
    <b><a href="http://www.MensRetreat.com">
    <img border="0" src="MidwestMensRetreat2009.png" width="412" height="151"></a><br>
    Midwest Men's Retreat - Conference&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
    Fri-Sun&nbsp;&nbsp;&nbsp; Sept 18-20</b><br>
    Geneva Ridge Resort in Lake Geneva Wisconsin<br>
    &nbsp;</font></p></td>
    					</tr>
    				</table>
    				<p>
    				<script src="BigAdsfade.js" type="text/javascript"></script></td>
        </tr>
        </table>
      <table width="826" border="0" cellspacing="0" cellpadding="0" id="table1">
        <tr> 
          <th width="826" height="50" nowrap colspan="3">
    				<i><font face="Tahoma" size="2">
    				<a href="Current_Issue/LightMinistriesNorth.pdf" style="text-decoration: none; font-weight: 400">
    				<font color="#800000">....Download a Gift from the Heart...[click here]</font></a><span style="font-weight: 400"><font color="#800000">
    				<br>
    				by Light Ministries North</font></span></font></i></th>
        </tr>
        <tr> 
          <td width="194" height="50" align="center">
    		<p align="left">
    		<b><font size="2"><a href="Contacts.htm">Contact Us</a></font></b></td>
          <td width="528" height="50" align="center">
    		<p align="center"><b>
    		<font face="MS Sans Serif" size="1" color="#666666">&nbsp;</font><span class="bod"><font face="MS Sans Serif"><font color="#666666">&nbsp;&copy;2009 
    			The Christian Courier Newspaper&nbsp;&nbsp;//&nbsp; Design &amp; Content 
    		by </font> <a style="text-decoration: none" href="http://www.Sagacity-LLC.com">
    		Sagacity LLC</a></font></span></b></td>
          <td width="104" height="50" align="center"> 
            <span class="bod"><b><a target="_top" href="PrivacyPolicy.htm">
    		<font color="#000000">Privacy<br>
    		Policy</font></a></b></span></td>
        </tr>
      </table>
      <br>
    </div>
    </body>
    </html>
    any/all help will be much appreciated
    thank you

  2. #2
    SitePoint Addict
    Join Date
    Nov 2005
    Location
    Moss, Norway.
    Posts
    283
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Results for default browser settings.

    1. The popup only functions in Opera 9.64.

    2. If you do not do anything, after a while you are redirected to http://www.christiancouriernewspaper.com/blogbase/ in both FF 3.5.2, IE 8.06..... , Google chrome and Opera 10.00 Beta.

    3. But you get an error message in the lower left corner if you use IE 8. Have you validated the page?

    Questions:

    1. Have you tested the output from the different functions?

    2. Have you debugged the page in Fiddler and / or FireBug?

    3. Can you be more specific about where you thing the error occurs? Example:

    <script src="BigAdsfade.js" type="text/javascript">

    Do you have control over the file?

  3. #3
    SitePoint Member
    Join Date
    Jun 2009
    Posts
    21
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by kgun View Post
    Results for default browser settings.

    1. The popup only functions in Opera 9.64.

    2. If you do not do anything, after a while you are redirected to http://www.christiancouriernewspaper.com/blogbase/ in both FF 3.5.2, IE 8.06..... , Google chrome and Opera 10.00 Beta.

    3. But you get an error message in the lower left corner if you use IE 8. Have you validated the page?

    Questions:

    1. Have you tested the output from the different functions?

    2. Have you debugged the page in Fiddler and / or FireBug?

    3. Can you be more specific about where you thing the error occurs? Example:

    <script src="BigAdsfade.js" type="text/javascript">

    Do you have control over the file?

    first of all.. huge thanks for replying back I appreciate it.

    Answers to your questions:

    1. Yes, Ive tested it in 2 browsers only

    2. No I have not

    3. I'm getting an 'spage' null or void object pertaining to BigAdsfade.js but when I search for spage, it doesn't exist in my html page.. weird

    4. Yes I have control over the file



    OK- since I'm not getting this- is there anyway for you to show me a simple popup script. I just want it to pop up when they go to the site.. then the site takes you to the main site, which is why you saw the redirect.. here is my new code, can you show me what to copy/paste so i can get this thing over with?

    huge thanks

    this is the code I have for onload

    Code:
    <OnLoad=window.open('http://www.christiancouriernewspaper.com/register.html', 'Christian Courier e-Paper Registration', 'toolbar=0, location=0, directories=0, menuBar=0, scrollbars=1, resizable=1, width=550, height=450, left=50, top=150');>
    and here is the main code:

    Code:
    <html>
    <head>
    <title>The Christian Courier - a ministry preserved in Christ</title>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
    <meta http-equiv="Refresh" content="3;URL=http://www.ChristianCourierNewspaper.com/blogbase">
    <style type="text/css">
    .sub {  font-family: "MS Sans Serif", Arial, Helvetica, sans-serif; font-size: 12px; font-weight: bold; color: #666666}
    .bod {  font-family: "MS Sans Serif", Arial, Helvetica, sans-serif; font-size: 10px; color: #000000}
    .subwh {  font-family: "MS Sans Serif", Arial, Helvetica, sans-serif; font-size: 14px; font-weight: bold; color: #FFFFFF}
    .bodwh {  font-family: "MS Sans Serif", Arial, Helvetica, sans-serif; font-size: 10px; color: #FFFFFF; font-weight: bold}
    </style>
    <style>
    	.dhmcss  {width:100%;background:#FFFFFF ;COLOR: #808080; FONT-FAMILY: verdana,arial,helvetica; FONT-SIZE: 10pt; FONT-WEIGHT: bold; padding-left:5;padding-right:5;padding-top:4;padding-bottom:4; TEXT-DECORATION: none; }
    	.dhmcssover  {width:100%;background:#EC941C ;COLOR: #FFFFFF; FONT-FAMILY: verdana,arial,helvetica; FONT-SIZE: 10pt; FONT-WEIGHT: bold;  padding-left:5;padding-right:5;padding-top:4;padding-bottom:4; TEXT-DECORATION: none; }
    	.dhmcssdown  {width:100%;background:#ACDCA5 ;COLOR: #000000; FONT-FAMILY: verdana,arial,helvetica; FONT-SIZE: 10pt; FONT-WEIGHT: bold;  padding-left:5;padding-right:5;padding-top:4;padding-bottom:4; TEXT-DECORATION: none; }
    </STYLE>
    <base target="_blank">
    </head>
    <BODY>
    <body bgcolor="#ECEDEC" text="#000000" link="#666666" vlink="#666666" alink="#CCCCCC" leftmargin="1" topmargin="1" marginwidth="1" marginheight="1"> 
    
    <OnLoad=window.open('http://www.christiancouriernewspaper.com/register.html', 'Christian Courier e-Paper Registration', 'toolbar=0, location=0, directories=0, menuBar=0, scrollbars=1, resizable=1, width=550, height=450, left=50, top=150');>
    
    <div align="center">
      <table width="770" border="0" cellspacing="0" cellpadding="0" height="471">
        <tr valign="top"> 
          <td width="1024" height="471" align="right">
                    <table border="1" width="100%" id="table2">
    					<tr>
    						<td align="center" bgcolor="#FFFFFF">
    <!--						<p class="sub" align="center"><font color="#000000">____________________</p></font><div id="BigAdsdv" style="position:relative;width:700px;height:350px;overflow:hidden;padding:0px;margin:0px;border-style:solid;border-width:0px;border-color:#FFFFFF;z-index:1;FILTER: progid:DXImageTransform.Microsoft.Fade(Overlap=1.00,duration=3,enabled=false);"></img> -->
    						<p>
    		<img border="0" src="Logo_15_Wrapped_2009.png" width="291" height="135" align="left"></p>
    <p>&nbsp;</p>
    <p>
    				<img border="0" src="MPj04026520000[1].jpg" width="304" height="248" align="right"></p>
    <p><u><font size="4" color="#0000FF"><b>America's Longest Running Christian 
    Newspaper</b></font></u></p>
    <p><b><u><font size="4" color="#0000FF">
    						<br>
    						</font></u></b><font size="4" color="#0000FF">
    						------------------------- Info: 414.344.7300 
    						---------------</font><font size="2"><br>
    <br>
    <br>
    <b><a href="http://www.MensRetreat.com">
    <img border="0" src="MidwestMensRetreat2009.png" width="412" height="151"></a><br>
    Midwest Men's Retreat - Conference&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
    Fri-Sun&nbsp;&nbsp;&nbsp; Sept 18-20</b><br>
    Geneva Ridge Resort in Lake Geneva Wisconsin<br>
    &nbsp;</font></p></td>
    					</tr>
    				</table>
    				<p>
    				<script src="BigAdsfade.js" type="text/javascript"></script></td>
        </tr>
        </table>
      <table width="826" border="0" cellspacing="0" cellpadding="0" id="table1">
        <tr> 
          <th width="826" height="50" nowrap colspan="3">
    				<i><font face="Tahoma" size="2">
    				<a href="Current_Issue/LightMinistriesNorth.pdf" style="text-decoration: none; font-weight: 400">
    				<font color="#800000">....Download a Gift from the Heart...[click here]</font></a><span style="font-weight: 400"><font color="#800000">
    				<br>
    				by Light Ministries North</font></span></font></i></th>
        </tr>
        <tr> 
          <td width="194" height="50" align="center">
    		<p align="left">
    		<b><font size="2"><a href="Contacts.htm">Contact Us</a></font></b></td>
          <td width="528" height="50" align="center">
    		<p align="center"><b>
    		<font face="MS Sans Serif" size="1" color="#666666">&nbsp;</font><span class="bod"><font face="MS Sans Serif"><font color="#666666">&nbsp;&copy;2009 
    			The Christian Courier Newspaper&nbsp;&nbsp;//&nbsp; Design &amp; Content 
    		by </font> <a style="text-decoration: none" href="http://www.Sagacity-LLC.com">
    		Sagacity LLC</a></font></span></b></td>
          <td width="104" height="50" align="center"> 
            <span class="bod"><b><a target="_top" href="PrivacyPolicy.htm">
    		<font color="#000000">Privacy<br>
    		Policy</font></a></b></span></td>
        </tr>
      </table>
      <br>
    </div>
    </body>
    </body>
    </body>
    </html>

  4. #4
    SitePoint Addict
    Join Date
    Nov 2005
    Location
    Moss, Norway.
    Posts
    283
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Try to Google:

    1. There are a lot of scripts on sites like http://www.hotscripts.com/
    2. Or you can try to Google:

    JavaScript OR php popup script OR class


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
  •