Extension talk:Popups/2019

Setting up Popups using Page Content Service instead of TextExtracts

edit

I am under the impression that using Page Content Service to summarize articles could be more effective than TextExtracts on my wiki. I, however have no idea how I would go about using it instead of TextExtracts.


I am under the impression I will need to use $wgPopupsGateway and $wgPopupsRestGatewayEndpoint to accomplish this but couldn't find enough information to do it.


Hoefsldyla (talk) 19:39, 8 January 2019 (UTC)Reply

SpecialPages returns Fatal Error

edit

Fatal error: Uncaught Error: Call to undefined method MediaWiki\MediaWikiServices::getSpecialPageFactory() in /var/www/html/htdocs/xxx/mediawiki/extensions/Popups/includes/PopupsContext.php:169 Stack trace: #0 /var/www/html/htdocs/xxx/mediawiki/extensions/Popups/includes/PopupsHooks.php(86): Popups\PopupsContext->isTitleBlacklisted(Object(Title)) #1 /var/www/html/htdocs/xxx/mediawiki/includes/Hooks.php(177): Popups\PopupsHooks::onBeforePageDisplay(Object(OutputPage), Object(SkinVector)) #2 /var/www/html/htdocs/xxx/mediawiki/includes/Hooks.php(237): Hooks::callHook('BeforePageDispl...', Array, Array, NULL, 'Popups\\PopupsHo...') #3 /var/www/html/htdocs/xxx/mediawiki/includes/OutputPage.php(2385): Hooks::runWithoutAbort('BeforePageDispl...', Array) #4 /var/www/html/htdocs/xxx/mediawiki/includes/exception/MWExceptionRenderer.php(135): OutputPage->output() #5 /var/www/html/xxx/goroinfo/mediawiki/includes/exception/MWExceptionRenderer.php(54): MWExceptionRenderer::reportHTML(Object(Error)) #6 / in /var/www/html/htdocs/xxx/mediawiki/extensions/Popups/includes/PopupsContext.php on line 169 86.126.48.166 (talk) 16:14, 15 January 2019 (UTC)Reply

Looks like you need go upgrade your mediawiki version. Jdlrobson (talk) 21:48, 6 March 2019 (UTC)Reply
Did updating MediaWiki and/or Popups fix the problem? Phuedx (WMF) (talk) 10:54, 23 May 2019 (UTC)Reply

Image don't displayed

edit

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


I have a problem on my wikia - images on prewiew don't displayed, only text. 178.95.173.141 (talk) 18:14, 13 February 2019 (UTC)Reply

Do you have Extension:PageImages installed? Jdlrobson (talk) 21:48, 6 March 2019 (UTC)Reply
Yes, but PageImages don't displayed images from infoboxes, please hepl to fix this. 46.211.45.231 (talk) 12:54, 25 March 2019 (UTC)Reply
This is, because PageImages (even for mw 1.32) may still have a bug.
Look at includes/LinksUpdateHookHandler.php and compare your version with
https://gerrit.wikimedia.org/r/#/c/mediawiki/extensions/PageImages/+/458748/9/includes/LinksUpdateHookHandler.php
https://phabricator.wikimedia.org/T203965
It took me one week until I could fix this it. It's still a very stupid problem. 217.92.248.228 (talk) 11:00, 18 April 2019 (UTC)Reply
ok, has been fixed in the mw 1.32 version. well done all right. 217.92.248.228 (talk) 11:06, 18 April 2019 (UTC)Reply
The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.

popups not working and crashing entire site (MediaWiki 1.32)

edit

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


Unfortunately for me, this extension is completely not working on MediaWiki 1.32. I have all required extensions downloaded and installed for correct version of MW and every time the line "wfLoadExtension( 'Popups' );" is active, my local wiki crashes with this:


Warning: require(\xampp\htdocs\pagetest/extensions/Popups/includes/ServiceWirings.php): failed to open stream: No such file or directory in \xampp\htdocs\pagetest\includes\services\ServiceContainer.php on line 120

Fatal error: require(): Failed opening required '\xampp\htdocs\pagetest/extensions/Popups/includes/ServiceWirings.php' (include_path='\xampp\htdocs\pagetest\vendor/pear/console_getopt;\xampp\htdocs\pagetest\vendor/pear/mail;\xampp\htdocs\pagetest\vendor/pear/mail_mime;\xampp\htdocs\pagetest\vendor/pear/net_smtp;\xampp\htdocs\pagetest\vendor/pear/net_socket;\xampp\htdocs\pagetest\vendor/pear/pear-core-minimal/src;\xampp\htdocs\pagetest\vendor/pear/pear_exception;\xampp\php\PEAR') in \xampp\htdocs\pagetest\includes\services\ServiceContainer.php on line 120 (I've intentionally skipped drive letter; and before you ask for a website address - wiki is on my local PC and therefore not accessible from the internet!)


And here is a part of my LocalSettings.php file:

# The following extensions were automatically enabled:

wfLoadExtension( 'CategoryTree' );

wfLoadExtension( 'Cite' );

wfLoadExtension( 'CiteThisPage' );

wfLoadExtension( 'CodeEditor' );

wfLoadExtension( 'Gadgets' );

wfLoadExtension( 'ImageMap' );

wfLoadExtension( 'InputBox' );

wfLoadExtension( 'Interwiki' );

wfLoadExtension( 'MultimediaViewer' );

wfLoadExtension( 'OATHAuth' );

wfLoadExtension( 'ParserFunctions' );

wfLoadExtension( 'PdfHandler' );

wfLoadExtension( 'Poem' );

wfLoadExtension( 'SyntaxHighlight_GeSHi' );

wfLoadExtension( 'WikiEditor' );

wfLoadExtension( 'RandomSelection' );

wfLoadExtension( 'CharInsert' );

wfLoadExtension( 'BetaFeatures' );

$wgPopupsBetaFeature = true;

wfLoadExtension( 'PageImages' );

wfLoadExtension( 'TextExtracts' );

//wfLoadExtension( 'Popups' );← when I mark this as a comment, everything goes ok

$wgBetaFeaturesWhitelist= array('popups');

$wgPopupsOptInDefaultState = '1';

$wgPopupsHideOptInOnPreferencesPage = true;

$wgPopupsReferencePreviewsBetaFeature = false;


So what's going on and how can I get Popups to work? 37.30.23.167 (talk) 16:11, 9 May 2019 (UTC)Reply

It looks as if the version of the Popups extension is mismatched to the version of MediaWiki. For example, the master branch is not expected to work against relatively older version of MediaWiki.
If you are using the master branch, then perhaps you could try the following and see if it works:
cd /path/mediawiki/extensions/Popups</code> git fetch origin git checkout origin/REL1_32
Phuedx (WMF) (talk) 16:15, 10 May 2019 (UTC)Reply
Thank you for your help, I'll check if it works. In the meantime, I've managed to find another solution – by downloading and installing older version of Popups (1.27) without changing anything else. 37.30.23.167 (talk) 23:24, 11 May 2019 (UTC)Reply
Great! Thanks for the update.
Phuedx (WMF) (talk) 15:06, 12 May 2019 (UTC)Reply
The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.

Images displaying as broken images (1.31.1)

edit

Heya.

Ever since I updated to 1.31.1, images now display as broken file links (example), even though the pages have the "page image" section filled (example). I've updated the extensions to the appropriate versions (1.31.1) but still nothing. Am I missing someone really obvious, or is it some kind of bug?

I tried the below method in the "Image don't displayed" thread, but no noticeable changes happened.

Parameters:

  • MediaWiki: 1.31.1
  • PHP: 7.1.14 (cgi-fcgi)
  • MySQL: 5.6.41-84.1
  • ICU: 4.2.1.
  • LUA: 5.1.5.

Any ideas? SupermanFan97 (talk) 02:38, 22 May 2019 (UTC)Reply

Disable popups for a[href^="#"]

edit

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


In my opinion, there's no (good) reason to have a page preview for any link that starts with a #, because those links are always to the page itself. You don't need a preview for pages you're already on them, so there's no need to show the preview.

This is relevant because in some situations, such as in Extension:Kartographer, the zoom-in and zoom-out buttons are links with a title="zoom (in|out)" attribute, and because this extension triggers on (it seems) any a[title], those links get a popup, which is completely pointless.

Now I could ask Kartographer to change their code, but I think their implementation is fine, since they're using the title attribute exactly as it's intended. So, to fix this issue, this extension should be changed a bit that a[href^="#"] does not trigger a popup. Joeytje50 (talk) 10:57, 17 July 2019 (UTC)Reply

Hmm. That's a good point regarding links that are buttons. See also phab:T198652 regarding "^" links in the <references /> section.
However I still hope that we'll eventually get functionality for previewing ==section== links (See phab:T156041 and duplicates), so I'd be worried about any solution which blocked that. –Quiddity (talk) 18:19, 17 July 2019 (UTC)Reply
In that case, at least preventing a[href="#"] would fix it. The only way that ever appears is in scripts that insert it (since [[#]] doesn't link to "#", but instead links to the actual page itself as an actual link), and those scripts never intend for it to be a link to the top of the page. Joeytje50 (talk) 12:46, 18 July 2019 (UTC)Reply
I believe the issue described here is resolved with phab:T212419 as well as the changes later done to fix the regression described in phab:T216683. Please feel free to reopen this topic or create a new Phabricator ticket in case we missed something. Thiemo Kreuz (WMDE) 15:32, 26 September 2019 (UTC)Reply
The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.

No Popups for new users

edit

i'm using (8711244) 22:37, 11. Okt. 2018 on MW 1.32

with

wfLoadExtension( 'Popups' );

$wgPopupsHideOptInOnPreferencesPage = false;

$wgPopupsOptInDefaultState = "1";

$wgPopupsReferencePreviewsBetaFeature = false;


newly created users are opted out of popups

mysql> SELECT * FROM user_properties WHERE up_property = 'popups' \G

*************************** 1. row ***************************

up_user: 16

up_property: popups

up_value: 0


Only when i set the (not documented) Option: $wgPopupsOptInStateForNewAccounts = "1"; new users have working PopUps. I took this option from extensions/Popups/tests/phpunit/PopupsHooksTest.php


Is this the wrong way or is there just some documentation missing?


~ Felix 93.240.33.54 (talk) 08:40, 4 September 2019 (UTC)Reply

Hey Felix. Thanks for highlighting this. It looks like the documentation is out of date. You're correct, you need to set both
$wgPopupsOptInDefaultState = 1
$wgPopupsOptInStateForNewAccounts = 1.
This config setup is related to Wikipedias, as we had to treat new accounts bit differently to old one, that's why there are two config variables ($wgPopupsOptInDefaultState and $wgPopupsOptInStateForNewAccounts). It's pretty well explained in the extension.json file, but definitely it's bit unclear on how to set it up properly on other non-wiki installations.
I'll update the README file and explain on how to properly set configs, and update the default config to make it easier to setup. Polishdeveloper (talk) 14:49, 4 September 2019 (UTC)Reply

Issues when used with Extension:Tabber

edit

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


as Pwrest a year ago already asked and never got answered. I also have the same troubles using Popups alongside Tabber Extension. Is there a hint wich could help solving that issue? Or maybe is there a full solution to that? Xaase (talk) 11:13, 13 December 2019 (UTC)Reply

The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.
Return to "Popups/2019" page.