I am now using a strict !DOCTYPE and want to ensure that my pages comply. The Javascript I used to use no longer works - how can I seperate it from the structure of the page?
This <div> layer positioned always at bottom left of the screen on scrolling (and calling some code from labpixies) works well in non-ie browsers, but in ie it requires the omission of the doctype declaration. Why? Is it possible to fix it so that it works with the doctype in ie?
// This is asp.net snippet <marquee id="marqueeLeft" class="marqueestyle" direction="up" onmouseout="this.start();" onmouseover="this.stop();" scrolldelay="500" style="height: 99px; width: 100%;" > <asp:PlaceHolder ID="LeftPlaceHolder" runat="server"></asp:PlaceHolder> </marquee>
When I moved the pointer to this <marquee> tag. It shows the error message "Validation (xhtml 1.0 transitional) element marquee is not supported". When i run my web app it runs successfully but it gives jscript error as System.Argument Exception as value for controls and behaviors must not be null.
I am coding xhtml strict for my pages for the first time and I got some one problem with javascript:
I don't know how to modify the scripts to target elements on the page where the name attribute is deprecated.
Eg.
Code:
<form action="test.php" method="post"> <div><input name="text" /> <input type="submit" name="submit" value="search" /></div> </form> how can I modify the code to select such fild in such form ?
how I can get my custom attributes to validate in XHTML Strict? I have to have it validate as it is for a class.Example of the form:
HTML Code: input onkeyup="TF_filterTable(document.getElementById('dataTable'), filter)" size="40" tf_colkey="name"tf_searchtype="substring" /> Example of the JS:
Code: var inputs = frm.getElementsByTagName("INPUT"); for (var i=0;i<inputs.length;i++) { //looping thru all INPUT elements[code].........
I am using a javascript to validate that all form fields are filled in here:[URL].. The form input fields in the top div can be validated no problem. However, when I add to the javascript, this section of code:
Code: if (document.forms['secondform'].firstname.value=="") { themessage = themessage + " - First Name "; }
And so on for the next few input boxes, the javascript stops working entirely, passing the user onto the next page without actually validating the fields. I feel it is because I am not calling the input boxes correctly in the javascript, but I am unsure how to do it.
I was thinking that maybe because they are in a different division if I added that in there somewhere I could get it clear up, but no such luck yet.
I was able to achieve Collapsing/Expand at Project Level but not at the vendor level. However, same HTML works fine with IE 8 and FF. The Expand/Collapse at the Vendor Level fails with XHMTL Strict 1.0 and IE 7.
which is the best DOCTYPE to use with JavaScript?Just validating now and its telling me that the<body onLoad="startclock()"> onLoad attribute is not supported....
I was roughing out a feature I want to add to my site in notepad with no doctype declare.I got it just how I wanted, then realized it didn't work in IE. I added a doctype, it validates at xhtml strict, but it killed IE, while it started adding round corners in IE which wasn't working with no doctype...but now my JS isn't working... So I lost functionality of the JS while adding the round corner style that wasnt working when the JS was mostly working...FF works fine every damn way of course....I uploaded it to http://[url]......Also when it was functioning, the lower set of icons background wasn't showing. You can load that link ^^ in FF to see exactly what I'm going for....it works in ff
I have a javascript (snow.js) on my website. Without a DOCTYPE in my HTML it runs in IE, Mozilla and Chrome.Because my mouse-overs (hover) were not working in Chrome I needed to add a DOCTYPE, after it worked (DOCTYPE : <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http:[url].....).
But my javascipt still works in IE but not in Mozilla and Chrome anymore. This script runs with the following statements after <body> :
I had to add the following DOCTYPE to a webpage in order for IE to parse my page design properly, and this caused the form on the page to fail in FireFox (which works fine without the doctype). The form works fine in IE.Here is the DOCTYPE I added to the top of the page;
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
is it true that the doctype declaration must be on the very first line (there mustn't even be a blank line above it) in order for it to be "working correctly" ?
I have a section of Javascript code that works a treat in IE but does nothing in Firefox. If we remove the doctype it appears to work, put the doctype back in and it breaks. We need the doctype to remain in so the page renders correctly cross-browser. Code:
For a variety of reasons that I won't currently go into, I need a lightbox script that doesn't rely so heavy on the document's DOCTYPE (Strict, Transitional, etc) and will just work with a page where the DOCTYPE doesn't get assigned.
I am trying to display a map with Google maps. The code listed below is located at http:[url]....
Code: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">[code]....
I find another example where some uses a CDATA tag, but it still doesn't work. http:[url]...I finally remove the DOCTYPE and it works. http:[url]....My problem is I want the DOCTYPE.
I have a problem with customer website.My script creates an Auto-Greet that overlays the page, displays in the lower left of the browser and remains visible as the user scrolls the page.
My Mockup the customer home page. This is the desired action.http:[url]....Customer website: (undesired action)http:[url]....The only difference is that my customers does not declare a .dtd document.They have a <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">. On my mock-up, I declare a .dtd document and my script works.
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http:[url]...
Question: I'm trying to figure out a way in javacript to dynamically change the <!DOCTYPE, is this possible?
I have been attempting to transition to use of xhtml strict doctype andmy text editor, BBEdit (on Mac) tells me, when I ask it to check syntax,that the attribute 'name' is not allowed in form object, as in any otherform element that I tried to use it in. This begs the question, how doI script forms with javascript in the context of this doctype? None ofthe javascript texts I have address this issue (O'Reilly Rhino book andothers).I could figure it out, but it appears to be a complicated process, justdoing getElementById() and sorting it out.Does anyone have a reference to material that deals with this issue?
Without getting into too much history on the why, I came into a situation where I needed to create a function to get various properties of !DOCTYPE so that other functions could adjust to work properly with certain DOCTYPEs (Strict, Transitional, etc.). I have tested the function in the following Windows browsers IE6+ FF3+ Chrome2+ and Safari3+ Opera9+. The only one that I can’t get working is Opera (testing with 9.64). I’m hoping that someone out that has a solution! Here is the code:
I am trying to implement a floating menu with a strict doctype for HTML 4.01.
I have got it working without the doctype but as soon as I insert the doctype line it just falls flat on it's face, anyone know of a working floating menu for this situation?
I have an XML file that I'm trying to load into and xml object, however the doctype tag is killing the javascript, and does not parse the XML at all. If I remove the doctype, the javascript can parse, and I can access the XML DOM. So I know the XML is valid. Even with the Doctype, it validates. However Javascript does not like it. I don't have a choice to remove the Doctype tag of the XML.
If I remove the Doctype, this method works to parse the XML DOM: Code: xmlDoc = new ActiveXObject("Microsoft.XMLDOM"); xmlDoc.async = false; xmlDoc.load(filename);
Also, if I use the .open method to retrieve the XML, I cannot access the XML DOM via xmlhttp.responseXML. But I do get a result when I use xmlhttp.responseText, it displays the corresponding XML. Code: xmlhttp.open("GET", filename, false);
I have a simple page that uses ajax, php, mysql to get database entries and displays them in a table by a limited number of results.
ie. it only shows 10 entries at a time.
Anyways, as soon as I had ANY DOCTYPE to the document, the table no longer shows up in Firefox. It will how ever show up in IE8 or if I remove the DOCTYPE.
Page WITH DOCTYPE Page WITHOUT DOCTYPE
What on earth would be causing this? I have validated the page with W3C with VALID markup.