Ticket #759 (reopened defect)
Solution for stripBaseURL remplacement
| Reported by: | bchenu@… | Owned by: | gogo |
|---|---|---|---|
| Priority: | high | Milestone: | 0.97 |
| Component: | Xinha Core | Version: | |
| Severity: | blocker | Keywords: | stripBaseURL getAttribute href relative absolute |
| Cc: |
Description
I have a solution to submit about the problem on URL relative/absolute on Internet Explorer with the getAttribute method. The stripBaseURL method never works properly and parsing the url is not a good solution.
The getAttribute method has a second parameter on Internet Explorer (see link below). If we pass '2', the method return the exact value. And of course it works :)
The patch consists to replace :
editor.stripBaseURL(link.href)
by
link.getAttribute("href", 2)
I apply this patch on HTMLArea 2 years ago and it allways works (I try on Xinha and this works too). Generally, this solution must be used when the getAttribute is call on Internet Explorer.
Note that this patch will have to be applied on plugins too.
links : http://msdn.microsoft.com/workshop/author/dhtml/reference/methods/getattribute.asp
