/    Sign up×
Community /Pin to ProfileBookmark

xml and html

I have a menu using xml it containes links to other pages, I need it to link to this one page which displays a share price. I have the link working on another page that uses html but i can not get it working in the xml page I think it could be because I need to use the a javascript function popUpWindow() to display the shareprice.

This is my html code to display the page:

<SCRIPT LANGUAGE=”JavaScript”>

<!–HIDE

function popUpWindow() {

var CtrlWin= window.open(‘http://echonet/?cmd=page&object=ActionZoom.html&lng=EN’, ‘CtrlWin’,

‘width=600,height=300’);

CtrlWin.focus();
}

//STOP HIDING–>

</SCRIPT>

<TABLE><tr height=”20″ BGcolor=#EDF0F3>
<td width=”125″ align=”center”><a href=”#” onClick=”popUpWindow()”> <font face=verdana color=steelblue size=2>Share Price</a></td></TABLE>

Is there any way i can get this link working in the XML file??
I have attached the XML file below.
Thanks for your time,
James.

[upl-file uuid=987b3334-1c6a-493d-ab65-e61ad0baddef size=2kB]xmlcode.txt[/upl-file]

to post a comment
JavaScript

4 Comments(s)

Copy linkTweet thisAlerts:
@khalidali63Mar 12.2003 — That does not make any sense,you should have some javascript code here that reads the XML file and creates the page.....

Cheers

Khalid
Copy linkTweet thisAlerts:
@jjudgeauthorMar 12.2003 — Yea i do have another file but i just sent you the file where the links are held!!sorry

anyway i have enclosed the other file

[upl-file uuid=eb60a9c9-071d-400b-b735-136e65360007 size=14kB]xmlcode1.txt[/upl-file]
Copy linkTweet thisAlerts:
@jjudgeauthorMar 13.2003 — HELP please
Copy linkTweet thisAlerts:
@rmurphyMar 15.2003 — Try changing the "&" to valid XML "&amp;amp;"

You may want to use an XSLT to transform your XML into HTML, I use the following javascript on the client, I'm not sure the commands in ASP.

// Load XML.

var source = new ActiveXObject("Msxml2.DOMDocument");

source.async = false;

source.resolveExternals = false;

source.load("MyXML.xml");

// Load style sheet.

var stylesheet = new ActiveXObject("Msxml2.DOMDocument");

stylesheet.async = false;

stylesheet.resolveExternals = false;

stylesheet.load("MyXSLT.xsl");

// Transform XML to HTML

var html = source.transformNode(stylesheet);


Another point...

Your XML is not very XML Schema friendly, you should pick the same name for your element tags and move the name into an attribute.
×

Success!

Help @jjudge spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 6.16,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @nearjob,
tipped: article
amount: 1000 SATS,

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,
)...