Google Answers Logo
View Question
 
Q: Trouble creating drop-down menu for blog ( No Answer,   0 Comments )
Question  
Subject: Trouble creating drop-down menu for blog
Category: Computers > Programming
Asked by: nealysmith79-ga
List Price: $7.50
Posted: 25 May 2003 12:02 PDT
Expires: 27 May 2003 21:43 PDT
Question ID: 208521
Hello! I am using Blogger.com to create my blog, sickcandy.com. I have
been customizing my pages in Dreamweaver, and that seems to be working
fine. My problem is for the life of me I can't figure out how to get
my archives to work. I've been trying to create a Java drop-down menu.
I have copied the source code from bizstone.com and also tried a
script generator at http://philringnalda.com/scriptgen/, all with no
luck. I hope that this is a relatively simple problem to fix. Your
help will be greatly appreciated! Thanks!!!

Request for Question Clarification by errol-ga on 25 May 2003 12:31 PDT
Hi there Nealysmith79!

I have had a quick look at your blog (very well designed it is too!)
and I can't seem to find your archive pages.
Does your blog date back further than May 17th?

I think the problem is not the actual menu that you need which would
be a simple matter of creating links to the archive page(s) but it's
the fact that there is no archive present.

I would be more than happy to write or alter an existing menu for you
with *insert URL here* parts.
Just tell me what sort of design you need and I'll give it a go.

Kind regards,
errol-ga.

Clarification of Question by nealysmith79-ga on 25 May 2003 13:14 PDT
Hi there! The whole 'lost archives' thing seems to be a big part of my
problem. I started the blog on the 11th, and I have three sets of
archives that were generated on blogger.com. They don't seem to have
found their way to my FTP, although they have in the past (I may have
recently delteded them). I just 'republished' the archives now.
Another problem: when I went to the 'archive template' area, I got
this message: "msxml3.dll error '80072efd' A connection with the
server could not be established /functions/getTemplate.inc, line 35 ".
Is there hope for me?

Clarification of Question by nealysmith79-ga on 25 May 2003 13:17 PDT
P.S.-- I think that it may have something to do with my archive
settings. Here's how they are currently set up:
Archive Frequency: weekly 
FTP Archive Path: /archives/
FTP Archive Filename: archive.html

Also, I'd like my drop-down menu to look like www.bizstone.com

Thanks!!!

Clarification of Question by nealysmith79-ga on 25 May 2003 13:25 PDT
Will this link help you?
http://www.sickcandy.com/archives/archive.html

Request for Question Clarification by errol-ga on 25 May 2003 15:33 PDT
Hello again.

I just had a look at the index [ http://www.sickcandy.com/archives/ ]
and it seems to be working ok.
There are pages for every 7 days so that's fine.

The problem as far as I can see is with the actual script in the file:
http://www.sickcandy.com/archives/archive.html

If I look on this page:
http://www.sickcandy.com/archives/2003_05_25_archive.html I can see
parts of a script that hasn't been started or terminated properly.
Looking at the source of the above script file we have the culprit
just after the first "document.write" part:
----------------
  document.write(script type=\"text/javascript\">function
gothere(where){location.href =
where.options[where.selectedIndex].value;}</script>");
  document.write("<form action=\"\">");
  document.write("<select name=\"archivemenu\"
onChange=\"gothere(this)\" class=\"archivelinks\">"); 
document.write("<option value=\"\">Archives</option>");  if ( null !=
currentPage ){    document.write( "<option value=\"" + currentPageLink
+ \>" + currentPageName + "</option>");    }  for ( var n=start;
n<end; n++ ){
    document.write( BlogInfo[n].MakeLink() );
    }


  document.write(/select></form>");
    
  }
----------------
The first line should read:

  document.write(<script type=\"text/javascript\">function 
                 ^
See the extra "<" before the script type?
It's that single missing character which is preventing your site from
working like the Bizstone.com one.

Try opening the file in Notepad then change that line, save it, upload
it to the /archives/ folder and refresh the blog page to see if your
menu works.

Hope this helps,
errol-ga.

Clarification of Question by nealysmith79-ga on 25 May 2003 15:52 PDT
Hi! I added the "<" to my archive.html file and uploaded it to my FTP.
It's still funky. I am happy to see that we're making progress! What
should I try next? Thank you...

Clarification of Question by nealysmith79-ga on 25 May 2003 15:53 PDT
I just check and for some reason it didn't take. Let me try it again...

Clarification of Question by nealysmith79-ga on 25 May 2003 16:02 PDT
I tried it again, but no dice. I'm editing the page in Dreamweaver,
not Note Pad. Does that make a difference? It was that one lone <
character, right? It seems that Dreamweaver won't let me save the page
with that character for some reason. Also, after failing to upload the
Dreamweaver-created file to my FTP, I tried to upload it through
Blogger.com and I got this message (again):
msxml3.dll error '80072efd' 
A connection with the server could not be established 
functions/getTemplate.inc, line 35 
Help!

Request for Question Clarification by errol-ga on 25 May 2003 16:15 PDT
Hi there.

We will get there eventually, download this file (right click and
select "save as" - don't left click) then upload it in place of the
one currently there.
http://homepage.ntlworld.com/r.s.mahoney/ga/archive.html
Please back the old one up first!

errol-ga.

Clarification of Question by nealysmith79-ga on 25 May 2003 16:16 PDT
Arrgh. This is so frustrating! I have tried to save the document
several times, and when I reopen it, the is file missing the < tag. I
don't have BBEdit. Any other thoughts?

Clarification of Question by nealysmith79-ga on 25 May 2003 16:18 PDT
Hi! I just got your post. I use a Mac. Sould I just copy the source code?

Request for Question Clarification by errol-ga on 25 May 2003 16:24 PDT
I had the problem with the tag "<" being put back too but I had to
alter some of the code above that to prevent it from happening.

Try this:

Left click on the URL then go to File>Save As and call the page
"archive.html" (assuming you're using IE).

Clarification of Question by nealysmith79-ga on 25 May 2003 16:27 PDT
I'm using IE, but I can't left click (Mac, you know). I did a save as
and uploaded the resulting file, but it's still not working.

Clarification of Question by nealysmith79-ga on 25 May 2003 16:30 PDT
Now the menu bar has disappeared entirely! Yikes!

Request for Question Clarification by errol-ga on 25 May 2003 16:36 PDT
Try saving the script again from that URL.
I noticed another missing tag at the end of the form.

Clarification of Question by nealysmith79-ga on 25 May 2003 16:43 PDT
Still no luck. Just to be clear, this is the file I'm attempting to update:
http://www.sickcandy.com/archives/archive.html
Thanks...

Request for Question Clarification by errol-ga on 25 May 2003 16:54 PDT
Hi!

Try it again, I've altered the code a bit more.

Clarification of Question by nealysmith79-ga on 25 May 2003 17:01 PDT
*sigh* Still no luck...

Request for Question Clarification by errol-ga on 25 May 2003 17:07 PDT
OK.

Give me some time (about a day or two) and I'll custom write it for
you.
The only drawback will be that it will depend on the person viewing
the page to have their system time and date set correctly because I'll
make it dynamically generate the archive links in the menu depending
on what the current date is.

errol-ga.

Clarification of Question by nealysmith79-ga on 25 May 2003 17:11 PDT
That sounds great! As long as it works, I'm not too worried about the
specifics of the dates. I really appreciate your help with this... I
spent (no kidding) 14 hours yesterday trying to figure it out on my
own and finally had the sense to give up. I really appreciate your
hard work and quick responses. I'll talk with you again in a day or
two...

Clarification of Question by nealysmith79-ga on 25 May 2003 21:25 PDT
Hi errol!

I discovered a couple of things since we last chatted. First, it seems
the files I FTP'd took a while to kick in. I suspect that Blogger
collects files from outside servers every 10 minutes or so. The last
file that was there had a lot of code on the left side of the page. To
make the site pretty while we're working the problem out, I put up a
file that would make the javascript invisible (I hope this makes
sense!) It worked, but when I added a new post through Blogger, it
seemed to generate an archive.html file that I created eons ago on
their server. I think that I have to upload the archive.html file on
to the Blogger 'archive template' area. I hope this makes some sense.
I really want this to work!

Clarification of Question by nealysmith79-ga on 26 May 2003 10:59 PDT
A couple more things that may be relevant... I checked with a Blogger
support group:

http://groups.yahoo.com/group/blogger_user_support/

and it seems the template server is down, hence the: 

"msxml3.dll error '80072efd' 
A connection with the server could not be established 
/functions/getTemplate.inc, line 35 "

message.  Through trial & error, I think that I figured out that you
have to upload the archive.html code to the Blogger template server
not the FTP, which would explain why we were having so much trouble
today. I suspect that once Blogger fixes the problem, I can upload a
template (with the < symbol) and I think that it may work.

This is pretty new to me, so I hope that I'm explaining myself well.
Does what I just said make sense? Please let me know!

Thanks!!!

Request for Question Clarification by errol-ga on 26 May 2003 18:10 PDT
Hi!

Another researcher let me know that Blogger were having problems so I
thought I'd wait a while but I did make this basic menu script for
you.
The drawback is that it relies on you editing the file and inputting
the URLs and dates manually but it does work and I designed it to
match your website.
You will have to make sure Blogger does not upload "archive.html",
select "no" fom the Archive settings so it will not overwrite this
file.

- - - - Copy and paste from below and save it as "archive.html" - - -
-

<!--

// === Website Settings === //

var WebsiteURL = "http://www.sickcandy.com"
var ArchivePath = "/archives/"

// === The Form Colors === //

var BackgroundColor = "#FFCCFF"
var TextColor = "#000000"



var ArchiveURLS = new Array(



// === Enter URLS for the archive files below with no comma after the
last one === //

"2003_05_11_archive.html",
"2003_05_18_archive.html",
"2003_05_25_archive.html"



)



var ArchiveNames = new Array(



// === Enter dates for the Archives below with no comma after the last
one === //

"11 - 17 May",
"18 - 24 May",
"25 May - 1 June"



)



// Creating Menu

function GoToURL()
{
URL=document.forms[0].ArchiveMenu.value
window.location.href=URL
}


document.write("<form>")
document.write("<select style=\"background:" + BackgroundColor + ";
color: " + TextColor + ";\" name=\"ArchiveMenu\"
onchange=\"GoToURL()\">")
document.write("<option value=\"#\" selected> - - Archives - - ")
document.write("<option value=\"#\"> ")

for (i=0; i<ArchiveURLS.length; i++)
{

document.write("<option value=\"" + WebsiteURL + ArchivePath +
ArchiveURLS[i] + "\">" + ArchiveNames[i])

}
document.write("</select>")
document.write("</form>")

// -->

Clarification of Question by nealysmith79-ga on 26 May 2003 18:36 PDT
Hi errol,
Quick question-- What will happen to my future archives if I use this method?

Request for Question Clarification by errol-ga on 26 May 2003 18:41 PDT
I think it will always archive the actual blog, it just won't create
or overwrite the archive.html file.
I created a Blogger account for the purpose of testing it and it
looked like that was the case, although I can't be sure unless I leave
it for more than a week.

Clarification of Question by nealysmith79-ga on 26 May 2003 18:54 PDT
Will I have to hand code the archive date

"2003_05_11_archive.html", 
"2003_05_18_archive.html", 
"2003_05_25_archive.html" 
 
every week? I hope not!

Request for Question Clarification by errol-ga on 26 May 2003 19:11 PDT
Yes, unfortunately.
To be honest, I'd wait until Blogger sort out their problems.
That script is just something which you could use as an alternative.

Clarification of Question by nealysmith79-ga on 26 May 2003 19:20 PDT
That sounds like a good plan. Is it okay to keep this question open
until they solve their problems (whenever that may be)?

Request for Question Clarification by errol-ga on 26 May 2003 19:25 PDT
That's fine by me!

If somebody has a good way to answer the question I'd be interested to know too.

errol-ga.

Clarification of Question by nealysmith79-ga on 26 May 2003 19:27 PDT
Thanks for all of your help, errol! I hope that we can solve it once
the dust settles.
Answer  
There is no answer at this time.

Comments  
There are no comments at this time.

Important Disclaimer: Answers and comments provided on Google Answers are general information, and are not intended to substitute for informed professional medical, psychiatric, psychological, tax, legal, investment, accounting, or other professional advice. Google does not endorse, and expressly disclaims liability for any product, manufacturer, distributor, service or service provider mentioned or any opinion expressed in answers or comments. Please read carefully the Google Answers Terms of Service.

If you feel that you have found inappropriate content, please let us know by emailing us at answers-support@google.com with the question ID listed above. Thank you.
Search Google Answers for
Google Answers  


Google Home - Answers FAQ - Terms of Service - Privacy Policy