mediawiki

Find Leaflet map object after initialisation

末鹿安然 提交于 2019-12-06 01:39:02
问题 I'm trying to change some things on a map that is already initialised by another script, using the Leaflet library. This other script did not store the map-object in a global variable, or in any other location I can access with my script. So currently there is a map on my page, but I don't have the map object. What I'd like to do is to retrieve the object of an already-initialised map, to make changes to it. For example, if there'd exist a function L.getMap('myID') I'd like to use such a

PHP Warning: PHP Startup: Unable to load dynamic library '…' failed to map segment from shared object: Cannot allocate memory in Unknown on line 0

谁说胖子不能爱 提交于 2019-12-06 01:26:48
Im getting the following on my developer machine. PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php5/20100525/gd.so' - /usr/lib/php5/20100525/gd.so: failed to map segment from shared object: Cannot allocate memory in Unknown on line 0 PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php5/20100525/mcrypt.so' - /usr/lib/php5/20100525/mcrypt.so: failed to map segment from shared object: Cannot allocate memory in Unknown on line 0 PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php5/20100525/mysql.so' - /usr/lib/php5/20100525/mysql.so:

Make MediaWiki not show the view history tab for unregistered users

[亡魂溺海] 提交于 2019-12-06 00:57:34
I have a question. How do I make mediawiki not show the [view history] tab for unregister users? I know you can use css to do it: in Mediawiki:common.css: #ca-talk { display:none!important; } #ca-history { display:none!important; } but it's for everyone, even logged in users,so i want to have a way to make it just unregistered users. Apparently, if you are running MediaWiki 1.18 or newer, you can add CSS that is only loaded for a specific user group. See the manual page for more information. So you should be able to add: #ca-talk { display:none!important; } #ca-history { display:none!important

How to speed up Pywikibot?

て烟熏妆下的殇ゞ 提交于 2019-12-05 21:15:48
问题 I've built some report tools using Pywikibot. As things are growing it now takes up to 2 hours to finish the reports so I'm looking to speed things up. Main ideas: Disable throttling, the script is read-only, so page.get(throttle=False) handles this Cache Direct database access Unfortunately I can't find much documentation about caching and db access. Only way seems to dive into the code, and well, there's limited information about database access in user-config.py . If there is any, where

Different sidebar for mediawiki pages

限于喜欢 提交于 2019-12-05 21:06:33
I have edited my sidebar as follows , *Navigation ** Projects|Projects ** Resources|Resources ** IRC Support|IRC Support ** Media Wiki Archive|Media Wiki Archeive **Vote on What We Do|Vote on What We Do * SEARCH * TOOLBOX * LANGUAGES i would like to have 3 different sidebar for 3 different pages ,my first page is http://www.hh.com/wiki/Main_Page for this page i would like to have the sidebar as *Navigation **Hello|Hello * SEARCH * TOOLBOX * LANGUAGES for another i would like to have http://www.hh.com/wiki/Page1 *Navigation **Page1|page1 * SEA1RCH * TOOLBOX * LANGUAGES My Question is, is it

How to add image with link in a sidebar - MediaWiki

浪尽此生 提交于 2019-12-05 19:37:01
I can add links to a MediaWiki sidebar this way: * some-url|url-text But how can i add image instead of text without hacking core or standard templates? I have read this: http://www.mediawiki.org/wiki/Manual_talk:Interface/Sidebar#Images_in_the_navigation_bar But it's just a feature request. Three possible approaches: Write a custom skin, that handles the sidebar any way you want. Write a tiny extension using the hook SkinBuildSidebar , to handle some custom code for images Use MediaWiki:Common.js to modify the sidebar using javascript. I would without doubt go for 2. edit: Note that some

Updating a media wiki article using Python?

橙三吉。 提交于 2019-12-05 19:33:54
Hi I have a cron job which collects some statistics about a service. I need the cron job to update a media wiki page (append to the page) programmatically. I am using python for the cron so what are my best options, are there any examples of mediawiki/python libraries or does Media wiki expose any HTTP/REST apis which I can use (may be through an extension). Thanks Sal9K If PyWikipediaBot is too heavy, try the Python module mwclient . You can login, view a page’s current content, make your change and then view it in less than 10 lines (example) . import mwclient site = mwclient.Site('en

Semantic mediawiki #ask query: Displaying nested properties on the same query

孤街醉人 提交于 2019-12-05 18:42:40
I would like to display in the same query properties of a page which is related to the pages im querying for. Let's say I would like to query all the pages in the City category, which are located in Germany, and I want to display the title of the page, but also I want to display the surface data of Germany, for example. Something like this: {{#ask: [[Category:City]] [[location::Germany]] |?mainlabel |?Location.surface }} I know this wont work, but you can see what I want to achieve. I'm not sure if there's a way to nest queries directly inside other queries. The normal method of doing it is

How to change font size and colour in Mediawiki navigation sidebar and footer?

人盡茶涼 提交于 2019-12-05 11:31:49
My website was developed using Mediawiki and I have the following question: How do I change the font size and font colour in the navigation sidebar and footer? I am using the vector skin and having difficulties finding the correct way to make these changes. For the navigation: search in your css to div#mw-panel div.portal div.body ul li a { color: #0645AD; } div#mw-panel div.portal div.body ul li a:visited { color: #0B0080; } and change it to div#mw-panel div.portal div.body ul li a { font-size:16px; color: #008000; } div#mw-panel div.portal div.body ul li a:visited { color: #A0600B; } use

mediawiki mathjax need to use escape $x$

╄→гoц情女王★ 提交于 2019-12-05 11:24:25
I am using MediaWiki with MathJax, because a lot of the pages have maths equations. But on some pages I also need to display the string $x$ as is. Is there any way to escape the $x$ so it doesn't invoke MathJax and display as an italic x? MathJax supports \$ to escape a $ within an expression, but that doesn't work with the initial $ (of course). If you set processEscapes:true in the tex2jax section of your configuration, then you will be able to escape the initial dollar sign to allow you to type $x$ . Alternatively, you can use <span class="tex2jax_ignore">...</span> around the text you don