|
| |
|
|
Starhugger
Posts: 534 Joined: 4/12/2005 Status: offline
|
Choose an encoding? - 3/4/2007 3:58:26
At some point months and months ago, Frontpage suddenly started giving me a popup whenever I loaded my Index page into FP. No other page, just the home Index page. The popup asks me to "Choose an encoding." (screenshot attached) I have never been able to get rid of it, no matter what I choose or don't choose in the popup window, Page Options, Site Options, etc., for language and encoding settings. I have NO idea how it got started and it has been driving me nuts. So, that's one of the (many) reasons why I decided to start gradually recoding my site, starting with my Index page, in CSS. I've been using FP as an editor, with most of the FP components turned off. I've left enough in that I can use the FP included page script, which I find useful. So here I am, happily (well, sort of) recoding my Index page in CSS and everything is going well (at least as well as it can go using CSS...). Suddenly, I'm in my Index page's CSS file and I accidentally hit a function key -- NO idea which one. It asks me: Do I want to save the file first before Previewing. Huh? Instinctively I say Yes and it loads my CSS file into what looked like IE7. Huh? Okay whatever. So I click the upper-right X to close "IE7" and wind up closing Frontpage instead. Huh??? Okay fine. I reload FP and suddenly, I have this blasted encoding thing popping up!! What the--??? Does anyone have ANY idea what this thing is looking for? Why is this happening? And most important, how can I get it to stop?? Thanks for the help. Starhugger Thumbnail Image
Attachment (1)
|
|
|
|
Tailslide
Posts: 6295 Joined: 5/10/2005 From: Out here on the raggedy edge Status: offline
|
RE: Choose an encoding? - 3/4/2007 5:17:13
I'm guessing it's looking for the encoding declaration like this: <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> or this:
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" /> on your index page (there are lots more of these including some M$ proprietory ones). If you don't have one then you should probably add one. Which to choose? Depends on the language that you're using but I'd generally go for the UTF-8 one these days.
_____________________________
"My strategy is so simple an idiot could have devised it" Little Blue Plane Web Design | Blood, Sweat & Rust - A Land Rover restoration project
|
|
|
|
Starhugger
Posts: 534 Joined: 4/12/2005 Status: offline
|
RE: Choose an encoding? - 3/4/2007 11:56:40
Thanks for replying, Tail and Jaybee. I do have an encoding declaration though. I've tinkered with it, and here is what I have as the pre-Body code at the moment, which I copied from Tail's suggested code (and which still brings up the popup window): <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
<head>
<meta http-equiv="Content-Language" content="en" />
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Home Page</title>
<link rel="stylesheet" type="text/css" href="css/header.css" />
<link rel="stylesheet" type="text/css" href="css/main.css" />
<link rel="stylesheet" type="text/css" href="css/homepage.css" />
</head> It doesn't seem to matter what I put as the charset, though. The popup FP window defaults to "US/Western European (Windows)" but even when I put that in, it still pops up to ask me when I load the page into FP. What I did find at first was that I had the "title" line immediately after the "head" line, which was causing the popup to come up in Split Window mode every time I switched from the "code" half to the "design" half. When I put the "title" line after the "meta" tags, it at least stopped doing that. But it's still doing the popup when I first load the page. I've even gone into Site Options and Page Options and made sure that everything is set to the same character set, but that doesn't seem to change anything. Any other ideas? SH
|
|
|
|
Starhugger
Posts: 534 Joined: 4/12/2005 Status: offline
|
RE: Choose an encoding? - 3/4/2007 12:15:55
That's correct, Jaybee. In Frontpage only, and only for the "index.htm" page in my current site, and in "homepage.htm" in the CSS version (same page in terms of content, but different name for now). It's never done it for any other pages. SH
|
|
|
|
Starhugger
Posts: 534 Joined: 4/12/2005 Status: offline
|
RE: Choose an encoding? - 3/4/2007 12:55:36
Okay, I tried it in both the current version and the CSS version. In both cases, the popup window does NOT come up. So it seems it's something to do with the actual pages in question. In the CSS version, I have the Site Settings>Language set to utf-8. In the current live version, the meta-tag is set to "windows-1252" and the Site Language is "US/Western European (Windows)." SH
|
|
|
|
Starhugger
Posts: 534 Joined: 4/12/2005 Status: offline
|
RE: Choose an encoding? - 3/4/2007 16:26:37
Hmmm... Okay, the plot thickens. It seems to have to do with a javascript module I have on that page. It's a very cool module that calculates the current Moon phase and displays it graphically, and you can put it on your website (they ask you to register with them first). When I delete it, the pages loads fine. When I use an updated version, it loads fine (although this new version comes with its own problems and I'd rather use the one I have now, but hopefully without this FP problem). Here is the code that seems to be creating the problem. Is there something I should be putting in the Head section to warn FP that there's a js module in the body? It's possible I had it there once and removed it, thinking it was for something else. Unfortunately, the site where I got the code doesn't list the old code anymore. (line breaks inserted for readability) <!-- // Begin Current Moon Phase HTML (c) CalculatorCat.com // -->
<script language="JavaScript" type="text/javascript"> var ccm_cfg =
{ n:'1', pof:'1', dt:'1', tc:'#ffffff', pth:'' } </script>
<table width="200" bgcolor="#000000"
style="background-color:bgcolor="#000000" " cellpadding="0"
cellspacing="3" border="0"><tr>
<td align="center" style="border: 1px solid
#FF2832;color:#ffffff;padding-top:8px;padding-bottom:5px;"
bgcolor="#000000" nowrap="1">
<font face="arial,verdana,sans-serif" size="1" color="#ffffff">
<span style="font-size:10px;font-family:arial,verdana,sans-serif;color:#ffffff">
<span style="font-size:11px;letter-spacing:.3em">CURRENT MOON</span><br />
<script language="JavaScript" type="text/javascript"
src="http://www.xxxxxxxxxx.com/cs/ccm_b.js"></script>
<script language="JavaScript" type="text/javascript"
src="http://www.xxxxxxxxxx.com/cs/ccm_h.js"></script><br clear="all">
<a href="http://www.xxxxxxxxxxxx.com/moon_phases/moon_phases.phtml" target="cc_moon_ph"
style="font-size:10px;font-family:arial,verdana,sans-serif;color:#777777;
text-decoration:underline;background:#000000;border:none;">
lunar phases</a></span></font></td></tr></table>
<!-- // end moon phase HTML // --> Can anyone see if I should have something in the Head section to prevent FP from freaking out? Thanks. Starhugger
< Message edited by Starhugger -- 3/5/2007 0:37:18 >
|
|
|
|
Starhugger
Posts: 534 Joined: 4/12/2005 Status: offline
|
RE: Choose an encoding? - 3/5/2007 0:35:27
Here's the new version code. Line breaks inserted for readability. (I hope I'm not violating any copyright laws by posting this, but I think their terms of use only covers changing the code. I'm X-ing out key parts to be sure. Please register with their site to use this code.) <!-- // Begin Current Moon Phase HTML (c) CalculatorCat.com // -->
<div style="width:223px">
<div style="padding:2px;background-color:#000000;border: 1px solid #000000">
<div style="padding:15.6px;padding-bottom:5.6px;padding-top:5.6px;
border: 1px solid #CCCCFF" align="center">
<div style="padding-bottom:7px;color:#FFFFFF;
font-family:arial,helvetica,sans-serif;font-size:11px;letter-spacing:.3em;">
CURRENT MOON</div>
<script language="JavaScript" type="text/javascript">var ccm_cfg =
{ pth:'http://www.xxxxxxxxxx.com/cs/', fn:'ccm_h1.swf', lg:'en', hs:1,
tc:'FFFFFF', bg:'000000', mc:'', fw:183.9, fh:78.8, js:0, msp:0 }</script>
<script language="JavaScript" type="text/javascript"
src="http://www.xxxxxxxxxx.com/cs/ccm_fl.js"></script>
<div style="padding-top:5px" align="center">
<a href="http://www.xxxxxxxxxxxxx.com/moon_phases/moon_phases.phtml"
target="cc_moon_ph" style="font-size:10px;font-family:arial,verdana,sans-serif;
color:#888888;text-decoration:underline;border:none;">
<span style="color:#888888">moon info</span>
</a></div></div></div></div><!-- // end moon phase HTML // --> I have Adblock running on Firefox 1.5 and if I don't turn it off, it puts a "shadow" tag on the generated image that says "Adblock." What a nuisance. I don't get that with the older version. The new version apparently also must have Flash enabled and I'm concerned that people wouldn't be able to view it if they had it turned off. Again, that problem doesn't come up (to my knowledge) with the old version on a live page. Thanks again for the help. Starhugger
|
|
|
|
jaybee
Posts: 14191 Joined: 10/7/2003 From: Berkshire, UK Status: offline
|
RE: Choose an encoding? - 3/5/2007 4:59:22
OK, lets give this a go. First off we'll put the javascript into an external file so copy the code below into a new file and save it in your root directory as moonphase.js var ccm_cfg = { n:'1', pof:'1', dt:'1', tc:'#ffffff', pth:'' } Then where you have the current Calculator cat code, replace it with the code below. <!-- // Begin Current Moon Phase HTML (c) CalculatorCat.com // -->
<script language="JavaScript" type="text/javascript" src="moonphase.js"></script>
<table width="200" bgcolor="#000000" cellpadding="0" cellspacing="3" border="0">
<tr>
<td align="center" style="border: 1px solid #FF2832;color:#ffffff;padding-top:8px;padding-bottom:5px;" bgcolor="#000000" nowrap="1">
<font face="arial,verdana,sans-serif" size="1" color="#ffffff">
<span style="font-size:10px;font-family:arial,verdana,sans-serif;color:#ffffff">
<span style="font-size:11px;letter-spacing:.3em">CURRENT MOON</span><br />
<script language="JavaScript" type="text/javascript" src="http://www.xxxxxxxxxx.com/cs/ccm_b.js"></script>
<script language="JavaScript" type="text/javascript" src="http://www.xxxxxxxxxx.com/cs/ccm_h.js"></script>
<br clear="all">
<a href="http://www.xxxxxxxxxxxx.com/moon_phases/moon_phases.phtml" target="cc_moon_ph" style="font-size:10px;font-family:arial,verdana,sans-serif;color:#777777;
text-decoration:underline;background:#000000;border:none;">
lunar phases</a></span></font></td>
</tr>
</table>
<!-- // end moon phase HTML // -->
then replace all the xxxxxxxxxs with the calculatorcat url. I can't see anything obvious on the ad blocker front but the script keeps putting in calls to the Calccat site so they may well have something that is triggering it. I suggest you contact them or have a look through any FAQs or support areas on their site to see if anything is mentioned. You say you're worried about people not having Flash turned on, if they're that type then they are unlikely to have javascript on either so they still won't see it. There are no <noscript> lines in there to act as replacements.
_____________________________
If it ain't broke..... fix it until it is. GAWDS Now where did I put that Doctype?
|
|
|
|
Starhugger
Posts: 534 Joined: 4/12/2005 Status: offline
|
RE: Choose an encoding? - 3/5/2007 11:06:23
quote:
First off we'll put the javascript into an external file so copy the code below into a new file and save it in your root directory as moonphase.js Actually, I'm not sure that this wouldn't violate their terms of agreement, which I believe asks that you not alter the code. Do you think this would prevent it from being "seen" as an ad by ad-blocking utilities? It may not alter the functioning of the code, per se, but rearranging it like that might be enough to make the author uncomfortable about it. quote:
I can't see anything obvious on the ad blocker front but the script keeps putting in calls to the Calccat site so they may well have something that is triggering it. I suggest you contact them or have a look through any FAQs or support areas on their site to see if anything is mentioned. Yes, I sent them a contact form email yesterday, asking for help with this, and haven't heard back yet. The script actually calls out to two different URLs, but just to be sure I wasn't just violating their TOA I x'ed out the URLs in both code patches here. If someone reading this thread is interested, I provided a link to their site where they can get it themselves from the source. quote:
You say you're worried about people not having Flash turned on, if they're that type then they are unlikely to have javascript on either so they still won't see it. There are no <noscript> lines in there to act as replacements. Well, I'm one who has Flash installed but disabled on FF unless I absolutely need it. And I do have javascript enabled. I just can't stand stuff flashing on the screen at me. I get so distracted that I can't read what's next to it! Drives me nuts. Back when I used to use IE all the time, I paid real money for a utility that would disable Flash on IE, although to enable it again you had to shut down IE and reload it. Pain in the byte. FF is SOOO much more convenient! And I almost never get spyware, adware, etc. when running FF, yet I always do with IE. And with all the nonsense I found with IE7, I finally just gave up and now I'm a Firefox devotee. Thanks again for your help, Jaybee. I'll let you know what happens when the script guys get back to me. Starhugger
|
|
|
|
Starhugger
Posts: 534 Joined: 4/12/2005 Status: offline
|
RE: Choose an encoding? - 3/5/2007 11:27:00
quote:
No because you're not changing the js code, you're just using it slightly differently. The note is there to stop people taking it, modifying it and then touting it as their own. There is nothing to stop you tidying up his html code which is quite frankly a bit of a mess. Sorry, re-reading my last post it is a bit confusuing. This is the code for the old one, not the new Flash version. That one you need to talk to them about. Oooh! Okay, thanks. I didn't realise that. Actually, the new version has a non-javascript option, come to think of it, but still requires Flash. You may be right about tidying up the code, but I'd prefer to check with the author(s) first. If I don't hear from them after a couple of tries, I'll give your suggestion a try. Thanks! SH
|
|
|
|
Starhugger
Posts: 534 Joined: 4/12/2005 Status: offline
|
RE: Choose an encoding? - 3/5/2007 11:39:16
quote:
To help block the spyware go get Spybot Search & Destroy Spyware Guard and Spyware Blaster. All free, read the instructions. You know, I had SS&D installed for a long time and it used to find stuff on a regular basis. Then I had problems downloading an update a year or two ago, and ever since then, no matter how many times I uninstalled, reinstalled, etc., it never found anything ever again, even when Adaware found scads of stuff. So I finally gave up and uninstalled the thing. Yet, it found a huge population of stuff on a friend's computer that I tried to revive when it was on death's doorstep. I guess it only finds the really sinister stuff and ignores the rest. I figure my other anti-spyware will get the really bad stuff, so no point in having SS&D too. I've never heard of SG or SB. I'll have to check them out. I run spyware scans ever few days with Adaware and PC-cillin (which is primarily antivirus but they've branched out into other malware in the last couple of versions). As long as I'm using FF, these antispyware scans almost never find anything, but run IE7 around a few sites and they always find a few critters lurking in the corners. SH
|
|
|
|
jaybee
Posts: 14191 Joined: 10/7/2003 From: Berkshire, UK Status: offline
|
RE: Choose an encoding? - 3/5/2007 11:48:30
quote:
I have read and agree to the following Copyright/Terms of Use: Moon Module Copyright/Terms of Use - This module, design, and code is protected under United States and International copyright laws. You are not allowed to remove any of the links pointing back to CalculatorCat.com. The text link (i.e., "moon phase info") at the bottom of the module MUST remain unaltered. All copyright notices embedded in the HTML and Javascript code must remain unchanged. Also, this module may not be used on websites that have any of the following content: pornography/adult content, excessive profanity, racial intolerance, illicit drugs, hacking/cracking, or any other content that promotes illegal activity. By using this module, you are stating your acceptance of these Terms. According to that what I've told you to do above is fine.
_____________________________
If it ain't broke..... fix it until it is. GAWDS Now where did I put that Doctype?
|
|
New Messages |
No New Messages |
Hot Topic w/ New Messages |
Hot Topic w/o New Messages |
Locked w/ New Messages |
Locked w/o New Messages |
|
Post New Thread
Reply to Message
Post New Poll
Submit Vote
Delete My Own Post
Delete My Own Thread
Rate Posts
|
|
|