Browser JavaScript Explained

Browser JavaScript is a feature that allows Opera to automatically fix incompatible Web pages, out of date scripts, and pages that inadvertently block Opera. The script file is automatically distributed by Opera Software ASA, and can be used to apply fixes to specific Web sites, and specific scripts.

Browser JavaScript respects your JavaScript preferences, and will not be loaded if JavaScript is disabled.

Note: Opera also provides User JavaScript, which allows you to apply your own enhancements and fixes to Web pages. Additionally, Opera Software ASA runs the Open the Web initiative, which contacts the authors of problematic Web sites.

Keeping up-to-date

  • Opera automatically checks for updates to Browser JavaScript once every week. Any updates will be automatically downloaded and applied the next time a page is loaded in Opera.
  • You can manually check for updates using Help > Check for updates.
  • Automatic checking is controlled by the Browser JavaScript and Check For New Opera settings in Opera6.ini.
  • Files are downloaded separately for each user of Opera, and you do not have to be an administrator of your computer to make use of this feature.
  • The Browser JavaScript is signed and distributed by Opera Software ASA, and should not be edited.
  • The file will be stored in Opera's profile folder. The Help > About screen will tell you where the profile folder is.
  • Current browser.js status: disabled

If you use a proxy server that requires user name and password to access the internet, please note that Opera will not request user name and password for an authenticating proxy in order to download ua.ini and browser.js. Site patching or upgrade notification will not take place if such proxies are required.

Patches applied by Browser JavaScript

In most cases, when Browser JavaScript applies a fix, a message is posted in the JavaScript console (Tools > Advanced > JavaScript console) saying that the page has been changed.

Some of the fixes apply to specific Opera versions, or on specific platforms only.

Site fixes

saab
  • sniffing on saab.com and saab.de excludes Opera
www.opera.com
  • Browser.js status and version reported on browser.js documentation page
music.download.com
  • Fixing audio samples, old overlibwms library only detects Opera7
fileplanet.com
  • Fileplanet.com sniffing blocks Opera
jobkorea.co.kr
  • Multiple fixes
joins.com
  • Multiple fixes
moneta.co.kr
  • moneta.co.kr relies on IE quirks for CSS positioning
epa.qld.gov.au
  • epa.qld.gov.au site uses capturing load events.
ford.com
  • ford.com flash content does not start playing
rec.feeds.yahoo
  • Make "add feeds" dialog work in Y!Mail beta
dell
  • Multiple fixes
ebay
  • Multiple fixes
google
  • Google calendar date selection fails due to order of blur and mousedown events
hp.com
  • HP shopping site is designed for smaller fonts
mail.yahoo
  • Multiple fixes
scandinavian.net
  • Selects are reset if first option is removed in onchange
sony
  • UDM on sony.com breaks if insertRule throws exceptions
t-online.de
  • Multiple fixes
ulead
  • Ulead.com old Milonic menu
yahoo
  • Multiple fixes
able.co.jp
  • able.co.jp uses capturing event listeners
adobe.com
  • adobe.com browser sniffing causes endless scrolling
airfrance
  • AirFrance use getYear when they should use getFullYear
alice.it
  • alice.it design breaks because it depends on smaller fonts
aol.co.uk
  • AOL login hidden by IFRAME
aol.com
  • Multiple fixes
apple.com
  • apple.com click tracking overwrites page
barnesandnoble.com
  • Barnes&Noble uses "required" attributes on elements that aren't required
bioware.com
  • bioware.com uses outdated HierMenus
blogger.com
  • Multiple fixes
bloglines.com
  • Bloglines, designMode case sensitivity issue
bnz.co.nz
  • bnz.co.nz use getYear when they should use getFullYear
britishairways
  • Multiple fixes
budget.com
  • Budget.com: menu appears behind IFRAME "shim"
bugs.co.kr
  • Multiple fixes
chosun.com
  • Multiple fixes
dancenter.com
  • Dancenter use getYear when they should use getFullYear
dcf-access.dcf.state.fl.us
  • Access Florida invalid markup problem
dowjones.com
  • dowjones.com: No styling when ID as Opera, menus under Flash
eatsleepsport.com
  • eatsleepsport.com uses SCRIPT for.. event.. syntax, never stops loading
emirates.com
  • Emirates.com: broken OpenCube
fes.ebank.co.jp
  • Multiple fixes
fotocenter.aol.de
  • AOL: browser warnings for various features of aol.de
foxnews.com
  • FoxNews: sniffing prevents Flash video features from functioning
hangame.com
  • hangame.com SPANs should be inline-block
icicidirect.com
  • styling INPUT with text-transform can confuse users
idg.se
  • speed up back/forward navigation, ensure ads do not re-appear
imageshack.us
  • Imageshack cancels mousedown event, prevents focusing input
ipop.co.kr
  • ipop.co.kr SPAN should be inline-block
klm.com
  • KLM uses Gecko-specific originalTarget
mail.google
  • Multiple fixes
makemytrip.com
  • Multiple fixes
maps.ubiest.com
  • Ubiest.com uses CSS filters if document.all exists
maybank2u.com.my
  • maybank2u, onresize event causes a refresh whenever the softkeyboard is opened
msnbc.com
  • MSNBC sniffing hides Flash content
music.mu-mo.net
  • mu-mo.net uses SCRIPT for..event.. syntax
myspace.com
  • Multiple fixes
n-gage.com
  • N-Gage plugin sniffing does not give Flash to Mac Opera
namooya.com
  • Namooya.com main flash does not appear
nbc4.tv
  • NBC4.tv uses capturing load events
nbcolympics.com
  • NBC Olympics site uses capturing load events
nectar.com
  • Nectar uses getYear where they should use getFullYear
nick.com
  • Nick.com flash detection fix
nokia
  • Broken Flash detection on some Nokia sites
nrg.co.il
  • Multiple fixes
orbitz.com
  • Orbitz new Function() issue workaround
pda.naver.com
  • pda.naver.com appears half-offscreen
pogo.com
  • Loading problems on pogo.com because of document.load in frameset event handler scope
prisjakt.nu
  • prisjakt.nu capturing load events on back navigation
reviews.cnet.com
  • CNet videos: document.write adds a script that depends on variables defined later
sabadellatlantico.com
  • SabadellAtlantico use getYear when they should use getFullYear
search.live.com
  • Live.com search disappearing menu fix
skysports.com
  • Missing automatic resize of Flash object
synaptics.com
  • Synaptics.com outdated HVMenu
teletekst.nos.nl
  • Teletext focus fix
time.com
  • time.com script causes reload loop if UA contains "Windows CE"
united.com
  • United.com flight search problem: hidden images do not load, so no onload event
viamichelin.com
  • Fixing map selection on viamichelin.com (event.button)
video.ivillage.com
  • ivillage video does not appear
video.nbc.com
  • NBC.com video problems
wachovia.com
  • Viewing checks calls createElement with markup strings if document.all exists
walla.co.il
  • Multiple fixes
washingtonpost.com
  • Washington Post picks wrong script branch because site thinks Opera is IE
worldofwarcraft.com
  • Mouseover popups do not appear due to document.all sniffing
yellowpages.com.au
  • Yellow pages event capture fix
zdnet.com.com
  • ZDnet video site plays non-existing files if browser is Opera
aumypage.duogate.jp
  • au my page XMLHttp re-use issue
https://www.bookryanair.com/skylights/cgi-bin/skylights.cgi
  • Selects are reset if an option is changed from onchange.

Patched scripts

  • Old versions of the following popular menu scripts, all of which fail in Opera:
    • "Sothink menus" versions 3.72 and earlier; changes browser detection to make the menus use the correct code in Opera.
    • "Milonic menus": changes browser detection to make the menus use the correct code in Opera.
    • "HierMenus": changes browser detection so the menu is not disabled in Opera.
    • "Likno AllWebMenus", builds earlier than 498; changes browser detection to make the menus use the correct code in Opera.
    • "Menu/Pop Menu": (HV Menu); changes browser detection so the menu is not disabled in Opera.
    • "Ultimate Dropdown Menu": changes browser detection so the menu is not disabled in Opera.
    • "OpenCube menus": changes browser detection to make the menus use the correct code in Opera.
    • "Coolmenus": changes browser detection to make the menus use the correct code in Opera.
    • "DynAPI": changes browser detection to make the library use the correct code in Opera.
    • "Transmenus": changes browser detection and code to make the library use the correct code in Opera.

Other patches

  • Router configuration SCRIPT in OPTION tag fix
  • PDF security patch

Note to webmasters

There are several reasons why Opera might modify your pages. These include:

  • Opera may prevent a browser detect on your pages from causing problems.
  • Opera may fix incompatible, invalid, out-of-date, or problematic code used on your pages.

If you think Opera is modifying your page incorrectly or unnecessarily, or if you have removed the cause of the problems, please mail web-compliance@opera.com.

If you wish to disable Browser JavaScript to allow you to test your fixes, you can do this by setting Browser JavaScript to 0 in Opera6.ini.