By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
459,654 Members | 1,580 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 459,654 IT Pros & Developers. It's quick & easy.

JavaScrip, xml and Linux

P: n/a
Dear readers,

Can I use the following object on a Linux based web server:

var xmlDoc = new ActiveXObject("Microsoft.XMLDOM");

If not, is there a compatible object?

Tia, Jean.
Jul 23 '05 #1
Share this Question
Share on Google+
5 Replies


P: n/a
Dear readers,

Okay, that was a bit stupid because the object is - ofcourse - created by
the browser...
Now the real trouble is the following code:

var xmlDoc = new ActiveXObject("Microsoft.XMLDOM");
xmlDoc.async = "false";
xmlDoc.load(http://111.222.333.444/btw/Btw2Xml.jsp?parm=NYC);

If I have a local file, I can do the load... ( the url shown is a fake one)

If I put very same file on my webserver, I get a an "access error" in IE on
the 3rd line show, character 7.
This is the 'dot' in "xmlDoc.load". If I use the script debugger it says:
"msxml3.dll : access denied".

Which is very informative, but not a great help.
Does anyone have a clue?

Tia, Jean.

"Jean Pion" <je*******@hotmail.com> schreef in bericht
news:ab***************************@news1.zonnet.nl ...
Dear readers,

Can I use the following object on a Linux based web server:

var xmlDoc = new ActiveXObject("Microsoft.XMLDOM");

If not, is there a compatible object?

Tia, Jean.

Jul 23 '05 #2

P: n/a


Jean Pion wrote:

Now the real trouble is the following code:

var xmlDoc = new ActiveXObject("Microsoft.XMLDOM");
xmlDoc.async = "false";
Should be
xmlDoc.async = false;
xmlDoc.load(http://111.222.333.444/btw/Btw2Xml.jsp?parm=NYC);

If I have a local file, I can do the load... ( the url shown is a fake one)

If I put very same file on my webserver, I get a an "access error" in IE on
the 3rd line show, character 7.


If you have script in a page served from http://example.com/ then using
Microsoft.XMLDOM you can only load URLs from that host
http://example.com/, at least with the normal security settings in IE.
I think you can make http://example.com/ a trusted site and thereby
allow it to connect to other servers.

--

Martin Honnen
http://JavaScript.FAQTs.com/
Jul 23 '05 #3

P: n/a
Thanks Martin,

That sounds very reasonable...
I tried this, but I still have the same troubles.
Even checked all the options for trusted sites, which seem to allow for
cross-domain activities.

Now trough yout link found that:

Set the domain property only if you must allow cross-domain scripting. Use a
value determined on the server. Setting this property to a value determined
on the client (like through the location object) could expose your site to
attack from another site through Domain Name System (DNS) manipulation.

But I'm unsure what it means but I think it is releated.
Any examples?

Tia, Jean.

"Martin Honnen" <ma*******@yahoo.de> schreef in bericht
news:41***********************@newsread4.arcor-online.net...


Jean Pion wrote:

Now the real trouble is the following code:

var xmlDoc = new ActiveXObject("Microsoft.XMLDOM");
xmlDoc.async = "false";


Should be
xmlDoc.async = false;
xmlDoc.load(http://111.222.333.444/btw/Btw2Xml.jsp?parm=NYC);

If I have a local file, I can do the load... ( the url shown is a fake one)
If I put very same file on my webserver, I get a an "access error" in IE on the 3rd line show, character 7.


If you have script in a page served from http://example.com/ then using
Microsoft.XMLDOM you can only load URLs from that host
http://example.com/, at least with the normal security settings in IE.
I think you can make http://example.com/ a trusted site and thereby
allow it to connect to other servers.

--

Martin Honnen
http://JavaScript.FAQTs.com/

Jul 23 '05 #4

P: n/a
Thanks Martin,

Oh dear, oh dear. In my hury I 'trusted' the the wrong site.
So, to follow your example:

If you have script in a page served from http://www.example.com then using
Microsoft.XMLDOM you can load URLs from http://www.elsewhere.com
if you can make http://www.example.com a trusted site.

You were right, thank you.
I was confused and tried to 'trust' http://www.elsewhere.com but that does
not work.

Jean

"Jean Pion" <je*******@hotmail.com> schreef in bericht
news:c4**************************@news1.zonnet.nl. ..
Thanks Martin,

That sounds very reasonable...
I tried this, but I still have the same troubles.
Even checked all the options for trusted sites, which seem to allow for
cross-domain activities.

Now trough yout link found that:

Set the domain property only if you must allow cross-domain scripting. Use a value determined on the server. Setting this property to a value determined on the client (like through the location object) could expose your site to
attack from another site through Domain Name System (DNS) manipulation.

But I'm unsure what it means but I think it is releated.
Any examples?

Tia, Jean.

"Martin Honnen" <ma*******@yahoo.de> schreef in bericht
news:41***********************@newsread4.arcor-online.net...


Jean Pion wrote:

Now the real trouble is the following code:

var xmlDoc = new ActiveXObject("Microsoft.XMLDOM");
xmlDoc.async = "false";
Should be
xmlDoc.async = false;
xmlDoc.load(http://111.222.333.444/btw/Btw2Xml.jsp?parm=NYC);

If I have a local file, I can do the load... ( the url shown is a fake one)
If I put very same file on my webserver, I get a an "access error" in
IE on the 3rd line show, character 7.


If you have script in a page served from http://example.com/ then using
Microsoft.XMLDOM you can only load URLs from that host
http://example.com/, at least with the normal security settings in IE.
I think you can make http://example.com/ a trusted site and thereby
allow it to connect to other servers.

--

Martin Honnen
http://JavaScript.FAQTs.com/


Jul 23 '05 #5

P: n/a
Jean Pion wrote:
Dear readers,

Can I use the following object on a Linux based web server:

var xmlDoc = new ActiveXObject("Microsoft.XMLDOM");

If not, is there a compatible object?

Jean,

I see you already have a few answers, but not about the actual problem.
As a test, can you imagine where a Linux system would get hold of either
ActiveXObjects or Microsoft.XMLDOM?

That's right - neither can I. Both are, after all, _Microsoft_ products
which are in notoriously short supply on Linux systems...
Jul 23 '05 #6

This discussion thread is closed

Replies have been disabled for this discussion.