Click to See Complete Forum and Search --> : iFrame issue
lordofdavipers
09-13-2007, 03:30 AM
At a website i work on we have a contact page that has an iframe. the links above it will open the desired form in the iframe window (i.e. tech support, staff contact, etc.). However, our individual staff contact link, while it opens in the iframe, if you try to click any of the other links again and try to open them in the iframe, they open in a new window. ????????
I dont know if that made complete sense, but try it on the contact page. click link-by-link (from tech support to indiv. staff cont.) and do it again the second time and watch them open in a new window. (you have to refresh the contact page to "fix" it)
http://christians4life.net/main/contact.htm
Please let me know if you know the source for this issue.
thanks,
andrew
kiwibrit
09-13-2007, 06:18 AM
With your invalid code (http://validator.w3.org/check?verbose=1&uri=http%3A%2F%2Fchristians4life.net%2Fmain%2Fcontact.htm), and use of frames, I don't have the time to delve into this.
But one thought, why not simplify the whole thing by using a from that has a radio button to select the desired recipient, followed by the rest of the form inputs? If the specifics of the form are important, you could have hyper links on the contact page which call up the specific forms for the inteended recipients.
OT: I find the continual changing banner at the top of the page unpleasant - and from what I have read others find that sort of animation unpleasant, too. It may also cause some disabled visitors problems.
Ferret
09-13-2007, 09:24 AM
While I second the suggestion to fix the errors in your code, I don't like the general "use a validater or die a horrible death" snobbery.
Taking a stab at what's going wrong: I'm going to guess it has something to do with your use of the <base> tag.
<base target="_top" />
The <base> tag should be in the header.
That might not be the whole problem... I'll keep looking in the mean time.
edit: Upon further inspection, there's a fair number of misplaced tags. I'm working on it.
kiwibrit
09-13-2007, 10:36 AM
While I second the suggestion to fix the errors in your code, I don't like the general "use a validater or die a horrible death" snobbery........
Intriguing comment. When a page has a whole bunch of invalid code, I am not clear that it is snobbery to point out it is difficult to wade through. Some of us don't have the time to do so as a hobby - code which has been cleaned up gives us a better chance to look at in the time we've got - when we nip over to this forum as a sort of coffee break. Of course, it could well be that in cleaning up the code, the original poster cleans up the original problem. :)
Ferret
09-13-2007, 11:31 AM
Here's where I am so far..... if I had realized this would have been easier to rewrite from scratch (which I now know), I would have done so. :eek:
Down to ~15 errors from 60 or so. I tried to mark things I changed, but in some places that turned into a mess. :P
<!--Ferret Edit: always use a valid doctype--><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<body> <!--Ferret edit: this was all put into an external style sheet: bgcolor="#FFFFFF" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0" background="../2007_TEMPLATES/images1.2007/bg1.jpg"-->
<!-- font face="Arial" Tag removed, style added to style sheet -->
<li><!--Ferret edit: not needed, style in style sheet font face="Arial"--><a href="http://christians4life.net">
Home</a><!--/font--></li>
<li><!--Ferret edit: see above font face="Arial"-->
<a href="http://christians4life.net/main/ministries.htm">Ministries</a><!--/font--></li><!-- Ferret edit: removed unused rel attributes from these links -->
<li><!-- Ferret edit: see abovefont face="Arial"-->
<a href="http://christians4life.net/main/guidance.htm">Guidance</a><!--/font--></li>
<li><!-- Ferret edit: see abovefont face="Arial"-->
</div>
<!-- Ferret edit font face="Arial"-->
<!--1st drop down menu --><!--/font-->
<div id="dropmenu1" class="dropmenudiv">
<!-- Ferret edit font face="Arial"-->
<a href="http://christians4life.proboards41.com">Home</a>
<a href="http://christians4life.proboards41.com/index.cgi?action=login">
Login</a>
<a href="http://christians4life.proboards41.com/index.cgi?action=register">
Register <span style="size:-3">(free)</span></a> <!-- /font --></div>
<!-- Ferret edit font face="Arial"-->
<!--2nd drop down menu --><!-- /font -->
<div id="dropmenu2" class="dropmenudiv" style="width: 150px;">
<!-- Ferret edit font face="Arial"-->
<a href="http://christians4life.net/main/guidance.htm">Home</a>
<a href="http://christians4life.net/main/no_template/testimonies.htm">
Testimonies</a> <!-- /font --></div>
<!--3rd drop down menu -->
<div id="dropmenu3" class="dropmenudiv" style="width: 150px;">
<!-- Ferret edit font face="Arial"-->
<a href="http://christians4life.net/main/contact.htm">Contact Home</a>
<a href="http://christians4life.net/main/email_archive">Email Archive</a>
<a href="http://christians4life.net/main/policy.htm">Privacy Policy</a>
<!-- /font --></div>
<!-- Ferret edit font face="Arial"-->
<!--4th drop down menu --><!-- /font -->
<div id="dropmenu4" class="dropmenudiv" style="width: 150px;">
<!-- Ferret edit font face="Arial"-->
<a href="http://christians4life.net/pf5/kids.htm">Children</a>
<a href="http://christians4life.net/pf5/youth.htm">Youth</a>
<a href="http://christians4life.net/pf5/relationships.htm">Singles/Couples</a>
<a href="http://christians4life.net/pf5/family.htm">Family</a>
<a href="http://christians4life.net/pf5/adults.htm">Adults</a>
<a href="http://christians4life.net/pf5/you_church.htm">You & Your
Church</a> <!-- /font --></div>
<!-- Ferret edit font face="Arial"-->
<!--5th drop down menu --><!-- /font -->
<div id="dropmenu5" class="dropmenudiv" style="width: 150px;">
<!-- Ferret edit font face="Arial"--><a href="http://www.google.com/">Google</a>
<a href="http://www.yahoo.com">Yahoo</a>
<a href="http://www.msn.com">MSN</a> <!-- /font --></div>
<script type="text/javascript">
Applications</a> |
<a target="IFRAME" href="no_template/forms/contact.forms/staffing.htm" style="text-decoration: none">
Management Info</a> |
<a target="IFRAME" style="text-decoration: none" href="no_template/forms/staff.forms/form.1.htm">
Individual Staff Contact</a></span></span></p>
<p style="margin-top: 0; margin-bottom: 0">
<iframe name="IFRAME" src="no_template/forms/contact.forms/formtype.htm" style="width:100%; height:394px; border:0;">
Your browser does not support inline frames or is currently configured not to display inline frames.
</iframe></p>
continued in next post.... 10k character limit. :P
Ferret
09-13-2007, 11:32 AM
<!-- Ferret edit: replaced by adding padding to the top of the below table. No need for extra tags-->
<table style="border:1px; width:650px; padding-top: 20px"><!-- Ferret edit -->
<tr>
<td style="background-color:#000000" colspan="2"><!-- Ferret edit -->
<p align="center" style="margin-top: 0; margin-bottom: 0; font-weight: bold;"><!--b bold should be done with styles... see previous tag-->
<span style="font-size:4; color: #fff;"><!--Ferret edit: styles replaced: size="4" color="#FFFFFF"--><a name="eMore">
</a>Emails<!-- Ferret edit: why do you need this tag? You use it very frequently throughout the site. span lang="en-us"-->
and More<!--/span--></span><!-- Ferret edit: I changed the font tag into a span with style formatting, as font is a depricated tag--><!--/b--></td>
</tr>
<tr>
<td style="width:261px;">
<p style="margin-top: 0; margin-bottom: 0">
<!--Ferret edit: style in stylesheet font face="Arial"-->
c4l@christians4life.net<!--/font--></td>
<td style="width:373px"><!-- Ferret edit: Many many useless tags deleted from this section and others following -->
Our all-purpose email address for general questions ranging from <a href="policy.htm">Account Management</a>, Technical Support, Community, organizational information, etc.<!--/font-->
</td>
</tr>
<tr>
<td style="width:261px"><!-- Ferret edit -->
<p style="margin-top: 0; margin-bottom: 0">
<span style="font-size:2"><!-- Ferret edit -->
<a href="http://myspace.com/c4lms">
<img border="0" src="../images/logos/myspace_logo.gif" alt="MySpace Logo" style="width:150px; height:31"><!--Ferret edit--></a></span><!-- Ferret edit --></td>
<td style="width:373px"><!-- Ferret edit -->
<!--font face="Arial"--><p style="margin-top: 0; margin-bottom: 0" class="style2">
Click logo on left to visit our MySpace.<!--/font--></td>
</tr>
<tr>
<td style="width:261px;"><!-- Ferret edit -->
<p style="margin-top: 0; margin-bottom: 0">
<!--Ferret edit: see other edits font face="Arial"-->
<a href="calendar.htm" style="text-decoration: none; color:#FF0000; font-weight:bold"><!--ferret edit-->Calendar</a><!--/font--></span></td>
<td style="width:373px"><!-- Ferret edit -->
<span lang="en-us">See the calendar for events and other stuff</span></td>
</tr>
<tr>
<td style="width:261px"><!-- Ferret edit -->
<span style="font-weight:bold"><!--Ferret edit-->
<!-- Ferret edit font face="Arial"-->
<a href="http://www.online-translator.com/url/tran_url.asp?lang=en&direction=es&template=General&transliterate=on&autotranslate=on&url=http://christians4life.net/" style="text-decoration: none; color:#FF0000; font-weight:bold">
C4L In Spanish</a><!--/font--></span></td>
<td style="width:373px"><!-- Ferret edit -->
View C4L in Spanish</td>
</tr>
</table>
<!--Ferret edit: replaced by adding padding to the top of the below table-->
</tr>
<tr>
<td style="background-color:#666666" colspan="2"><!-- Ferret edit -->
<!-- Ferret edit font face="Arial"-->
<p align="center" style="margin-top: 0; margin-bottom: 0">
<span lang="en-us" style="font-size:2; color:#FFFFFF"><!-- Ferret edit -->Choose
"Affiliates" in the tech form and please include your
organization name and URL in the message box.</span><!--/font--></td>
<!-- Ferret edit font face="Arial" -->
<p align="center" style="margin-top: 0; margin-bottom: 0">
<span lang="en-us" style="font-size:2; color:#FFFFFF">Choose "Links"
in the tech form and please include your link name and URL in the
message box.</span><!--/font--></td>
</tr>
<tr>
<td style="width:257px"><!-- Ferret edit -->
<td style="width:257px"><!-- Ferret edit -->
<!-- Ferret edit font face="Arial"-->
The Christian Index<!-- /font --></td>
<td style="width:377px"><!-- Ferret edit -->
<!--Ferret edit font face="Arial"-->
<a href="http://www.christianindex.org">
http://www.christianindex.org</a><!--/font--></td>
</tr>
</table>
<!--/font-->
<!-- #EndEditable --></td>
</tr>
</table>
</div><!-- Ferret edit font face="Arial"-->
<!-- ImageReady Slices (Untitled-1) -->
<!-- End ImageReady Slices --><!-- /font-->
<p style="margin-top: 0; margin-bottom: 0" align="center"><!--font face="Arial"--><span style="font-weight:bold; font-size:7pt" class="style6"><!--Ferret edit--><!-- strong-->This website is dedicated to the works
of our Lord and Savior Jesus Christ.<!--/font--><!--/strong--></span><!--Ferret edit font size="1"-->
<!-- Ferret edit /font--></span><!--/font--></p>
<p style="margin-top: 0; margin-bottom: 0" align="center"><span style="font-weight:bold; font-size:7pt"><!--Ferret edit-->
Copyright (C) 2004-2007 Christians 4 Life organization.
All rights reserved.</span></p>
<p style="margin-top: 0; margin-bottom: 0" align="center">
<span style="font-size:7pt">Website by <!-- /font --><!-- font face="Tahoma, Verdana"-->
<!--font face="Arial" size="1"-->
<a target="_blank" style="text-decoration: none;" href="http://wandrewc.com/luvrwd">
LUVR Web Design</a><!-- /font --><!-- /font --><!--font size="1" face="Arial"-->.<!-- /font --></p>
<!-- Ferret Edit TAG REMOVED!!! body -->
</body>
<!-- #EndTemplate -->
</html>
Ferret
09-13-2007, 11:37 AM
Here's the simple CSS file I started (and linked to) to alleviate the MASSIVE number of formatting tags you have on your site. (there were at least 20-25 instances of <font face="Arial"> that I replaced with a simple * {font-family: Arial, Helvetica, sans-serif;}
here is the CSS:
* {
font-family: Arial, Helvetica, sans-serif;
}
body {
background-color:#FFFFFF
background:url(../2007_TEMPLATES/images1.2007/bg1.jpg);
}
MUCH more of the formatting should be ported over to an external CSS file... I just didn't do it. I used a lot of inline styles, which isn't a good idea in the long run, but it gives you an idea of proper formatting technique.
Ferret
09-13-2007, 11:41 AM
Intriguing comment. When a page has a whole bunch of invalid code, I am not clear that it is snobbery to point out it is difficult to wade through. Some of us don't have the time to do so as a hobby - code which has been cleaned up gives us a better chance to look at in the time we've got - when we nip over to this forum as a sort of coffee break. Of course, it could well be that in cleaning up the code, the original poster cleans up the original problem. :)
I agree... I was more referring to the general reaction that posts get: if the validator doesn't check out, then we don't have time for you. Example being a post I made the other day: http://www.webdeveloper.com/forum/showthread.php?t=160463
The fix was just removing a decimal point, but the initial reaction was not to look at the code unless it's error free. Sorry to use you as an example, but I think it's better to try to figure out which error it is that might be causing the problem and start from there.
lordofdavipers
09-13-2007, 01:16 PM
wow. lots of replies with lots of things to do. im pretty sure my issue is coming from using the obsolete FrontPage (I have web expression). FP adds style tags throughout the document regardless. Im not sure if WE does it or not.
I can tell that it's going to take some time to do this. My question for the guy who said use radio buttons, what's the best way to implement them?
kiwibrit
09-13-2007, 01:55 PM
......My question for the guy who said use radio buttons, what's the best way to implement them?
My long marriage will end in divorce if I spend any more time on the computer today - so excuse me for being brief.
I was thinking of using the radio buttons to send the results of the form to the right addressee. But IIRC your forms differ from recipient to recipient. Why not just have a list of hyperlinks to pages with appropriate forms?
No use of frames here - but simplicity has its merit.
lordofdavipers
09-13-2007, 06:39 PM
thanks for the info about the radio button...im not quite sure how to do that, though. more than likely with javascript. i'll google around for it (unless you know how to right off hand).
in the mean time while waiting on a reply, i'll try to re-think how the forms are accessed.
lordofdavipers
09-13-2007, 07:21 PM
right now i've just made the last link for individual staff contact open in a new window to save you guys hassles of fixin it. thanks for the help.
lordofdavipers
09-13-2007, 07:48 PM
well hey. good news is that i fixed it. i had a STRONG hunch it was a particular javascript code within the indiv. staff cont. (ISC for short) pages.
this was on each page
<script language="javascript">
function fbkinfo(){
window.open("http://christians4life.net/main/no_template/feedback.info.htm","feedback","height=320, width=500")}
</script>
<script language="javascript">
self.name="home"</script>
i dont think its the popup window that caused it rather its the self.name="home" one that did it. now i was an super expert with html in the 2.0 era but its 4.0 and im i've been completely left behind so i'll say the ineveitable...i dont know why it did that.
thanks guys.
webdeveloper.com
Copyright Internet.com Inc., All Rights Reserved.