You need to be logged in to post in the forums. If you do not have an account, please sign up first.
FAQ
Installing User JavaScriptBefore User JavaScript can run in Opera, you must enable the feature by pointing Opera to your User JavaScript directory
- Create a directory for storing User JavaScript files, for instance C:\userjs\
- Go to Tools -> Preferences -> Advanced -> Content -> JavaScript Options. Add the location of your newly created script directory to My JavaScript files.
Installing User JavaScript files
Scripts can be installed in one of the following ways:
- If you want to review the script prior to installation, you can just visit the script, and select “Save As…” when you are viewing the script.
- Mouse: By right-clicking the download link, and select “Save target as … “. Save the script to your previously created User JavaScript folder.
- Keyboard: By focusing the download link, and pressing “Ctrl-Shift-S”. Save the script to your previously created User JavaScript folder.
Uninstalling User JavaScript files
Permanent uninstallation of User JavaScript files is done by deleting the script file from the folder containing your User JavaScript files.
If you want to disable a script file without permanently removing it, this is easiest achieved by changing the file suffix of the script file. Example: renaming myScript.js to myScript.js.xx will disable the script.
Also you can use UserJS Manager for installing and disabling UserJS.
Certain UserJS
a-lib-stacktrace.js and a-lib-xmlhttp-cd.js - Cross-domain XMLHttpRequest for Opera.
aagmfunctions.js - Emulates some functions of Greasemonkey. Used for providing of the best compatibility with scripts from FireFox.
allinbackground.js - Opens links in a background on Ctrl+Click.
alt2title.js - If the tag «Title» is not set, copies content of tag «Alt» in him. It's needed for the "correct show" of tag «Alt» as a pop-up prompt at pictures, as it does IE. (let-me-see-img.js usually better)
auto-copy.js - Copies the selected text in the clipboard (flash is needed). A version correctly working with Russian language is here.
autocopy.js - Copies the selected text with formatting in the clipboard. Only for Windows.
autosizer.js - This script activates when you use Opera to view an image file and adds five different viewing modes for images: "Original", "Shrink to Fit", "Maximize", "Fit to Width" and "Fit to Height". New version here. Version for Opera 9.5 here.
bbcode.js - Inserts in the textarea any BBCode and HTML tags.
block-external-scripts.js - Blocks loading of scripts from other domains. It takes away advertising realized on js, for example, Google AdSense or "pop-up windows v2.0", like this.
blockexternal.js - Blocks scripts, pictures, frames and flash from other domains. It advertising in most cases. There is a white list.
block_external.js - More advanced variation on a that theme from Mikivanch. Allows to block pictures by size. Does not block scripts.
BlockIt.js - Bloker of scripts. Approximate analogue of extension NoScript for FireFox.
bug-me-not.js - Using service BugMeNot.com searches logins and passwords for the sites of requiring authentifications. Run on Ctrl+Shift+Double Click.
convert2phf.js - Saves a page in phf or mht. A page is saved with all of changes done by javascript.
coolirisalike.js - At pressing of Ctrl and hovering of mouse on links, the preview window shows. (attempt to realize the analogue of Firefox exptension Cooliris Previews).
devConsole.js - Console of developer. For work as UserJS will replace the first line «(function()» on «function ujs_devConsole()», and last «})()» on«}» and use the button: Dev console.
disable-script.js - Blocks all of scripts on sites, but allows to use UserJS.
dlembed.js - Double click on blank space of page, will add before each flash, link for downloading. There exists button version.
extra-download-links.js - Adds links to the pictures and flash in sidebar "Reference". Here last version.
fix-content-type.js - If HTML pages are incorrectly served as text, this script attempts to correct them, and load them as HTML
fix-gzipped-pages.js - Corrects the twice gzip-compressed pages.
get-link-info.js - Gives out information about link. Namely: size, date, content-type. Sufficiently bugged and consumes a more traffic what separate utilities.
google-translate - Text translation, including full pages, selected text and textarea, with a Google Translate.
google-translation with tooltip - Variant from Ayush, oriented to translation of separate words.
hide-objects.js - Hides a flash on pages. Unblocking via double click. (Flashblocker is better).
highlighter.js - Advanced search with highlighting. Including in Google and with using of regular expressions.
HighlightText.js - At pressure on the button, changes the color of current selection on yellow and it memorizes in cookies. Analogue of extension Line Marker for FireFox.
image_reloader_for_opera.js - Image loading, on Ctrl+Click or long pressing of the left mouse button.
imgthumb.js - When you hover a image link youll see a thumbnail in bottom left corner.
keyboard.userjs.js - Virtual keyboard which is added to the test fields on a page.
let-me-see-img.js - In place of the not visible not loaded images shows a border. In addition, shortens too long inscriptions in place of images and copies content from alt to title.
link-alert.js - This script identifies links to specific file types, and displays an appropriate icon when the link is hovered. Sufficiently bugged. Better to use links-with-icons.css.
linkifier.js - Does «text links» a clickable. There can be problems with speed.
linkify-txt.js - Does clickable, a links in text files.
logger.js - Writes down history of the visited pages in a file. Java is needed.
middleclickJSOverride.js - Provides correct work, in case click a middle-button on javascript-link.
multipopup.js - Beautiful transparent tooltips with additional possibilities. Not forget to disable built-in tooltips. Can cause problems.
no_meta_redirect.js - Disable a meta-redirect.
noclicktoactivate.js - Avoiding click-to-activate for plugins (flash, for instance). Version for Opera 9.5 here.
open-in-background-with-long-press.js - Opens new tab in a background with long click. Useful for laptop users. In Opera 9.5x you must set Ctrl+F12->Advanced->Content->Javascript options->Allow lowering of windows.
open-in-new-window.js - All links will opened on a new page. Works only on sites which written in beginning of script.
open_browser.js - Opens the certain sites in the certain browser. Only for Windows.
ops.js - Provides autocomplete feature for text input fields. Two (improved) variants are here.
ospell.js - On-line spell checking in textarea.
pdfHandler.js - Deletes an empty page at opening files *.pdf, *.doc and *.xls.
Remove_it_permanently-for_Opera.js - Deletes the clicked element of page. Permanently. Only for Windows.
removeblank.user.js - Deletes all attributes «target="_blank"», which cause opening of links on a new page.
robosticky.js - Add sticky-notes to HTML and XHTML pages.
safe-alert.js - Allows to stop appearance of js-alert for a page.
scroller.js - Enables to scroll a page, with pressing Ctrl and left button and moving a mouse.
seobar3.js - Is a powerful tool for web-site promoters and analysts. SEObar can display the following information on the page of your browser: Alexa Traffic Rank, Google Page Rank, Yandex CY and more.
Smilize.user.js - Transform text smiles (for example,
, :-), :d,
, etc) in animated gif. Need aagmfunctions.js.snap-links.js - Open multiple links by drawing a box around links.
snap-images_userjs.js - Similar for images.
text-replacement.js - Replaces the certain text on all of pages.
titleprotector.js - Does not allow web-pages to change a title of browser with JavaScript.
xerath-plugsome-toolbar.js - Shows near each flash, toolbar with buttons: Reload, Save, Play and Pause. Two last work not everywhere.
xerath-power-drag.js - Allows to change the size of textarea and images by a mouse.
xml-tree.user.js - Shows XML files as a tree and with syntax-highlighting.
zoom-image.user.js - This script allows you to zoom individual images using an image toolbar appearing whenever you hold your mouse over an image.
Site-specific UserJS
experts-exchange.com - ExpertsExchangeFilter.user.js. Removes all the garbage, fake entries and other stuff.
google.com - Google Fx (need aagmfunctions.js). Nice Look&Feel + ThumbShots + Global Suggest (multi-lang) + Streaming Auto-Pages + Easy Adv. Features + Images relink, cache pages & easy filters.
livejournal.com - lj_unfolder.user.js. This script adds to Livejournal comment pages ability to download logn threads inline, ajaxy.
my.opera.com - MyOpera Community Enhancements.
rapidshare.com - rapidshare_com.js (scripts for similar services is here).
youtube.com - youtube_com.js, youtube_down.js, videoscript.user.js.
For developers
http://userjs.org/help/tutorials/
Avoid a global variables and functions. Use anonymous function:
(function(){
Yours code
})();
If you uses non english symbols in UserJS, encode it (\uXXXX) or save script in utf-8 without BOM (not works in Opera 9.2).
For getting info from other domain use cross-document-messaging. For compatibility with Opera 8-9 and Opera 9.5 use similar code:
if(window.postMessage){frame.contentWindow.postMessage(post)}else{frame.contentDocument.postMessage(post)}
Certain bugs
«window.getSelection()» - loses line feed. Try «document.getSelection()» or see quick-reply.js

«window.getSelection().containsNode()» - Always false.
«document.selection.type» - «None» even if selection exists. Opera 9.5 only.
«mousedown» - breaks drag-n-drop on page. Use «BeforeEvent.mousedown»
...
Originally posted by larskl:
made sticky
Thanks.
And good job with the FAQ Lex1.

GT500.org Forums -- Blog -- TeamSpeak -- Several Critiques of Opera 10
[Security Wiki]
Main Page -- Keeping Your Computer Clean
[System Specs]
For those who either need to know, or are just curious.
[Computers and Security]
BleepingComputer -- What the Tech -- Geeks to Go! -- BestTechie -- Microsoft Security Essentials -- Sponsored Search Results Lead to Malware -- S!Ri.URZ Research Blog
Still, I'd suggest to add brief explanation next to each Site-specific UserJS above. Plus, add a link to the author's site with an updated explanation in English or any other language (to use with translator). Its scary to install a generic name script without knowing what it does.
brief explanation
OK.
add a link to the author's site
Direct links are given only for simple in the use scripts, and in such scripts usually exists of links to the site.
Virtual Keyboard isnt working with Wand . When i double clicked the password field ( which marked with yellow ) its not opening .
How can i fix this ?
Opera Türkiye | Opera SSS | Opera Türkiye Projeleri | Opera Türkçe Yardım
Becouse some my colleagues said to me some userjs doesn't work with linux.But windows is OK.
Opera Türkiye | Opera SSS | Opera Türkiye Projeleri | Opera Türkçe Yardım
After all that I also installed the userjs manager, it shows my scripts activated, but they do nothing.
Originally posted by Lex1:
For getting info from other domain use cross-document-messaging. For compatibility with Opera 8-9 and Opera 9.5 use similar code:
This doesn't seem to be working in Opera 10 anymore. Example: http://trash.chregu.tv/xdom.html
I have a question: Why isn't UserJS allowed to make cross domain requests? Widgets are allowed to do so...!?
(If nothing else stated the most current weekly) on a nice Dell Studio XPS 16!
1. March 2009, 18:14:17 (edited)
document.addEventListener("message",function
Use window.addEventListener
Why isn't UserJS allowed to make cross domain requests?
Security. Afaik, userjs run in the context of page. GM-scripts is isolated. Widgets at all have no access to page.
Originally posted by totalimpact:
Any reason why scripts wouldnt work - I have the copy clipboard script and google images script, and neither works. I have built a script dir in my profile and set it in preferences, and made sure to check the enable java script box, and set the option in opera6.ini to: Always Load User JavaScript=1 and yes i restarted opera several times.
After all that I also installed the userjs manager, it shows my scripts activated, but they do nothing.
Same here.
But, I found here a post regarding the override.ini file.
I didn't delete anything, as the poster there suggests, but changed the relevant User JavaScript values from 0 to 1.
Seems to help, tho I'm not yet convinced everything is working as it should...
From Opera 10.5 has been removed:
- document.addEventListener("load", ...) (just use window.addEventListener("load", ...) )
- document.selection
- element.text
document.selection also can to work with a textarea, what has no direct analogue. However, it is mainly essential for bookmarklets.
Originally posted by CCVo:
Originally posted by totalimpact:
Any reason why scripts wouldnt work - I have the copy clipboard script and google images script, and neither works. I have built a script dir in my profile and set it in preferences, and made sure to check the enable java script box, and set the option in opera6.ini to: Always Load User JavaScript=1 and yes i restarted opera several times.
After all that I also installed the userjs manager, it shows my scripts activated, but they do nothing.
Same here.
But, I found here a post regarding the override.ini file.
I didn't delete anything, as the poster there suggests, but changed the relevant User JavaScript values from 0 to 1.
Seems to help, tho I'm not yet convinced everything is working as it should...
okay, I have the same problem, but I really can't find the override.ini file, where can I find it?
Originally posted by The-Remcotje:
Originally posted by CCVo:
Originally posted by totalimpact:
Any reason why scripts wouldnt work - I have the copy clipboard script and google images script, and neither works. I have built a script dir in my profile and set it in preferences, and made sure to check the enable java script box, and set the option in opera6.ini to: Always Load User JavaScript=1 and yes i restarted opera several times.
After all that I also installed the userjs manager, it shows my scripts activated, but they do nothing.
Same here.
But, I found here a post regarding the override.ini file.
I didn't delete anything, as the poster there suggests, but changed the relevant User JavaScript values from 0 to 1.
Seems to help, tho I'm not yet convinced everything is working as it should...
okay, I have the same problem, but I really can't find the override.ini file, where can I find it?
Allright, I think I have done something wrong because the downloaded script contained 0 characters, I don't know why. But now it's fixed and it works fine. Also Unite's UJS Manager is a great tool, it makes it so easy to download new scripts!
document.selection.createRange().text
Approximate analogue:
var getText=function(){var d=document,s=d.getSelection(),t=d.getElementsByTagName('textarea');if(!s)for(var i=0,e;e=t[i];i++){if(s=e.value.substring(e.selectionStart,e.selectionEnd))break}return s};
Originally posted by 99th:
i'm looking for piece of script to prevent google search interface from capturing my keyboard input no matter where focus is: everytime i use oldschool "1" and "2" to switch between tabs, google handles those keypresses and substitute "1" and "2" chars into it's search field.
You might take a look at this short UserJS: »» google-search-key-unbreaker-userjs.
