473,666 Members | 2,060 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

setAttribute("h ref) - linkObj.href= returning text node in IE

This is strange ...

I know about IE returning absolute URL's when using getAttribute but I don't
understand why it is appending the text inside of the <atag when using
setAttribute() or linkObj.href= ..as in this example...

http://mysite.verizon.net/microweb2/updateHref.htm

There are 2 functions in this page. The first one is where it displays this
anomoly. It appends the actual text onto the href "if" the text is written
out as an absolte URL. If the text is not written out as an absolute URL it
behaves correctly. Why would IE grab the text node and append it just
because the text is written as an absolute URL?
The 2nd function actually resets the text to overcome this anomoly but I
would like to know why IE is doing this.

David J.
Dec 6 '06 #1
1 2186
There are 2 functions in this page. The first one is where it displays
this anomoly. It appends the actual text onto the href "if" the text is
written out as an absolte URL.
To be more clear, it is appending onto the actual text node the additional
snippet that also gets appended to the href. It should only append the href
and not the text node.

David J.
Dec 6 '06 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
7488
by: MiW | last post by:
Hi I'm making a kind of JavaScript-based library for creating SVG objects/elements. And I hit the wall... Every element (rect, circle etc.) can be created using *.createElement, then *.setAttribute and *.appendChild. Except "image" element. When 'image' element is created like this, it doesn't display anything. When I create that element with the same attributes in SVG code itself, it works perfectly. It works even if I create it with
1
3293
by: CES | last post by:
All, Could someone please look at this and tell me what's wrong... the function works properly in FireFox but in IE onmouseover it replaces the innerHTML. So the original html: at info@test.com Thank you for your consideration. becomes at mailto:info@test.com:?SUBJECT=Request for additional information - Package id : /*JS var*/ Thank you for your consideration.
1
15449
by: George W. | last post by:
Okay, I'm a C#/XML newbie, and I've been wrestling with this for a while now, checked dotnet sites, articles, MSDN Library, etc. and haven't been able to determine why this is happening. I have an xml file that I am loading into an XmlDocument and then trying to add a child element to the root element. I keep getting: System.ArgumentException: The reference node is not a child of this node. This occurs at the line where I'm using...
11
2439
by: jesdynf | last post by:
I'm having trouble applying a stylesheet to content I'm generating after the fact. Here's the sample code: <html> <head> <title>CSS/DOM Problem Example</title> <style type="text/css"> ..historylinks {
3
8395
by: masterofzen | last post by:
I've been playing around with this for a while. I bet the answer is pretty obvious, but I'm just not seeing it. I'm also reasonably certain I've run into this problem before. I'm trying to dynamically insert a few nodes into a webpage using insertBefore. Here's the HTML in question. (Yes, I know the HTML is terrible, but I didn't write it and can't edit it, which is why I have to insert things through the DOM instead. Long story.) <div...
7
3351
by: dennis.sprengers | last post by:
I am trying to write an editor object, which adds some functionality and a toolbar to every textarea with a "form-textarea" class. Both FF and IE generate an error in line 20 (container.appendChild(this.toolbar);) saying "Node cannot be inserted at the specified point in the hierarchy" code: "3" I have two questions: - who would help me with this error - please provide other feedback about my code, since I want to write a solid...
7
2247
by: SM | last post by:
Hello, i need to add a classname to an element <ausing JavaScript. I've tried a couple of thing with no success. This is an small piece of my code: .... <li><a href="<?php echo $cd_img; ?>" onClick="show_picture(this); return false;">image 1</a></li> <li><a href="<?php echo $cd_img; ?>" onClick="show_picture(this); return false;">image 2</a></li>
8
4321
mikek12004
by: mikek12004 | last post by:
1) Script Title: Rich HTML Balloon Tooltip 2) Script URL :http://www.dynamicdrive.com/dynamicindex5/balloontooltip.htm 3) Problem Description: See this page General Music for links you can see without scrolling down the div the tooltip is shown at the desired place but when you scroll donw the div the tooltip's position gets all messed up, e.g in the last "ΤΙΤΛΟΣ ALBUM" (which means Title of album ) the tooltip gets in front of the...
0
8448
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
1
8552
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
7387
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6198
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5666
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4198
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
2773
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
2011
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
2
1776
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.