Community Central
Community Central
Forums: Index Support Requests Import script for navigation popups only works in certain positions
Fandom's forums are a place for the community to help other members.
To contact staff directly or to report bugs, please use Special:Contact.
Archive
Note: This topic has been unedited for 4253 days. It is considered archived - the discussion is over. Information in this thread may be out of date. Do not add to unless it really needs a response.


Here is the link to our sitewide js page:http://religion.wikia.com/wiki/MediaWiki:Wikia.js

It consisted of a few js functions used for some buttons that are on a few pages

then some variables are defined for the statcounter

then the statcounter is imported

then navigation popups is imported.


navigation popups will not work if its import line is placed above the functions

nor will it work if its import line is placed below the statcounter import line

Can anyone shed any light on this behavior.

Granpa (talk) 13:48, August 26, 2012 (UTC)

Best I can figure out is that the popups script isn't designed to work on anything other than Wikimedia projects. It contains broken references to variables which don't exist on Wikia; as soon as it hits that point, everything stops due to the error. Try adding:
mw.config.set('wgNoticeProject', 'Wikia');


before the $.getScript for the popup script. See if that helps. It's hard to tell as everything seems to work right now, if it was still broken I could investigate more deeply. Lunarity 14:49, August 26, 2012 (UTC)
It was working earlier but it has mysteriously stopped working now.
I added the code above but it had no effect.
Granpa (talk) 15:14, August 26, 2012 (UTC)


I reverted to an earlier revision that I know was working earlier but it still doesnt work.
I have no idea whats going on.
Granpa (talk) 15:26, August 26, 2012 (UTC)
Its working in chrome but not in firefox.
Granpa (talk) 15:28, August 26, 2012 (UTC)
control f5 and its working in firefox.
I've been using shift reload but maybe that doesnt work anymore
Granpa (talk) 15:29, August 26, 2012 (UTC)


OK, everything is back exactly where it was when I first started this thread and popups are working Granpa (talk) 15:35, August 26, 2012 (UTC)

and now it has mysteriously stopped again even though I didnt do anything.
Granpa (talk) 15:54, August 26, 2012 (UTC)
and this is quite typical.
this sort of thing happens all the time
it works then I change one unrelated thing and it stops
then I change it back to exactly where it was before and it still wont work.
its totally flaky
Granpa (talk) 15:56, August 26, 2012 (UTC)
I tried loading this version: [1] manually and it came up correctly without any errors for me. The statement I gave you won't have an overt effect, it just prevents the script from crashing; that mw.config statement needs to be before the popup script is loaded, as long as you keep those 2 together in the same order than it should work. Make sure you're refreshing your cache correctly as well, otherwise the changes you make won't take effect until some time afterwards. Lunarity 16:31, August 26, 2012 (UTC)
I added your line. Popups arent working for me but maybe they will for you.
Granpa (talk) 17:26, August 26, 2012 (UTC)


Staff originally told me to add

importScriptURI( 'http://help.wikia.com/index.php?title=MediaWiki:Gadget-popups.js&action=raw&ctype=text/javascript' );
importStylesheetURI( 'http://help.wikia.com/index.php?title=MediaWiki:Gadget-navpop.css&action=raw&ctype=text/javascript' );
Granpa (talk) 17:42, August 26, 2012 (UTC)
Navigation popups are still working over at help wiki http://help.wikia.com/wiki/Special:Random
You have to enable them in preferences under gadgets.
Granpa (talk) 17:46, August 26, 2012 (UTC)
The popups are working fine for me. Maybe there's something else entirely that prevents them from working for you... Please use Chrome and open the developer console while you load one of the page where they should work. Then post any error messages you get here. Alternatively you can use Firefox but then you'd have to install Firebug first.


I opened tools then developer something then errors. I loaded a very small page at http://religion.wikia.com/wiki/Eternal_life and got this:


GET http://tag.admeld.com/ad/json?publisher_id=525&site_id=wikia&placement=test_atf&size=300x250&url=http://religion.wikia.com/wiki/Eternal_life&callback=AdMeldAPIClient.callback&container=TOP_RIGHT_BOXAD&callback=jQuery17206533968118019402_1346004718777 jquery.min.js:4


GET http://religion.wikia.com/__varnish_liftium/config?pubid=999&v=1.2&country=us oasis_shared_js_anon:796


GET http://tag.admeld.com/ad/json?publisher_id=525&site_id=wikia&placement=test_atf&size=728x90&url=http://religion.wikia.com/wiki/Eternal_life&callback=AdMeldAPIClient.callback&container=TOP_LEADERBOARD&callback=jQuery17206533968118019402_1346004718778 jquery.min.js:4

GET http://tag.admeld.com/ad/json?publisher_id=525&site_id=wikia&placement=test_btf_right&size=160x600&url=http://religion.wikia.com/wiki/Eternal_life&callback=AdMeldAPIClient.callback&container=LEFT_SKYSCRAPER_2&callback=jQuery17206533968118019402_1346004718779 jquery.min.js:4 f.ajaxTransport.send jquery.min.js:4 f.extend.ajax jquery.min.js:4 AdMeldAPIClient.init oasis_shared_js_anon:572 (anonymous function) oasis_shared_js_anon:580


GET http://tag.admeld.com/ad/json?publisher_id=525&site_id=wikia&placement=test_btf&size=300x250&url=http://religion.wikia.com/wiki/Eternal_life&callback=AdMeldAPIClient.callback&container=PREFOOTER_LEFT_BOXAD&callback=jQuery17206533968118019402_1346004718780 jquery.min.js:4

GET http://tag.admeld.com/ad/json?publisher_id=525&site_id=wikia&placement=test_btf_right&size=300x250&url=http://religion.wikia.com/wiki/Eternal_life&callback=AdMeldAPIClient.callback&container=PREFOOTER_RIGHT_BOXAD&callback=jQuery17206533968118019402_1346004718781 jquery.min.js:4


GET http://religion.wikia.com/__spotlights/spc.php?zones=14%7C15%7C16%7C17%7C18%7C19%7C20%7C21%7C22&source=&r=71747338&loc=http%3A//religion.wikia.com/wiki/Eternal_life&referer=http%3A//religion.wikia.com/wiki/Bestla&target=_top&cb=30288526&hub=phil&skin_name=oasis&cont_lang=en&user_lang=en&dbname=religionwiki&tags=philosophy&block=1&charset=UTF-8 jquery.min.js:4


GET http://syndication.mmismm.com/tntwo.php?mm_pub=7333&u=http%3A%2F%2Freligion.wikia.com%2Fwiki%2FEternal_life&r=http%3A%2F%2Freligion.wikia.com%2Fwiki%2FBestla&t=420&tm=816148 sandbox_v100_cim_11_26_8.en.js:618 GET http://ad.doubleclick.net/adj/wka.phil/_religionwiki/article;s0=phil;s1=_religionwiki;s2=article;artid=31938;dmn=wikiacom;hostpre=religion;pos=TOP_LEADERBOARD;wpage=eternal_life;lang=en;dis=large;hasp=no;cat=articles_with_content_from_conservapedia;cat=christianity;loc=top;dcopt=ist;admeld=-1.00;ab=e1g1;src=driver;sz=728x90,468x60,980x130,980x65;mtfInline=true;tile=1;endtag=$;ord=22523392711? oasis_shared_js_anon:683


GET http://ad.doubleclick.net/adj/wka.phil/_religionwiki/article;s0=phil;s1=_religionwiki;s2=article;artid=31938;dmn=wikiacom;hostpre=religion;pos=TOP_RIGHT_BOXAD;wpage=eternal_life;lang=en;dis=large;hasp=no;cat=articles_with_content_from_conservapedia;cat=christianity;loc=top;admeld=-1.00;ab=e1g1;src=driver;sz=300x250,300x600;mtfInline=true;tile=2;endtag=$;ord=22523392711? oasis_shared_js_anon:683 Uncaught TypeError: Cannot read property 'sizes' of undefined oasis_shared_js_anon:690


GET http://religion.wikia.com/__varnish_liftium/error?msg=Error%20downloading%20config&type=general&pubid=999&lang=en&cb=570071 oasis_shared_js_anon:688


GET http://religion.wikia.com/__varnish_liftium/error?msg=Error%20downloading%20config&type=general&pubid=999&lang=en&cb=481716 oasis_shared_js_anon:688

GET http://cdn.krxd.net/controltag?confid=HixxvJVY oasis_shared_js_anon:1010


GET http://religion.wikia.com/__varnish_liftium/beacon?beacon=%7B%22numSlots%22%3A1%2C%22events%22%3A%22%22%2C%22country%22%3A%22us%22%7D&cb=629925 oasis_shared_js_anon:688