472,129 Members | 1,581 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,129 software developers and data experts.

how to set browser window attributes in this HTML code?

Hi There,

Prob a simple answer to this (I hope) but I can't quite work it out yet...

I have this in a page:

<map name="Map">
<area shape="rect" coords="43,68,52,77" href="map.html" target="_blank"
alt="Link to map">
</map>

I want the page "map.html" to load into a new browser window, and set the
new browser window to be the size required to just fit the map, and turn off
the unwanted toolbars. (I just want a simple window to show the map in)

How can I do this please?

Thanks.
Jul 23 '05
68 10964
In article <I8L0e.16546$fn3.3307@attbi_s01>,
"c.thornquist" <c.**********@insightbb.com> wrote:

I'm not sure what you mean. What could I have used in place of the
javascript I used in the pop-ups on this page (
http://www.dandefurniture.com/DE_Dick_Idol.html ) ? I do not want the page
any longer than it already is & as a web surfer, I prefer to click to a
smallish pop-up...
As a web-surfer, you can already open links in a new window if you want
to. You have the capability: you have the choice.
Why open a new page for one small image?
A pop-up is a new page. It's just that the size of the canvas is
(possibly) smaller than that of the spawning window. But, under the
covers, there is nothing different about loading content into a popup or
into a "new page": same content, same HTTP request/reply, same rendering
engine, etc.
What about "today's date" on pages? Can that be coded w/o javascript?


Sure (do it server-side), although I'd question whether there's any
point in attempting it at all. Does your computer not have a convenient
way of telling you the correct date and time?

--
Joel.
Jul 23 '05 #51

"Joel Shepherd" <jo******@ix.netcom.com> wrote in message
news:jo****************************@news1.west.ear thlink.net...
In article <I8L0e.16546$fn3.3307@attbi_s01>,
"c.thornquist" <c.**********@insightbb.com> wrote:

I'm not sure what you mean. What could I have used in place of the
javascript I used in the pop-ups on this page (
http://www.dandefurniture.com/DE_Dick_Idol.html ) ? I do not want the
page
any longer than it already is & as a web surfer, I prefer to click to a
smallish pop-up...
As a web-surfer, you can already open links in a new window if you want
to. You have the capability: you have the choice.
Why open a new page for one small image?


A pop-up is a new page. It's just that the size of the canvas is
(possibly) smaller than that of the spawning window. But, under the
covers, there is nothing different about loading content into a popup or
into a "new page": same content, same HTTP request/reply, same rendering
engine, etc.


Thanks for explaining that. Does that mean we are back to the original topic
of this thread? I've been following the thread, but didn't see an answer (a
way to control the new window size with HTML).
What about "today's date" on pages? Can that be coded w/o javascript?


Sure (do it server-side), although I'd question whether there's any
point in attempting it at all. Does your computer not have a convenient
way of telling you the correct date and time?


I wouldn't want to use server side just for the date. I think the date thing
is just a trick to make a page appear updated. I see it used on some news
sites.

Thanks much,

Carla
Jul 23 '05 #52
me
"Joel Shepherd" <jo******@ix.netcom.com> wrote in message
news:jo****************************@news1.west.ear thlink.net...
In article <I8L0e.16546$fn3.3307@attbi_s01>,
"c.thornquist" <c.**********@insightbb.com> wrote:

I'm not sure what you mean. What could I have used in place of the
javascript I used in the pop-ups on this page (
http://www.dandefurniture.com/DE_Dick_Idol.html ) ? I do not want the page any longer than it already is & as a web surfer, I prefer to click to a
smallish pop-up...


As a web-surfer, you can already open links in a new window if you want
to. You have the capability: you have the choice.


Fair enough, but that wasn't what she asked and it wouldn't achieve her
stated goal.
Why open a new page for one small image?


A pop-up is a new page. It's just that the size of the canvas is
(possibly) smaller than that of the spawning window. But, under the
covers, there is nothing different about loading content into a popup or
into a "new page": same content, same HTTP request/reply, same rendering
engine, etc.


Fair enough but again she asked for a way to code a popup that would fit her
needs without JS and your answer doesn't achieve that goal.

Just like Carla I prefer JS to popup a new smaller window to display some
images. IMO it's more esthetically pleasing and less jarring than reloading
the entire page. It has another advantage in that user still sees the
original page and can quickly return to it. This method is widely used and
most users are already familiar with the concept therefore it seems
perfectly natural to them.
Signed,
me
Jul 23 '05 #53
me
"c.thornquist" <c.**********@insightbb.com> wrote in message
news:KeQ0e.17456$fn3.3968@attbi_s01...
"Joel Shepherd" <jo******@ix.netcom.com> wrote in message
news:jo****************************@news1.west.ear thlink.net...
In article <I8L0e.16546$fn3.3307@attbi_s01>,
"c.thornquist" <c.**********@insightbb.com> wrote:
[snip]
What about "today's date" on pages? Can that be coded w/o javascript?
Sure (do it server-side), although I'd question whether there's any
point in attempting it at all. Does your computer not have a convenient
way of telling you the correct date and time?


I wouldn't want to use server side just for the date. I think the date

thing is just a trick to make a page appear updated. I see it used on some news
sites.

Thanks much,
Carla


Indeed, upon seeing the current date visitors might assume that the page was
just modified.

As an aside, clients have asked me if I could display a date when the page
was last modified. I tell them that if they expect to update their pages
frequently this may be a good thing but if they don't then the only thing
they'll accomplish is to give visitors the impression that the site isn't
changing or that it's been neglected by the owner.
Signed,
me
Jul 23 '05 #54
"me" <anonymous@_.com> wrote:
Just like Carla I prefer JS to popup a new smaller window to display
some images. IMO it's more esthetically pleasing and less jarring than
reloading the entire page.
But IMO it's even more pleasing to open the image in a new tab,
and I can't do that if the link is a JS string instead of a
normal url.

Even if you dismiss the existance of non-IE browsers, IE7 will
reportedly add tab support, so it's something you might want
to be planning for.
--;k

Jul 23 '05 #55
c.thornquist wrote:
"Lachlan Hunt" <sp***********@gmail.com> wrote in message
news:42***********************@per-qv1-newsreader-01.iinet.net.au...
Well written HTML, CSS and JS that is completely, separated from each
other is usually very close to, if not completely, accessible to those
without one or the other;
I'm not sure what you mean. What could I have used in place of the
javascript I used in the pop-ups on this page (
http://www.dandefurniture.com/DE_Dick_Idol.html ) ?


While I don't approve of opening popups at all, and have configured my
browser to *never* open a popup under any circumstances, there are ways
to achieve your goal in an accessible way, one which I have very quickly
written, although it still needs some additional work.
...as a web surfer, I prefer to click to a smallish pop-up, rather
than move to a new page to view the individual small images.
The key to that sentence is "as a web surfer", yet you want to make the
same choice for other users when you are the author.
Why open a new page for one small image?
Personally, I prefer to do so; but as stated, your preferences (like
everyone elses) differ and, as a user, you should have the right to make
such decisions without an author deciding for you.
Is there a way to code the pop-up using HTML?
Using the target attribute is about as close as you can get, but you
have no ability to suggest any of the window properties (eg. size,
position, etc) as you do with JavaScript.

Ok, now to the solution I have quickly written. As I said, it needs
some work, but this should be considered as a proof-of-concept. My
tests worked well in both Firefox and Opera, both of which have very
good DOM support, though there are still issues with IE that need to be
worked out and possibly other browsers I have not tested.

The Markup:
(Note: I've used the id attribute for simplicity so that I could use
getElementById() to access it with the script. It's not required if you
access the element in another way.)

<ul id="fruit">
<li><a href="apple.jpg" title="Photo of a Big Red Apple">Apple</a></li>
<li><a href="orange.jpg" title="Photo of a Small Orange">Orange</a></li>
<li><a href="banana.jpg" title="Photo of a Banana">Banana</a></li>
</ul>

The Script:
/*
* attachEvents() dynamically attaches the "onclick" events
* to the links, which will open the new windows when the
* link is clicked.
*/
function attachEvents(list) {
var links = list.getElementsByTagName("a");
if (links.length > 0 && links[0].addEventListener) {
for (var i = 0; i < links.length; i++) {
links[i].addEventListener("click", popup, false);
}
return true;
} else {
return false;
}
}

/*
* This function handles the click event for the links
*/
function popup(e) {
var win;
var prop =
"scrollbars=yes,menubar=no,resizable=yes,height=41 0,width=450";
if (win = window.open(this.getAttribute("href"), "image", prop)) {
// Use win for any further scripting related to the
// newly created window, if needed.
// eg. You may set the new window's title based on the title
// attribute in the link using this.getAttribute("title");

// Stop the default action. Equivalent effect to "return false;",
// often used within the onclick="...;return false;" attribute.
e.preventDefault();
}
}

/*
* Initialisation function called when the document loads
*/
function init() {
if (document.getElementById) {
attachEvents(document.getElementById("fruit"));
}
}

/*
* Attach the onload event to the window, which is similar to using
* the onload attribute in the body element.
* I know it uses the non-standard window interface, but I'm unaware of
* a standards-compliant method to achieve this. If anyone does, please
* let me know.
*/
window.onload = init;

I used javascript for nav bars in which the table cells changed color on
hover, until I stumbled on some code used by Microsoft in my inbox of
HotMail.
I wouldn't trust any code you found on the hotmail website, last time I
saw it (though, it has been a while since I've had a hotmail account),
it was quite awful and nothing that should be copied by anyone. Please
correct me if Hotmail have since adopted standards, but I don't believe
they have.

Such effects can be achieved using the :hover pseudo-class in CSS.
However, support for it is limited in IE and may require some additional
JS to back it up. Although i suggest you ask for more advice about this
in a stylesheets related group.
What about "today's date" on pages? Can that be coded w/o javascript?
What's the point? Both my computer and my watch let me know the date
and time just fine. Seeing the current date on a web page is
meaningless unless it actually indicates something useful about the
document. eg. It's creation date, last modified date or whatever.
Usually, such dates are not the same as the current date (unless, of
course, the user happens to visit on the date of publication).
I'm not being sarcastic or contrary. I just want to know.


I didn't think you were being sarcastic or contrary, you asked some fair
questions and have shown some willingness to learn! :-)

--
Lachlan Hunt
http://lachy.id.au/
http://GetFirefox.com/ Rediscover the Web
http://GetThunderbird.com/ Reclaim your Inbox
Jul 23 '05 #56
In article <11*************@corp.supernews.com>, "me" <anonymous@_.com>
wrote:
"Joel Shepherd" <jo******@ix.netcom.com> wrote:

As a web-surfer, you can already open links in a new window if you want
to. You have the capability: you have the choice.


Fair enough, but that wasn't what she asked and it wouldn't achieve her
stated goal.


This is a newsgroup. Things are discussed. There's no guarantee or
requirement that the discussion directly address the original OP's
inquiry. (Looking back over the thread, it looks like early on the OP
essentially answered their own question anyway.)

Beyond that, in the post I was replying to, it appeared that the author
was under the impression that loading a popup was somehow different from
loading any other page, and it's not. So I attempted to clear up that
bit of confusion. Again: discussion, and perfectly acceptable here.

Thank you for observing that I did not give a help-desk'esque response.
Your implication that doing so wasn't helpful, though, is off the mark.
And, in any event, who appointed you to be judge of the appropriateness
of others' contributions?

--
Joel.
Jul 23 '05 #57
In article <MP********************@texas.net>, ma**********@yahoo.com
enlightened us with...
"me" <anonymous@_.com> wrote:
Just like Carla I prefer JS to popup a new smaller window to display
some images. IMO it's more esthetically pleasing and less jarring than
reloading the entire page.


But IMO it's even more pleasing to open the image in a new tab,
and I can't do that if the link is a JS string instead of a
normal url.


A designer can support both by using real links as well as an onclick, i.e.

<a href="theImg.jpg" onClick="myOpenFunction('theImg.jpg');return false;><img
src='theImgThumb.jpg"></a>

An added advantage is that it will also work for users without javascript
enabled.

--
--
~kaeli~
If God dropped acid, would he see people?
http://www.ipwebdesign.net/wildAtHeart
http://www.ipwebdesign.net/kaelisSpace

Jul 23 '05 #58
me
"Mad Bad Rabbit" <ma**********@yahoo.com> wrote in message
news:MP********************@texas.net...
"me" <anonymous@_.com> wrote:
Just like Carla I prefer JS to popup a new smaller window to display
some images. IMO it's more esthetically pleasing and less jarring than
reloading the entire page.
But IMO it's even more pleasing to open the image in a new tab,
and I can't do that if the link is a JS string instead of a
normal url.


Fair enough. As an aside it can be done but not easily (and without JS
disabled).
Even if you dismiss the existance of non-IE browsers, IE7 will
reportedly add tab support, so it's something you might want
to be planning for.


Possibly, but I suspect IE7 will still support JS popups.
Signed,
me
Jul 23 '05 #59
me
"Joel Shepherd" <jo******@ix.netcom.com> wrote in message
news:jo****************************@news1.west.ear thlink.net...
In article <11*************@corp.supernews.com>, "me" <anonymous@_.com>
wrote:
"Joel Shepherd" <jo******@ix.netcom.com> wrote:

As a web-surfer, you can already open links in a new window if you want to. You have the capability: you have the choice.
Fair enough, but that wasn't what she asked and it wouldn't achieve her
stated goal.


This is a newsgroup. Things are discussed. There's no guarantee or
requirement that the discussion directly address the original OP's
inquiry.


Fair enough.
(Looking back over the thread, it looks like early on the OP
essentially answered their own question anyway.)
True, but in the post you replied to Carla said: "I've been following the
thread, but didn't see an answer (a way to control the new window size with
HTML)." And that question is the title of this thread.
Beyond that, in the post I was replying to, it appeared that the author
was under the impression that loading a popup was somehow different from
loading any other page, and it's not. So I attempted to clear up that
bit of confusion.
I didn't get that impression. And IMO Carla wasn't confused. She did say
"*Why* open a new page for one small image?" and you said "A pop-up is a new
page". But that statement doesn't relate to her query about *why*.
Again: discussion, and perfectly acceptable here.
No arguement there.
Thank you for observing that I did not give a help-desk'esque response.
OK, maybe I misunderstood you. I got the impression you were trying to
answer her question. I just observed that your reply was IMO not an answer
to her question.
Your implication that doing so wasn't helpful, though, is off the mark.
And, in any event, who appointed you to be judge of the appropriateness
of others' contributions?


I made no judgements. Like you, I made a post containing my observations.
Such occurrences are common in Usenet. l see no reason for conflict.
Signed,
me
Jul 23 '05 #60
me
"Lachlan Hunt" <sp***********@gmail.com> wrote in message
news:42***********************@per-qv1-newsreader-01.iinet.net.au...
c.thornquist wrote:
"Lachlan Hunt" <sp***********@gmail.com> wrote in message
news:42***********************@per-qv1-newsreader-01.iinet.net.au...
Well written HTML, CSS and JS that is completely, separated from each
other is usually very close to, if not completely, accessible to those
without one or the other;


I'm not sure what you mean. What could I have used in place of the
javascript I used in the pop-ups on this page (
http://www.dandefurniture.com/DE_Dick_Idol.html ) ?


While I don't approve of opening popups at all, and have configured my
browser to *never* open a popup under any circumstances, there are ways
to achieve your goal in an accessible way, one which I have very quickly
written, although it still needs some additional work.


When you say accessible I assume you mean that the script/method you suggest
will work regardless of whether the user has JS enabled or not. I further
asume that users without JS will see the image in a normal size window with
controls bars etc visible correct?
Signed,
me
...as a web surfer, I prefer to click to a smallish pop-up, rather
than move to a new page to view the individual small images.


The key to that sentence is "as a web surfer", yet you want to make the
same choice for other users when you are the author.
Why open a new page for one small image?


Personally, I prefer to do so; but as stated, your preferences (like
everyone elses) differ and, as a user, you should have the right to make
such decisions without an author deciding for you.
Is there a way to code the pop-up using HTML?


Using the target attribute is about as close as you can get, but you
have no ability to suggest any of the window properties (eg. size,
position, etc) as you do with JavaScript.

Ok, now to the solution I have quickly written. As I said, it needs
some work, but this should be considered as a proof-of-concept. My
tests worked well in both Firefox and Opera, both of which have very
good DOM support, though there are still issues with IE that need to be
worked out and possibly other browsers I have not tested.

The Markup:
(Note: I've used the id attribute for simplicity so that I could use
getElementById() to access it with the script. It's not required if you
access the element in another way.)

<ul id="fruit">
<li><a href="apple.jpg" title="Photo of a Big Red Apple">Apple</a></li>
<li><a href="orange.jpg" title="Photo of a Small Orange">Orange</a></li>
<li><a href="banana.jpg" title="Photo of a Banana">Banana</a></li>
</ul>

The Script:
/*
* attachEvents() dynamically attaches the "onclick" events
* to the links, which will open the new windows when the
* link is clicked.
*/
function attachEvents(list) {
var links = list.getElementsByTagName("a");
if (links.length > 0 && links[0].addEventListener) {
for (var i = 0; i < links.length; i++) {
links[i].addEventListener("click", popup, false);
}
return true;
} else {
return false;
}
}

/*
* This function handles the click event for the links
*/
function popup(e) {
var win;
var prop =
"scrollbars=yes,menubar=no,resizable=yes,height=41 0,width=450";
if (win = window.open(this.getAttribute("href"), "image", prop)) {
// Use win for any further scripting related to the
// newly created window, if needed.
// eg. You may set the new window's title based on the title
// attribute in the link using this.getAttribute("title");

// Stop the default action. Equivalent effect to "return false;",
// often used within the onclick="...;return false;" attribute.
e.preventDefault();
}
}

/*
* Initialisation function called when the document loads
*/
function init() {
if (document.getElementById) {
attachEvents(document.getElementById("fruit"));
}
}

/*
* Attach the onload event to the window, which is similar to using
* the onload attribute in the body element.
* I know it uses the non-standard window interface, but I'm unaware of
* a standards-compliant method to achieve this. If anyone does, please
* let me know.
*/
window.onload = init;

I used javascript for nav bars in which the table cells changed color on
hover, until I stumbled on some code used by Microsoft in my inbox of
HotMail.


I wouldn't trust any code you found on the hotmail website, last time I
saw it (though, it has been a while since I've had a hotmail account),
it was quite awful and nothing that should be copied by anyone. Please
correct me if Hotmail have since adopted standards, but I don't believe
they have.

Such effects can be achieved using the :hover pseudo-class in CSS.
However, support for it is limited in IE and may require some additional
JS to back it up. Although i suggest you ask for more advice about this
in a stylesheets related group.
What about "today's date" on pages? Can that be coded w/o javascript?


What's the point? Both my computer and my watch let me know the date
and time just fine. Seeing the current date on a web page is
meaningless unless it actually indicates something useful about the
document. eg. It's creation date, last modified date or whatever.
Usually, such dates are not the same as the current date (unless, of
course, the user happens to visit on the date of publication).
I'm not being sarcastic or contrary. I just want to know.


I didn't think you were being sarcastic or contrary, you asked some fair
questions and have shown some willingness to learn! :-)

--
Lachlan Hunt
http://lachy.id.au/
http://GetFirefox.com/ Rediscover the Web
http://GetThunderbird.com/ Reclaim your Inbox

Jul 23 '05 #61
JRS: In article <11*************@corp.supernews.com>, dated Fri, 25 Mar
2005 08:24:11, seen in news:comp.infosystems.www.authoring.html, me
<anonymous@_.com> posted :

As an aside, clients have asked me if I could display a date when the page
was last modified. I tell them that if they expect to update their pages
frequently this may be a good thing but if they don't then the only thing
they'll accomplish is to give visitors the impression that the site isn't
changing or that it's been neglected by the owner.


You don't know as much as you should do, then.

Given the poor implementation of javascript lastModified in some
browsers, it can also give the impression that the page is of American
origin (even when it is not) or that it is over a hundred years old or
that the page author is totally incompetent. See below.

--
© John Stockton, Surrey, UK. ?@merlyn.demon.co.uk Turnpike v4.00 IE 4 ©
<URL:http://www.jibbering.com/faq/> JL/RC: FAQ of news:comp.lang.javascript
<URL:http://www.merlyn.demon.co.uk/js-index.htm> jscr maths, dates, sources.
<URL:http://www.merlyn.demon.co.uk/> TP/BP/Delphi/jscr/&c, FAQ items, links.
Jul 23 '05 #62
me wrote:
"Lachlan Hunt" <sp***********@gmail.com> wrote in message
news:42***********************@per-qv1-newsreader-01.iinet.net.au...
While I don't approve of opening popups at all,... there are ways
to achieve your goal in an accessible way...
When you say accessible I assume you mean that the script/method you suggest
will work regardless of whether the user has JS enabled or not.


Yes, the method degrades gracefully for users that override or don't
support the JavaScript methods used. Although I did use "accessible"
rather loosely, as true accessibility also depends on other things like
the availability of suitable alternate content for users that can't see
images, it is certainly more accessible and less irritating than using a
javascript: URI.
I further asume that users without JS will see the image in a normal size
window with controls bars etc visible correct?


Yes, for users without JavaScript or users that override window.open
(like myself), the links will behave as ordinary links to images.

BTW, c.thornquist, these articles may also be helpful for you:
http://alistapart.com/articles/popuplinks/
http://alistapart.com/articles/imagegallery/

--
Lachlan Hunt
http://lachy.id.au/
http://GetFirefox.com/ Rediscover the Web
http://GetThunderbird.com/ Reclaim your Inbox
Jul 23 '05 #63
me
"Dr John Stockton" <sp**@merlyn.demon.co.uk> wrote in message
news:kA**************@merlyn.demon.co.uk...
JRS: In article <11*************@corp.supernews.com>, dated Fri, 25 Mar
2005 08:24:11, seen in news:comp.infosystems.www.authoring.html, me
<anonymous@_.com> posted :

As an aside, clients have asked me if I could display a date when the pagewas last modified. I tell them that if they expect to update their pages
frequently this may be a good thing but if they don't then the only thing
they'll accomplish is to give visitors the impression that the site isn't
changing or that it's been neglected by the owner.
You don't know as much as you should do, then.


That sentence makes no sense.
Given the poor implementation of javascript lastModified in some
browsers, it can also give the impression that the page is of American
origin (even when it is not) or that it is over a hundred years old or
that the page author is totally incompetent.
When I said "display a date when the page was last modified" I didn't mean
with a script but I see now how that could have been inferred. My objection
to putting a date on a page is philosophical, if the page is infrequently
updated it looks bad.
See below.
See what below?
© John Stockton, Surrey, UK. ?@merlyn.demon.co.uk Turnpike v4.00 IE 4 © <URL:http://www.jibbering.com/faq/> JL/RC: FAQ of news:comp.lang.javascript <URL:http://www.merlyn.demon.co.uk/js-index.htm> jscr maths, dates, sources. <URL:http://www.merlyn.demon.co.uk/> TP/BP/Delphi/jscr/&c, FAQ items,

links.
Jul 23 '05 #64

"Lachlan Hunt" <sp***********@gmail.com> wrote in message
news:42***********************@per-qv1-newsreader-01.iinet.net.au...
me wrote:
"Lachlan Hunt" <sp***********@gmail.com> wrote in message
news:42***********************@per-qv1-newsreader-01.iinet.net.au...
While I don't approve of opening popups at all,... there are ways
to achieve your goal in an accessible way...


When you say accessible I assume you mean that the script/method you
suggest
will work regardless of whether the user has JS enabled or not.


Yes, the method degrades gracefully for users that override or don't
support the JavaScript methods used. Although I did use "accessible"
rather loosely, as true accessibility also depends on other things like
the availability of suitable alternate content for users that can't see
images, it is certainly more accessible and less irritating than using a
javascript: URI.
I further asume that users without JS will see the image in a normal size
window with controls bars etc visible correct?


Yes, for users without JavaScript or users that override window.open (like
myself), the links will behave as ordinary links to images.

BTW, c.thornquist, these articles may also be helpful for you:
http://alistapart.com/articles/popuplinks/
http://alistapart.com/articles/imagegallery/

--
Lachlan Hunt
http://lachy.id.au/
http://GetFirefox.com/ Rediscover the Web
http://GetThunderbird.com/ Reclaim your Inbox


Thanks for those links, Lachlan. I was searching for an image gallery just
like the one found at the 2nd link. I found that same script last week, but
I didn't know how to make the links horizontal instead of vertical. So, I
used a different script, which is unbelievably long. I decided to tell the
site owner to scrap the poll of images on the front page entirely. Here's
what I'm referring to: http://www.urban-outlet.com/

I suppose many here will think I shouldn't even be building sites with such
limited knowledge of coding. I want to learn more, but I have little free
time (hence to reliance on the 90% who use IE). I am trying to learn about
validating. On the site above, when I used the <!DOCTYPE HTML PUBLIC
"-//W3C//DTD HTML 4.01 Transitional//EN">, my HTML editor added lots of
additional styles(?) to my embedded stylesheet (is that what it is called)?

I just tried validating it & there are 30 errors. But most of the errors
shouldn't be errors. I mean the validator has allowed them before. I'm going
to try to run every page through the validator from now on & learn from it.
But I'm serious about not having much time. I can't repair the code on the
sites already up, but I'll try to validate any new sites. My intentions are
good, anyway:) Actually, I wanted to tackle validation years ago, but the
W3.org site has poor navigation & they don't explain things very well. But
I'm better at design than coding, so others probably find the W3 site
elementary.

thanks again,

carla
Jul 23 '05 #65
In article <11*************@corp.supernews.com>, anonymous@_.com enlightened
us with...
When I said "display a date when the page was last modified" I didn't mean
with a script but I see now how that could have been inferred. My objection
to putting a date on a page is philosophical, if the page is infrequently
updated it looks bad.
See below.


See what below?


One of the links in his signature is to the FAQ. Which contains:

4.30 How do I format Last Modified date with javascript

The format of the document.lastModified string is browser-dependent and
sometimes misleading to users. Apparently, new Date() appears to read it
correctly, apart from possible century error. In particular, time zone, field
order and separators may vary. It is also reliant on the server's clock
having been correctly set at the time of upload. See the URL below.
http://www.merlyn.demon.co.uk/js-date3.htm#lM

--
--
~kaeli~
If it's tourist season, why can't we shoot them?
http://www.ipwebdesign.net/wildAtHeart
http://www.ipwebdesign.net/kaelisSpace

Jul 23 '05 #66
me
"kaeli" <ti******@NOSPAM.comcast.net> wrote in message
news:MP************************@nntp.lucent.com...
In article <11*************@corp.supernews.com>, anonymous@_.com enlightened us with...
When I said "display a date when the page was last modified" I didn't mean with a script but I see now how that could have been inferred. My objection to putting a date on a page is philosophical, if the page is infrequently updated it looks bad.
See below.
See what below?


One of the links in his signature is to the FAQ. Which contains:

4.30 How do I format Last Modified date with javascript

The format of the document.lastModified string is browser-dependent and
sometimes misleading to users. Apparently, new Date() appears to read it
correctly, apart from possible century error. In particular, time zone,

field order and separators may vary. It is also reliant on the server's clock
having been correctly set at the time of upload. See the URL below.
http://www.merlyn.demon.co.uk/js-date3.htm#lM
--
~kaeli~


Thanks for the clarification.
Signed,
me
Jul 23 '05 #67
JRS: In article <MP************************@nntp.lucent.com>, dated
Mon, 28 Mar 2005 07:34:22, seen in news:comp.infosystems.www.authoring.h
tml, kaeli <ti******@NOSPAM.comcast.net> posted :
In article <11*************@corp.supernews.com>, anonymous@_.com enlightened
us with...
When I said "display a date when the page was last modified" I didn't mean
with a script but I see now how that could have been inferred. My objection
to putting a date on a page is philosophical, if the page is infrequently
updated it looks bad.
> See below.


See what below?


One of the links in his signature is to the FAQ. Which contains:

4.30 How do I format Last Modified date with javascript

The format of the document.lastModified string is browser-dependent and
sometimes misleading to users. Apparently, new Date() appears to read it
correctly, apart from possible century error. In particular, time zone, field
order and separators may vary. It is also reliant on the server's clock
having been correctly set at the time of upload. See the URL below.
http://www.merlyn.demon.co.uk/js-date3.htm#lM


The material is no longer at that location, but is now in js-date2.htm.

Of course, a page that has not been changed for a long while is not
necessarily bad; I seek certain Annexe material on the Web which dates
from 1582 and from 1751/2 - once that historical material is loaded,
there should be no need to change it.

--
© John Stockton, Surrey, UK. ?@merlyn.demon.co.uk Turnpike v4.00 IE 4 ©
<URL:http://www.jibbering.com/faq/> JL/RC: FAQ of news:comp.lang.javascript
<URL:http://www.merlyn.demon.co.uk/js-index.htm> jscr maths, dates, sources.
<URL:http://www.merlyn.demon.co.uk/> TP/BP/Delphi/jscr/&c, FAQ items, links.
Jul 24 '05 #68
rse
1
By modifying the following you should be able to achieve the desired effect(s):

var NewWindow = null;
function makeNewWindow(mypage, myname, w, h, scroll) {
var win_left = (screen.width - w) / 2;
var win_top = (screen.height - h) / 2;

winprops='height='+h+',width='+w+',top='+win_top+' ,left='+win_left+',scrollbars='+scroll+',toolbar=n o,location=no,status=no,menubar=no,resizable=yes,d ependent=no';

NewWindow=window.open(mypage, myname, winprops);
if (parseInt(navigator.appVersion) >= 4) {
NewWindow.window.focus();
}
}

where w is width in pixels, h is the height in pixels and scroll is yes or no.
Nov 7 '05 #69

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

13 posts views Thread by Kai Grossjohann | last post: by
14 posts views Thread by Gérard Talbot | last post: by
3 posts views Thread by Leonard | last post: by
6 posts views Thread by G Dean Blake | last post: by
reply views Thread by leo001 | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.