On Sat, Jun 21, 2008 at 12:09 AM, Mike Wright <email@example.com> wrote:
I'm working on a project but am absolutely stymied and need outside help. *Both konqueror and firefox exhibit the same behavior so I don't think this is a browser bug.
I've checked the xhtml1-strict.dtd and it says that anchor tags support the core attributes which include "id"; however, the following html doesn't produce the expected results.
Sorry for the OT/wrong forum post, but I find the collective knowledge of the fedora users to be one of the best out there... and the most helpful.
Mike Wright :m)
Below is the html being tested.
<?xml version='1.0' encoding='UTF-8'?>
* *PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<p * id='m'></p>
<a * id='a'></a>
<p * id='p'></p>
*var d = document;
*var m = d.getElementById('m');
*var a = d.getElementById('a');
*var p = d.getElementById('p');
*var v = d.getElementById('v');
*var b = '<br />';
*m.innerHTML = a+b+p+b+v+b;
will it's simple ,
what do you want to get from the getElementById(')?
I mean if you're trying to know what kind of element is it, just to process it in some how, then you will not get a result from just using the getElemntByid thing for example:
will return in Firefox: [object HTMLParagraphElement]
in IE Mac: [object P]
why don't you just specify what you want to get back from it let's say you may use:
*var a = d.getElementById('a').innerText;
by the way adding href="" to the anchor tag will let* var a = d.getElementById('a'); return the href it self, if you still need an output that looks like:
tell me and will find a work around for you...
fedora-list mailing list
To unsubscribe: https://www.redhat.com/mailman/listinfo/fedora-list