Help before I throw my laptop out high rise window.

Status
Not open for further replies.


Can you be a tad more specific, like which one of the dozen inline javascript you are having a problem with?

Also have you thought about using something more cross-browser compatible, like Jquery, mootools, dojo or the prototype frame work?
 
It looks like your problem is here, FireBug in FireFox reported it as an unterminated string literal.

Code:
336 cal = '<html><head><title>Calendar</title></head><body>';
337 cal += "<style>a:link{cursor: hand}a:active{cursor: hand}a:hover{cursor: hand}a:visited{cursor: hand}body{cursor: default}.style24 {font-size: 18px;
338 font-weight: bold;
339 }
340 .style26 {font-size: 14px; background: #FFFFFF;}
341 .style27 {font-size: 18px; color: #074D91; font-weight: bold; }
342 </style>";

the error said:
unterminated string literal
[Break on this error] cal += "<style>a:link{cursor: hand}a:ac...sor: default}.style24 {font-size: 18px;\n

Meaning there was no closing " at the end of that, basically when you created a new line at font: bold; it caught } at line 339 and thought that was the end of the function. As a result you may need to make sure that entire code sniplet is on one line.
 
It looks like your problem is here, FireBug in FireFox reported it as an unterminated string literal.

Code:
336 cal = '<html><head><title>Calendar</title></head><body>';
337 cal += "<style>a:link{cursor: hand}a:active{cursor: hand}a:hover{cursor: hand}a:visited{cursor: hand}body{cursor: default}.style24 {font-size: 18px;
338 font-weight: bold;
339 }
340 .style26 {font-size: 14px; background: #FFFFFF;}
341 .style27 {font-size: 18px; color: #074D91; font-weight: bold; }
342 </style>";



Meaning there was no closing " at the end of that, basically when you created a new line at font: bold; it caught } at line 339 and thought that was the end of the function. As a result you may need to make sure that entire code sniplet is on one line.

I tried fixing that but still getting an error the same error. I fucking hate code.
 
need a closing css brace, quote and semicolon at the end of that line...

cal += "<style>a:link{cursor: hand}a:active{cursor: hand}a:hover{cursor: hand}a:visited{cursor: hand}body{cursor: default}.style24 {font-size: 18px;font-weight: bold;

should be:

cal += "<style>a:link{cursor: hand}a:active{cursor: hand}a:hover{cursor: hand}a:visited{cursor: hand}body{cursor: default}.style24 {font-size: 18px;font-weight: bold;}";
 
need a closing css brace, quote and semicolon at the end of that line...

cal += "<style>a:link{cursor: hand}a:active{cursor: hand}a:hover{cursor: hand}a:visited{cursor: hand}body{cursor: default}.style24 {font-size: 18px;font-weight: bold;

should be:

cal += "<style>a:link{cursor: hand}a:active{cursor: hand}a:hover{cursor: hand}a:visited{cursor: hand}body{cursor: default}.style24 {font-size: 18px;font-weight: bold;}";

Note my post above his last one... it doesn't end at font-weight:bold; he has more css shortly after it. He just didn't put it all on the same line.
 
need a closing css brace, quote and semicolon at the end of that line...

cal += "<style>a:link{cursor: hand}a:active{cursor: hand}a:hover{cursor: hand}a:visited{cursor: hand}body{cursor: default}.style24 {font-size: 18px;font-weight: bold;

should be:

cal += "<style>a:link{cursor: hand}a:active{cursor: hand}a:hover{cursor: hand}a:visited{cursor: hand}body{cursor: default}.style24 {font-size: 18px;font-weight: bold;}";


Tried that too, still no dice. It's definitely something that has to do with the javascript calendar function.

Any other ideas?
 
Status
Not open for further replies.