Jump to content

Javascript using ADODB.Connection


dseabroo

Recommended Posts

Many years ago I wrote a javascript application that ran in internet explorer and I still have it on display in my portfolio of work at http://electricgenesis.com/portfolio.shtml . To try to run it, open internet explorer and follow the instructions on the right hand column under Fanta Play Picture Manager and then click on the link. This used to run under previous version of internet explorer but when I tried it recently (after ignoring it for several years) it did not run. It was brought to my attention after I was testing everything after migrating to a different web server.

When I try to run it the Conn.Open command fails to open the database connection. The database is open to the public and can be accessed via mysql command line tool with same username and password. Does anyone know off hand what has changed with internet explorer and what is or is no longer supported with the ADODB ActiveX control? Does anyone know of an example of a working javascript somewhere that uses this so I can try it in my browser? Any help or suggestions would be warmingly welcome, as would any other feedback on my other work or website on the whole. Thanks everyone for your help!

Link to comment
Share on other sites

Can't help with your specific question.

 

Though I deal with those kind of issues too often especially cross browser.

Link to comment
Share on other sites

Originally intended to use script as a cost saving short-cut for a small project, this quickly grew to be perhaps the largest ECMAScript application ever written.

That's a pretty bold claim. I've got an application with several megabytes of Javascript code running it, can you beat that? I'll go out on a limb and say that GMail, Google Maps, and Facebook probably have some pretty impressive Javascript libraries of their own also.It's hard to say what exactly changed. You're trying to establish a client-side database connection to MySQL, maybe Microsoft set the default security settings so that doing that isn't possible. It's not something that is commonly done, the usual way to do that would be to send ajax requests to the server and have a server-side language interact with the database. Client-side database connections are so rare that I doubt Microsoft is working hard to support that stuff. Maybe the database drivers are no longer available, for example (since you're relying on those drivers to be installed on the client and not the server). You might be able to use the ActiveX object or exceptions to figure out more details about the error though.
Link to comment
Share on other sites

This just isn't what Javascript is intended for. I believe ActiveX controls are mostly obsolete, and they never were available in other browsers. ActiveX's most important purpose used to be to add functionality to Internet Explorer that was already native to other browsers.

 

A website that only works in one browser is practically useless because regardless of which browser your application runs on, you're always ignoring more than half the people that are visiting your website.

 

If you want a purely Javascript-based application that uses a database, Parse.com is an online database service that has Javascript among the languages that can access its content.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...