Register  |  Login

Question Details    

   Question

Time: 09:38 - Sep 01, 2006     Asked by: taisto.onnela      Status: Answered      Points: 25   

how do I code Ajax so that IE does not stop/ask abot it as an ActiveX component?

Now I am gettingn a yellow line in IE warning about activeX component, abviosly from the:

function createXMLHttpRequest() {
if (typeof XMLHttpRequest != 'undefined') {
return new XMLHttpRequest();
}
try {
return new ActiveXObject("Msxml2.XMLHTTP");
} catch (e) {
try {
return new ActiveXObject("Microsoft.XMLHTTP");
} catch (e) { }
}
return false;
}

Ask a New Question

Become a Quomon Expert

Current Categories

 

Other Questions Needing Answers


   

Answer Discussion
Answer Discussion
Answer Summaries
Answer Summary
 
Hi,

Coding AJAX in internet explorer without using the activex objects is not easy to achieve.
Here are two links that might help you out:
http://verens.com/archives/2005/08/12/aj...
http://dean.edwards.name/weblog/2006/04/...

Anpanman

Expert:

Anpanman

Date:

Sep 01, 2006

Time:

13:25

 

Votes: Good (0) | Bad (0)
Login to rate this answer

In addition to the links provided by Anpanman, take a look at a couple of the available Ajax libraries:

Prototype - http://prototype.conio.net/
or Dojo - http://dojotoolkit.org/

Both of these libraries serve as a cross-browser foundation for creating Ajax requests and allow for extending the capabilities for effects, element watching and events.

Besides, once IE7 hits the street, it will use the XmlHttpRequest object natively, instead of having to instantiate an ActiveX control. If you start using Prototype or Dojo now, you won't have to revisit your code in a few weeks/months.

Hope this helps,
Ric

Expert:

rcastagna

Date:

Sep 02, 2006

Time:

16:41

 

Votes: Good (0) | Bad (0)
Login to rate this answer

One other thing to look at is the "Security Settings" of IE...it can be set to allow ActiveX Objects to run without raising that alert. If you look at Internet Options --> Security tab, you'll see where you can adjust your security level for the various zones. If you click the "Custom Level..." button, you'll be able to adjust the prompts for ActiveX controls and plug-ins.

I've got "Automatic prompting for ActiveX controls" set to "Disable" and "Run ActiveX controls and plug-ins" set to "Enable". If I change either of these, I get the alert you've described, so I'm assuming these are the two that affect running the ActiveX Ajax objects.

I hope this helps,
Ric

Expert:

rcastagna

Date:

Oct 10, 2006

Time:

16:51

 

Votes: Good (0) | Bad (0)
Login to rate this answer

Forget coding and try XAjax for browser independent, automated "event to PHP" calls.

http://www.xajaxproject.org/

Expert:

xarcus

Date:

Nov 17, 2006

Time:

03:30

 

Votes: Good (0) | Bad (0)
Login to rate this answer

Are you running the site locally? If so, then you need to acces it via a webserver instead

Expert:

serge.fonville

Date:

Dec 16, 2006

Time:

09:07

 

Votes: Good (0) | Bad (0)
Login to rate this answer

taisto.onnela, please close this question and distribute the points.
If you didn't get a solution to your problem or you found it yourself, please leave a comment here to let the experts know.
Thanks,
Quomon Admin

Expert:

admin

Date:

Jun 25, 2007

Time:

05:38

 

Votes: Good (0) | Bad (0)
Login to rate this answer

The question has been closed.

Quomon Admin

Expert:

admin

Date:

Jul 02, 2007

Time:

09:30

 

Votes: Good (0) | Bad (0)
Login to rate this answer

Question Answered

This question has been answered, and points have been rewarded to the following experts:

Anpanman: 10
rcastagna: 10
xarcus: 5

You're welcome however to comment or give additional information or if you wish, you have the ability to write an Answer Summary for this question by clicking on the "Answer Summaries" Tab.

 
No summaries have been submitted yet. Want to be the first?



Respond to this question:

New User

  Email:

Upon submission of this form, you will automatically be registered as a Quomon user and we will send your login information to this address

Registered User

Username:

Password:


Forgotten Password

 

New User

  Email:

Upon submission of this form, you will automatically be registered as a Quomon user and we will send your login information to this address

Registered User

Username:

Password:


Forgotten Password

   

"Psst, Quomon is a great site. Pass it on."     Tell a Friend  |   Link To Us  |   Save to Delicious  |   Digg! Digg it


All Questions


Language Options

English:

www.quomon.com

Español:

www.quomon.es

Quomon Blog

blog.quomon.com

Sponsors

Questions and Answers Software
Real Estate Postcards
Marketing Fulfillment