Wikibooks:Reading room/Technical Assistance

Replacement filing cabinet.svgArchivesWikibooks Discussion Rooms
Discussions Assistance Requests Announcements
General | Proposals | Projects | Featured books General | Technical | Administrative Deletion | Undeletion | Import | Permissions Bulletin Board

Welcome to the Technical Assistance reading room. Get assistance on questions related to MediaWiki markup, CSS, JavaScript, and such as they relate to Wikibooks. This is not a general-purpose technical support room.

To submit a bug notice or feature request for the MediaWiki software, visit Phabricator.

To get more information about the MediaWiki software, or to download your own copy, visit MediaWiki

There are also two IRC channels for technical help: #mediawiki for issues about the software, and #wikimedia-tech for WMF server or configuration issues.


Cannot indent in the visual editorEdit

I was trying to add a glossary link to Pokémon when I found that for some reason the visual editor commands to indent or unindent paragraphs don't work. They are displayed as disabled on any page I have tried to edit and I have no idea why. I have tried reloading the webpage, opening a new browser tab, and logging in from a Private Browsing session; none had any effect. I'm using Safari 15.3 on a MacBook. Thanks! SupremeUmanu (discusscontribs) 21:07, 14 April 2022 (UTC)

@SupremeUmanu: can you add it if you "edit source"? I never use visual editor myself, but this would seem to be a workaround. --Jules (Mrjulesd) 14:13, 15 April 2022 (UTC)
Works great. I was dealing with an automatically formatted list markup format that the visual editor doesn't know how to handle yet. Cheers! SupremeUmanu (discusscontribs) 18:16, 19 April 2022 (UTC)

Linter concern wont clear...Edit

https://en.wikibooks.org/wiki/Special:LintErrors?pagename=LMIs_in_Control%2FPrint_version

I fixed the error in the underlying page, and checked I had. It still shows up here. Why is this happening even when I've purged the page concerned? ShakespeareFan00 (discusscontribs) 08:12, 27 April 2022 (UTC)

Yes I can't really figure it out. No problems in the source that I can see, it must be from the pages it transcludes I suppose. But it transludes a lot of pages, so it is difficult to see which one. You could go through each page to check for errors, but that would quite a while. --Jules (Mrjulesd) 19:48, 27 April 2022 (UTC)
I checked every single lint categeory for other pages that might be causing these. And there isn't a LintError present in the indvidual pages.. So there must be something odd happening when they combine.ShakespeareFan00 (discusscontribs) 20:18, 27 April 2022 (UTC)
Could be a bug in the linter itself? I'm not that good with linter stuff really. But alternatively you could ask at w:WP:VPT, they are pretty good there. --Jules (Mrjulesd) 20:23, 27 April 2022 (UTC)
I checked, and found there is - at least - one error:
find x "<b>" /c
 X: 2275
find x "</b>" /c
 X: 2276
- Erik Baas (discusscontribs) 21:57, 27 April 2022 (UTC)
On which page was that? --Jules (Mrjulesd) 09:38, 28 April 2022 (UTC)
On LMIs_in_Control/Print_version - Erik Baas (discusscontribs) 11:09, 28 April 2022 (UTC)

Relocating the table of contentsEdit

The table of contents for book chapters have been pulled out of the body recently :( and are turning up at the bottom of the navigation column where the are unseen and, IMHO, irrelevant. How can I return the table of contents back to the body of the chapter so that it is inline with the rest of the text? Or, failing that, how can I move the table to the top of the navigation column above the site material? Larsnooden (discusscontribs) 11:36, 30 April 2022 (UTC)

Please see WB:TOC, it should explain what you need to do. --Jules (Mrjulesd) 11:48, 30 April 2022 (UTC)
I have seen that, thanks, but it does not address the problem I see. The link's text does not say more than, "With __TOC__, it is placed at the same position where this code is placed". I do have the magic word __TOC__ in several chapters and that setting is still overridden and the TOC still ends up off to the bottom left in the navigation column and not where the magic word is placed. Larsnooden (discusscontribs) 12:00, 30 April 2022 (UTC)
Can you provide some examples? One tip that might be helpful is the template {{Clear}} which clears floating elements such as TOCs from other elements, and might help with placements. --Jules (Mrjulesd) 12:10, 30 April 2022 (UTC)
Sure. The chapter on Proxies and Jump Hosts has the magic __TOC__ word in place but the TOC is still shown down below the site navigation menu instead of inline. Most of the other chapters, such the one on Certificate-based Authentication, do not have __TOC__ and have the same problem. -- Larsnooden (discusscontribs) 12:18, 30 April 2022 (UTC)
Ah I think it might be a problem your end. On Certificate-based Authentication the TOC appears to me as coming after the first two paragraphs. On Proxies and Jump Hosts it comes after the first sentence. Tested on Firefox and Chrome browsers on a Windows 7 system. --Jules (Mrjulesd) 12:54, 30 April 2022 (UTC)
No. The problem is definitely in the wikibook site. I have not changed anything on my end recently nor have the __TOC__ markers been moved. Something broke there and needs to be repaired. Thanks. -- Larsnooden (discusscontribs) 12:59, 30 April 2022 (UTC)
If that's the case, can you explain to me why I can't replicate the problem on my system? One thing you could try is to bypass your cache. --Jules (Mrjulesd) 13:35, 30 April 2022 (UTC)
Dunno. I can't condone the use of Vista7 in any context, so I don't run it. But back to the problem here, I have cleared the cache, again, no luck. The problem rendering seems to be with Firefox 91.8.0esr-1 for Debian/Devuan om amd64 and maybe other versions of Firefox. Strangely, if I fetch the page using wget 1.21.3-1+b1 or curl 7.82.0-2 and then open the resulting file with Firefox, it renders as it should. Otherwise, lynx 2.9.0dev.10-1, Chromium 101.0.4951.41-2, and Brave 1.38.109 (all on amd64) all render the page correctly. Just Firefox is the exception. So maybe that narrows the possibilities? -- Larsnooden (discusscontribs) 04:03, 1 May 2022 (UTC)
I saved the page via Firefox and did a diff with files saved via the other web clients. There are a lot of differences so it seems that Firefox is getting served a very different page than the others, contrary to that which is expected. I haven't drilled down into all the deviations, but the second line differs in that Firefox gets the vector-sticky-header-enabled class, the others don't. -- Larsnooden (discusscontribs) 07:09, 1 May 2022 (UTC)

┌─────────────────────────────────┘

Pretty curious. Just tested those pages on Android using Firefox and Chrome, and they render correctly. So none of my devices or browsers have this problem.
So it's not a wikitext coding problem on the pages in question anyway, but could be some kind of bug going on, but whether it is client or server side is difficult to say.
Have you tried to w:WP:PURGE the pages in question using your problematic Firefox browser? If you are running the gadget LiveUTC clock, clicking on the clock time does this automatically.
Otherwise, it's possible the folks at w:WP:VPT might be able shed more light on this. --Jules (Mrjulesd) 08:19, 1 May 2022 (UTC)

css elementEdit

Does anybody know the name of the edit box element? I want to increase font-size. Thanks. L10nM4st3r/Roar at me 11:19, 6 May 2022 (UTC)

Sorry I don't quite follow you. Do you mean like mw:Extension:InputBox? I don't think you can alter the text size with it.
If this is incorrect please give me an example. --Jules (Mrjulesd) 11:32, 6 May 2022 (UTC)
@Mrjulesd: I mean the edit box when you click "edit", like when you edit a section or the whole page. It's the big one where you edit page content. I don't know if I can narrow that down any further. (Not the edit summary box) L10nM4st3r/Roar at me 12:04, 6 May 2022 (UTC)
@L10nM4st3r: oh I see. Well you have got some options available at Special:Preferences#mw-prefsection-editing, but they don't affect the font size. Have you got browser zoom? On Firefox I can press CTRL + which zooms in on the browser window, and increases font size.
Otherwise it might be able to alter this in class="wikiEditor-ui. So in your CSS something like .wikiEditor-ui {font-size:150% !important;} might work. --Jules (Mrjulesd) 13:06, 6 May 2022 (UTC)
I can zoom-in, but it doesn't keep that zoom once I leave the edit page, press reload or show preview. Even if I zom in, the whole page zooms in, instead of text size increasing, meaning that the text doesn't "wrap-around", if you know what I mean. It's not a massive deal. I made the "body" wider but comes with the side-effect that I can no-longer easily tap the place I want to. I will experement, however. L10nM4st3r/Roar at me 14:03, 6 May 2022 (UTC)
My device is grayscale, so redlinks look just like every other link. What is the id for those ones? Or how would I otherwise select it to change its style? L10nM4st3r/Roar at me 08:29, 10 May 2022 (UTC)
Red links seem to use the class = "new". So something like <a href="/w/index.php?title=Example&action=edit&redlink=1" class="new" title="Example (page does not exist)">Example</a> (looking at the HTML). --Jules (Mrjulesd) 23:14, 10 May 2022 (UTC)
For those with a similar question, use a.new to select a redlink. L10nM4st3r/Roar at me 09:11, 11 May 2022 (UTC)
@Mrjulesd: Not technical related, but please can you delete User:L10nM4st3r/monobook.css as its content has been copied onto my global meta css file. Please also delete User:L10nM4st3r/monobook.js. L10nM4st3r/Roar at me 09:25, 11 May 2022 (UTC)
@L10nM4st3r:  Done . --Jules (Mrjulesd) 09:37, 11 May 2022 (UTC)