Hi Spartanicus,
Yes \n is a newline in the code but it only represents "white space" in html
and is not equal to <br> so should not visibly display a new line in the
browser.
Also I have removed the \n from the code with no change to the display...
Tobierre
----- Original Message -----
From: "Spartanicus" <in*****@invalid.invalid>
Newsgroups: comp.lang.javascript
Sent: Tuesday, October 04, 2005 9:09 AM
Subject: Re: .js include creates extra line in html display
"Tobierre" <No******@hotmail.com> wrote:
In a web page I have created I have included a .js file in the body
section
of the page with the below JavaScript code. The code works fine, but
creates an extrra blank line at the bottom of the web page! Does anyone
know why this is happening?
Any help kindly appreciated
Tobierre
- document.write('<img width="1" height="1"
- src="http://www.mydomain.com/log_analysis_screen_info.gif?' + 'width=' +
- screen.width + '&height=' + screen.height + '&depth=' + screen.colorDepth
- +
- '">\n');
Remove the "\n" at the end of the code.
--
Spartanicus
"Spartanicus" <in*****@invalid.invalid> wrote in message
news:q9********************************@news.spart anicus.utvinternet.ie... "Tobierre" <No******@hotmail.com> wrote:
In a web page I have created I have included a .js file in the body
section
of the page with the below JavaScript code. The code works fine, but
creates an extrra blank line at the bottom of the web page! Does anyone
know why this is happening?
Any help kindly appreciated
Tobierre
- document.write('<img width="1" height="1"
- src="http://www.mydomain.com/log_analysis_screen_info.gif?' + 'width=' +
- screen.width + '&height=' + screen.height + '&depth=' + screen.colorDepth
- +
- '">\n');
Remove the "\n" at the end of the code.
--
Spartanicus