Monday, August 14, 2006

how to use opera 9.01 for all browsing needs

opera 9.01 is the fastest browser on earth, out of all web browsers capable of rendering most web pages correctly. faster than any version of internet explorer, firefox, mozilla, netscape, safari, camino, konqueror, icab, epiphany, k-meleon, or anything else. opera might not be as extensible as firefox is with its extensions, but who really needs extensions anyway? opera has a lot of features built-in! so, although i am a devout firefox user, and have been using firefox more than 90% of the time for web browsing activities for over 2 years (since about april 2004), i would really like to get to know opera better, use it more, try it out. you see, no other browser for windows is anywhere near as standards-compliant, and opera is just amazingly faaaaast. but the main problem in opera is, some web pages are designed to work only in internet explorer, or only in internet explorer and mozilla-based browsers. there is a browser plugin called meadco neptune that lets you view stuff using internet explorer to render, in another browser such as opera, thus solving this problem. but that meadco neptune plugin by itself is not enough. i have developed something known as a “user javascript” to automatically view certain websites using internet explorer to render, if you are using the opera browser and have the meadco neptune plugin installed. here is the user javascript i have developed:

// ==UserScript==
// @name Embed Internet Explorer in Opera v0.01
// @author Numinous Ubiquity

// @description Uses Microsoft Internet Explorer instead of Opera to render
// certain pages, using the MeadCo Neptune plugin for embedding IE.

// Put this file in your Opera User JavaScript directory, which you can set
// in Tools -> Preferences -> Advanced -> Content -> JavaScript Options ->
// User JavaScript Files -> Choose.

// You can edit the list of sites this happens on where it says "@include".

// Requires the MeadCo Neptune plugin to be installed in Opera.
// To install that plugin, visit http://www.meadroid.com/neptune/download/,
// download and install the plugin, and then copy npmeadax.dll from your
// Internet Explorer plugins directory to your Opera plugins directory.

// Known issues: you need to click first, while the screen is all white,
// and sometimes even that does not work. If you look at videos on video.msn.com
// or video.ap.org, you find out that this script actually loads 2 copies of
// the page, one that you see and one that is hidden. I do not know why,
// or how to fix my script. Maybe somebody else can figure out how to fix it.
// I have experimented with things and the current script is the best I can do.
// So, the version number right now is 0.01, to emphasize its pre-alpha status.

// @ujs:category general: enhancements

// @include http://*.blogger.com/*
// @include http://*.live.com/*
// @include http://*.microsoft.com/*
// @include http://*.windowsupdate.com/*
// @include http://video.ap.org/*
// @include http://video.msn.com/*

// ==/UserScript==

/*
* This script is granted to the Public Domain
*/

document.write('<embed pluginspage="http://www.meadroid.com/neptune/download/" width="100%" height="100%" type="application/x-meadco-neptune-ax" location="' + document.location.href + '"></embed>');

so that is the script. really only one line of code, if you exclude all of the comments, although the comments that start with "@include" tell what sites the script applies to, so they are really part of the code. so, three lines of code. anyway, you can edit the "@include" lines to have a different list of websites to apply to. and then, this sort of will duplicate the ie tab extension for firefox, except it is not quite as good, because my skills with this javascript stuff are not quite as perfect as i would like, so the script is a little buggy still. the comments in the script explain the bugs i know about. please, try this thing out, and if you know javascript, figure out what i did wrong and fix it, and maybe leave me a comment on how i can change this thing to work better. oh, and when you save it as a file in the user javascript directory for opera, you can give it any filename, as long as the extension is “.js”.

No comments: