Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Javascript > which doctype to use?? and one other

Reply
Thread Tools

which doctype to use?? and one other

 
 
bbxrider
Guest
Posts: n/a
 
      08-09-2003
this is my first page so i'm terribly lost on which doctype to use, i'm
hoping there's a basic type that doesn't require hours of research
i had been using,
<!DOCTYPE html
PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<!-- -->
<HTML>
but that stopped working and now can't seem to find one that works
it also started invoking the post - action, even when the validation is
returning false?? that is really weird

with different doc types it then asks for a coding reference?
its a pretty basic page, with a medium size form
http://job1data.com/phsvolunteer.htm


and this code seems to work fine in the page but the validator has it pegged
as an error, i was hoping to use jscript to avoid all the coding for dates
it seemed an easy way to build a larger select list
</SELECT>
year* <SELECT size=1 name="dobYYYY">
<script type="text/javascript">
d = new Date();
var year = d.getFullYear();
year = parseFloat(year);
for (i = year; i > (year - 80) ; i--) {
document.write("<OPTION> " + i);
}
</script>
</SELECT>


 
Reply With Quote
 
 
 
 
bbxrider
Guest
Posts: n/a
 
      08-09-2003
thanks for the help, i will have to try it but am guessing if i execute the
javascript, runat=server,
the actual html will be generated at the server, so the 'completed' page
will be delivered to the
client browser and thanks for the short cut tip on the date
"Dr John Stockton" <(E-Mail Removed)> wrote in message
news:A3BMBeFYnPN$Ew$(E-Mail Removed)...
> JRS: In article <ZKXYa.67820$(E-Mail Removed) >, seen
> in news:comp.lang.javascript, bbxrider <(E-Mail Removed)> posted at
> Sat, 9 Aug 2003 01:02:49 :-
>
> >d = new Date();
> >var year = d.getFullYear();
> >year = parseFloat(year);

>
> parseFloat() serves no useful purpose there.
>
> You could use
> year = new Date().getFullYear()
> or
> year = (D=new Date()).getFullYear()
>
> --
> John Stockton, Surrey, UK. ?@merlyn.demon.co.uk Turnpike v4.00 IE

4
> <URL:http://jibbering.com/faq/> Jim Ley's FAQ for

news:comp.lang.javascript
> <URL:http://www.merlyn.demon.co.uk/js-index.htm> JS maths, dates,

sources.
> <URL:http://www.merlyn.demon.co.uk/> TP/BP/Delphi/JS/&c., FAQ topics,

links.


 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
CSS Newbie - CSS Works With Invalid DOCTYPE. Fails With Valid DOCTYPE. Larry Lindstrom HTML 19 06-12-2012 02:07 PM
validation of XML document which does not contain DOCTYPE declaration mnshtiwari XML 0 04-16-2009 07:39 AM
What for does one need doctype? test@loctopus.com HTML 17 05-25-2006 09:41 AM
Microcontrollers: which one ? which language ? which compiler ? The Jesus of Suburbia NZ Computing 2 02-11-2006 06:53 PM
Which doctype do I use? Jim Scott HTML 5 09-10-2005 07:50 PM



Advertisments