Wikipedia talk:Tools/Navigation popups/FAQ

Page contents not supported in other languages.
From Wikipedia, the free encyclopedia

Revert[edit]

The revert option is missing from the edit menu popup; is there a known solution to this issue? Cheers, Folajimi (leave a note) 03:51, 17 July 2006 (UTC)[reply]

You only get the chance to revert when hovering over diff links or links to old revisions. Lupin|talk|popups 04:20, 18 July 2006 (UTC)[reply]
Many thanks for the timely reply; it is greatly appreciated.
It occured to me that I may have been doing something wrong after I managed to implement this revert following this post. Yet, I somehow managed to miss exactly what I was doing wrong.
Thanks again. Cheers, Folajimi (leave a note) 10:16, 18 July 2006 (UTC)[reply]

Other Wikis?[edit]

I have a question and an error. It says that it is going to want query.php in the "/" on the server - is that the root www.whatever.com/query.php? www.whatever.com/wikiroot/query.php? or www.whatever.com/wikiroot/extensions/query.php?

What features exactly does that enable in the popups? I couldn't find explaination on that. I thought I had the thing working, but now when I popup over certain things (including cur/last edits in history) I get a js error line 6476, char 2, 'meta.user' is null or not an object. Did I do something wrong? I am sure it was working to show those histories before. TheHYPO 10:52, 4 August 2006 (UTC)[reply]

Edit: I figured out when it was working - when I used the query = false tag in my user js file. I've tried removing that false tag and putting query in each of the three locations I mentioned above, but I get the above error. What functionality is the query providing? And can you suggest a problem I might be stupidly doing? Thanks TheHYPO 10:56, 4 August 2006 (UTC)[reply]

The instructions are inaccurate. It should say that query.php should be accessible at the same place as index.php. I've updated the instructions. Lupin|talk|popups 12:29, 4 August 2006 (UTC)[reply]
query.php lets the script generate history and contribs previews, extended previews for image pages, category member lists in category previews, extended ("queried") revert summaries, and speeds up some other operations. Also, the code that doesn't use query.php for some things is possibly quite buggy, as it doesn't get much testing any more. Lupin|talk|popups 12:34, 4 August 2006 (UTC)[reply]
I'm not sure what you mean by 'at the same place as index by a symbolic link' - I'm not overly experienced with this unfortunately. If you could be any more specific it would really help. Also, do I need the json.php file there as well, or is that an alternate version of query file that I don't need? Thanks for the help TheHYPO 14:41, 4 August 2006 (UTC)[reply]
index.php is a file which should reside on your server somewhere, probably in the same directory as LocalSettings.php. (For me there are two in the mediawiki directory; I don't mean the one in the config directory, but the other one). What I did to get the script working on my mediawiki installation was to run cd /path/to/that/directory/; ln -s extensions/BotQuery/query.php . at a command prompt. This assumes you're running mediawiki on a unix-like box (this won't work on Windows). For me, this is all it takes, but I do need to keep the json.php file in the extensions/BotQuery directory (I don't really understand php much, so I'm not sure why this works :-). On Windows, I'd suggest that you try copying query.php from extensions/BotQuery into that directory. Lupin|talk|popups 16:00, 4 August 2006 (UTC)[reply]
It's a Linux box, but I'm not the host - I don't know that I have access to the command prompt to do what you suggest TheHYPO 16:20, 4 August 2006 (UTC)[reply]
You do need some sort of access to the server to install an extension. Lupin|talk|popups 16:25, 4 August 2006 (UTC)[reply]
All the other ones I've so-far installed have simply been includes in the localsettings file. Does placing actual copies of these files (either exclusively, or in both locations) in the index.php directory not work as an access to the file? TheHYPO 16:27, 4 August 2006 (UTC)[reply]
Almost certainly, but I haven't tried that. Lupin|talk|popups 20:34, 4 August 2006 (UTC)[reply]
It occurs to me - is this query functionality at all dependant on php5 or the newest wiki? Because the system I'm running is running on 1.6.8 and php4 (by force right now). With the query-off tag you provide as a bypass, everything works fine, though some things as you mentioned are lacking (Eg: in images, the 'files that link to this image' section is removed). I can't see any reason putting ACTUAL copies of the files in the index directory wouldn't work if a link does, but it doesn't work for me. I get an error (usually on my second mouseover of a any history link - I get the heading and text of an article but none of the data that goes with it before I get the js error TheHYPO 17:11, 4 August 2006 (UTC)[reply]
I don't know. It's probably a good idea to run SVN head (the bleeding edge latest version) if possible, as this has some bugfixes which affect popups, and possibly query.php too. You could ask Yurik about that, since he wrote the extension :-) On the other hand, the errors you're seeing with popups are moderately unlikely to be related to the php version you're using; rather I'd expect that they're related to the absence (in the correct location) of query.php altogether. Lupin|talk|popups 20:34, 4 August 2006 (UTC)[reply]
You can test whether query.php is installed correctly for popups in the following manner. Do what it takes to get popups not to error out all the time, and then type the following in the location bar while logged in and viewing a page on your wiki:
javascript:document.location=pg.wiki.wikibase+'/query.php'
and hit enter. You should see output similar to http://en.wikipedia.org/w/query.php Lupin|talk|popups 20:38, 4 August 2006 (UTC)[reply]
What I get is:
Parse error: syntax error, unexpected '&', expecting T_VARIABLE or '$' in [url]/query.php on line 555
TheHYPO 14:30, 5 August 2006 (UTC)[reply]
Well, that's going to cause problems. My rather uninformed guess is that query.php doesn't support php4 after all, but you should ask Yurik to be certain why this is erroring out. You should probably mention which version of query.php you're using when you do so (where you got it, and if the answer is SVN, when). Lupin|talk|popups 15:09, 5 August 2006 (UTC)[reply]

I installed the popups and they worked well for some time. But now i get an error:unterminated string constant. at line 756 and char 37. If anyone can please help.nids(♂) 12:38, 2 September 2006 (UTC)[reply]

Custom URLs[edit]

I'm using a differnt style of URLs for my mediawiki which basically makes my articles look like /mywiki/<action>/<title>, for instance, /mywiki/view/Main Page, and /mywiki/edit/Main Page (see http://bmearns.net:81/wwk/view/Pretty_urls). This doesn't work with popups, because it gets the link as '/mywiki/view/title' and looks for an article named 'view/title'. Likewise with redlinks, it looks for articles named 'edit/title', instead of recognizing them as red links. I've got a local copy of the script and I've been looking for where to make the fix, but it's a malenky bit overwhelming trying to parse that big long script. Any help on where to look for this? Thanks.
B.Mearns*, KSC 19:22, 2 October 2006 (UTC)[reply]

Never mind, I found it. For those who are interested, you can rework the regex in the setMainRegex() function, on about line 5770 as of my version. I've elaborated back on my pretty urls page, linked above.
B.Mearns*, KSC 20:16, 2 October 2006 (UTC)[reply]

addOnloadHook problem[edit]

I am attempting to install popups on a mediawiki at work, but my browser's javascript console is logging an error, and I'm not seeing any popup love:

  • MediaWiki: 1.5.3
  • PHP: 5.1.1 (apache2handler)
  • MySQL: 5.0.16-nt

Error: addOnloadHook is not defined

Source File: http://10.1.18.225/wiki/mediawiki-1.5.3/index.php?title=User:Dpotter/popups.js&action=raw&ctype=text/javascript&dontcountme=s Line: 68


Any thoughts or suggestions would be helpful. I think that addOnloadHook is defined in wikibits.js, is that correct? dpotter 18:09, 13 October 2006 (UTC)[reply]

Installing for all users on another wiki?[edit]

I personally find Popups indispensable, so I thought it would be cool to install and enable it for all users on my wiki. I added the following to skins\MonoBook.php:

<script type="text/javascript" src="http://en.wikipedia.org/w/index.php?title=User:Lupin/popups.js&action=raw&ctype=text/javascript&dontcountme=s"></script>

...but nothing happens. The code is present and correct when I view source, but there's no errors in the Javascript console in Firefox and no yellow warning icon in IE. I'm probably being dumb...

Anyone have any ideas? I've taken the liberty of putting a new section to cover this into the attached page :) --kingboyk 14:07, 10 January 2007 (UTC)[reply]

Although there is probably some structural reason that makes this a poor decision, I installed Navigation popups for all users on my wiki by

  1. getting the script to work in my user account on my wiki
  2. copying that working code into the skins/common/wikibits.js file of my wiki

2obvious 21:15, 28 May 2007 (EST)

The easy way[edit]

All you have to do is go to the MediaWiki:common.js page of your wiki and put the javascript include code there. All users import the common.js file, so it will install for all users.

I'm having a big problem though, I've got the popups working on my Wiki except for the total lack of a preview. I've tried installed the query extension, but when I put in

javascript:document.location=pg.wiki.wikibase+'/query.php'

my mod_rewrite code kicks in and I get a "Query.php" titled Wiki page, but not the actual query.php file. I've also used the line that disables the query functions, and I still get no preview. All the links work fine, the popup just shows up with the link title and that's it. Right now my common.js file includes the lines

popupUseQueryInterface=false;

simplePopups=false; popupStructure='lite'; popupPreviews=true;

popupOnlyArticleLinks=true;

and now my pretty popups are just the title, and no more. Can you think of a reason I'd be getting absolutely no preview? Isochronous (talk) 00:42, 31 March 2008 (UTC)[reply]

I figured it out. The culprit was a wrong entry for siteArticlePath and siteBotInterfacePath. If you have your Wiki set up as the short-url page recommends, where the Wiki is installed to documentRoot/w/ , but the article base is documentRoot/wiki/, then your javascript should be:

function siteArticlePath(){ return 'wiki'; }
function siteBotInterfacePath(){ return 'w'; }

Isochronous (talk) 01:46, 31 March 2008 (UTC)[reply]

I've almost got it![edit]

So I installed this Navpop on my Wiki (which is great)! I just can't get the pictures to render. I just get the message

imagepage preview failed :( is the query.php extension installed?

I've installed the query.php extension exactly as described. I've tried to drop it in it's own folder in the extensions folder, and create a symbolic link to it. I've also just copied the files directly into the root of the wiki. Still no luck. Does anyone know what could be causing this? previous by User:HotMonkeyAC on February 5, 2007

  • While I see the images fine, when I cursor over them I see this same message. I didn't use to; something changed a few weeks ago ... Does anyone know how to make this message go away? Keesiewonder talk 10:40, 8 April 2007 (UTC)[reply]
  • Same here - I'm using Firefox, if that helps. --Stephen Burnett 08:20, 7 September 2007 (UTC)[reply]
  • I have the same problem, right here on Wikipedia. Image preview used to work. --Apoc2400 20:41, 17 October 2007 (UTC)[reply]
  • I'm experiencing the same problem. I also happen to be a Firefox user? миражinred (talk) 01:59, 23 December 2007 (UTC)[reply]
see also here, ----Erkan Yilmaz (talk ?, wiki blog) 09:05, 23 December 2007 (UTC)[reply]

Problem with revert edit summaries[edit]

At least two of my uses of the revert function in popups today have given "broken" edit summaries. Here is the latest edit diff, the edit summary is "(Revert to the revision prior to revision $1 dated $2 by $3 using popups)". Ruhrfisch 21:29, 20 February 2007 (UTC)[reply]

Ditto, but more than two. WLU 21:41, 27 February 2007 (UTC)[reply]

Image links[edit]

Everytime I look at an image at the bottom of the page it says "imagepage preview failed :( is the query.php extension installed?" I can see the picture alright though, I've hard refreshed the page and It's still doing it, I'm using IE6 on XP SP2, thanks for the popups.:)--User:Rock2e Talk - Contribs 09:09, 24 March 2007 (UTC)[reply]

This appears to be a known issue. Please see here. -- Seed 2.0 19:53, 1 April 2007 (UTC)[reply]

Color problems[edit]

I can't change my popups' color, even if I try to follow directions (Which I cannot make out very well). Can someone give me a step-by-step set of instructions? WikiPediaAid 20:36, 21 June 2007 (UTC)

Portability - Using on other wikis[edit]

I can't live without this script and was wondering if the instructions to set this up on my wiki could be clarified?

  • Install the script by adding these lines to your user javascript file on that wiki
I'm assuming User:Myusername/popups.js or is it User:Myusername/common.js or User:Myusername/monobook.js
Typically, one of the latter two options. Your "user javascript file" is ${SKIN}.js, where ${SKIN} is the name of your skin, such as monobook or common. Lupin|talk|popups 07:58, 23 November 2007 (UTC)[reply]
  • add the option popupUseQueryInterface=false;.
To where, LocalSettings.php or the javascript file?
Your user javascript file. Lupin|talk|popups 07:58, 23 November 2007 (UTC)[reply]

Problems with Windows Vista?[edit]

I have a fairly new computer - A Gateway GT5428 with Windows Vista. I have had reoccurring problems with my default browser (Internet Explorer) locking up especially when attempting to edit a page. When I first got this new machine, no issues for a while, but I started to notice the popup window "sticking" for a while. I could click out of my browser onto the desktop and click back in and get its attention, and it would let go of the link.

Not too far back I noticed my browser just locking up totally, the type of lockup that requires hitting "Ctrl" + "Alt" + "Del" and closing explorer down. I can look at pages and even hit the "edit this page" tab as an anon with no problems there, so I knew it was my acct with the popups not working well. I did notice at this stage that the popup window would start appearing transparent with only the text of the actions showing. I learned that you can clear the cache by hitting "Ctrl" + F5 several times and the first time I used this, I was able to go in and blank out the text in my monobook.js file. I re-added the text a short time later and was back up with popups doing what it was supposed to.

A few days ago I started having the same issue where I would click the page edit tab, and my browser would lock up. I tried opening another browser and logged in, with no probs. I could explore and look at pages, check diffs, etc with no probs (other explorer window still locked up). The instant I clicked "edit this page" - lockup of browser #2. Here's the bad part - in this state you cannot remove popups from your monobook.js file as you cannot edit anymore. Monobook files have special protection so you cannot edit it without being logged in. Thankfully admins can edit them and I had to email an admin for help (remember - you can't even edit talk pages to ask for help).

For the time being I will not reinstall popups until perhaps someone can show me a way to adjust something in my browser to work with the software. I figured others could possibly have this experience (my other computer with Windows 98SE never had this issue - granted it was old). It could be something with Vista. I thought I would share this experience. Thanks. JungleCat Shiny!/Oohhh! 23:24, 16 August 2007 (UTC)[reply]

I suggest adjusting your browser from Internet Explorer to Firefox. Let me know if you still have problems! (IE should be supported by popups, but not as well as firefox so this is probably the simplest solution). Lupin|talk|popups 07:50, 17 August 2007 (UTC)[reply]
I will definitely look into Firefox. Many thanks. JungleCat Shiny!/Oohhh! 02:50, 18 August 2007 (UTC)[reply]

"current" diff link[edit]

Is there a way that I can get a diff to the current version of a file in popups' history preview (like you do in the normal "history" view)? --Slashme (talk) 14:30, 20 December 2007 (UTC)[reply]

Suddenly no previews when hovering over Wiki-links[edit]

I recently upgraded my Internet Explorer browser from version 7 to 8. At this exact point, previews ceased to appear when I hovered my cursor over Wikilinks in articles. Due to this timing and the fact that this is a brand new data processor (on which this function was working until the browser upgrade, so that fact in and of itself is not relevant, either), I can give no consideration to clearing my cache as a solution (via instructions expressly pertaining to IE 6, yet). The function remains checked. I am at a complete lost. --Ted Watson (talk) 20:44, 9 February 2009 (UTC)[reply]

UPDATE: I backed down to IE 7 and all is working right now. I remembered that the newest version had caused problems a few months ago and some online service person told me to back-grade then. Again, fixed. --Ted Watson (talk) 22:25, 9 February 2009 (UTC)[reply]

Would it be possible to make Popups work in IE8 as well? Or is this due to some Microsoft setting? Microsoft are now actively promoting this new browser version, so most IE users will soon be unable to use the beloved Popups... ;) Erik1980 (talk) 14:34, 22 April 2009 (UTC)[reply]
Microsoft is now pushing out IE8 through Windows Update, so this problem is probably becoming pervasive. IE8's highly-touted "Accelerator" function seems to be suppressing this wonderful app. But turning off the Accelerator function while keeping IE8 hasn't brought back the navigation popups. Can the creator of this app tweak it to get out from underneath IE8? 13:57, 2 May 2009 (UTC)

ImageMap extension[edit]

Would it be possible to make an exception [standard] for the alternate text displayed by the ImageMap extension?   — C M B J   17:25, 13 March 2009 (UTC)[reply]

Possible to install on non-short-url wikis?[edit]

On MW 1.15.1, would love to install navpops on my wiki. Some questions below, Thanks! --SomaticJourney (talk) 05:45, 19 February 2010 (UTC)[reply]

  1. Must I have short-urls enabled?
  2. Do I need to install API?
  3. Do I need to install query.php?
  4. Must I import the popups.js script from wikipedia or can I host it on my server?
  5. Is there a list of wikis that use navpops?
  1. No, as long as you have a recent version of popups, there should be no need
  2. Yes
  3. No
  4. Should be possible to just import from Wikipedia
  5. Not that i'm aware. Translatewiki seems to have it though. —TheDJ (talkcontribs) 18:45, 21 February 2010 (UTC)[reply]
Awesome, that is great news! Perhaps we can modify the Navpop FAQ#Portability to reflect that fact (Short URL not necessary) for the Gadget to work. I'll install it and see how far I get. Thanks for your help. --SomaticJourney (talk) 21:59, 21 February 2010 (UTC)[reply]
I had not yet changed it, because it is a rather new development, and somewhat untested. If you can let me know of any results, please do. —TheDJ (talkcontribs) 22:31, 21 February 2010 (UTC)[reply]
Makes sense. I'd be happy to give feedback. Thanks for your work and attention. --SomaticJourney (talk) 00:47, 22 February 2010 (UTC)[reply]

Chrome[edit]

While I never have a problem in Firefox, these work only like half the time in Chrome. Anyone know why? AaronY (talk) 17:27, 2 December 2010 (UTC)[reply]

Desktop Mode on Mobile[edit]

I would like to use the popups while on a computer, but not while browsing in desktop mode on my smartphone or tablet. Is there a possibility for the tool to detect which media you are accessing wikipedia with and enable / disable to match? The main issue seems to me to be matching between "mouseover" while on a computer and whatever corresponding "touch-over" that is used on devices without input mechanisms such as a mouse or keyboard. Mr Ernie (talk) 15:21, 15 February 2018 (UTC)[reply]

You could load it from your common.js instead of from the gadget settings, and encapsule it in whatever detection of mobile devices you like. --nenntmichruhigip (Diskussion) 10:41, 18 February 2018 (UTC)[reply]


How about a way for users to turn off pop-ups? The settings option doesn't stick and I have to turn them off every time I use Wikipedia. It's bloody annoying.86.143.237.6 (talk)FedUpOfPopUps

Retain overlayed popups?[edit]

The graphical metaphor of stacked popups leads naturally to the expectation that as long as one is hovering over one popup, all popups under it will remain on screen. So I was surprised to see the first popup disappear when I went down a third level. Then I realized the retention criterion was that a popup remains on screen only so long as the cursor is over it. Is it too much to hope there is a configuration parameter to retain all popups overlayed by other popups? Jim Bowery (talk) 05:18, 19 October 2018 (UTC)[reply]