Extension talk:CategoryTree

Jump to: navigation, search

About this board

Archives 

1 (2006/2007) - 2 (2008) - 3 (2009) - 4 (2010) - 5 (2011)


By clicking "Add topic", you agree to our Terms of Use and agree to irrevocably release your text under the CC BY-SA 3.0 License and GFDL

Count is correct but only gray arrows are shown in sidebar

5
User71649 (talkcontribs)

Mediawiki 1.26.2

Try to get this working in my Sidebar using the default Vector skin.

The number of sub-pages and subcategories are correct but only a gray arrow is shown and so I can't traverse the category tree.

Interesting, for categories that have their own sub-categories, the arrow is completely gone!

Here are my  LocalSettings.php parameters:

$wgUseAjax = true;

require_once "$IP/extensions/CategoryTree/CategoryTree.php";

$wgCategoryTreeSidebarRoot = "Category:Sidebar";

$wgCategoryTreeSidebarOptions['showcount'] = true;

User71649 (talkcontribs)

I can confirm the problem exists in a fresh installation of MediaWiki 1.26.2 installed from the bitnami MAMPstack + MediaWiki.

154.43.0.14 (talkcontribs)

I have the same problem with MediaWiki 1.26.2 and the last CategoryTree code from git

User71649 (talkcontribs)

I've reverted to Medaiwiki 1.23.13 and the problem is absent.

A little surprised that the 6th top download extension (according to Special:ExtensionDistributor) can be incompatible with the latest mediawiki version that is almost 5 months old now.

I think I'm going to stick to the LTS versions of mediawiki from now on.

130.226.230.2 (talkcontribs)

Se the topic above. Replacing "$content.find" with "$" in ext.categoryTree.js (to places) seems to fix the problem in MediaWiki 1.26.

Reply to "Count is correct but only gray arrows are shown in sidebar"
NicolasEcarnot (talkcontribs)

Hello,

Using MediaWiki 1.26.3 and CategoryTree 2016-01-09T22:52:17, I'm using it in the sidebar with $wgCategoryTreeSidebarRoot = "myRootCategory";

I'm quite happy with that but when clicking on the blue arrows, nothing is happening.

I read the doc and tried the workarounds, but to no avail.

I'm not using redirects or short URLs.

Our setup is very simple and common.

Is there something I could try?

Thanks for your help.

Mhausi (talkcontribs)

this works for me: fix sidebar in MW

130.226.230.2 (talkcontribs)

Brilliant! Replacing "$content.find" with "$" in ext.categoryTree.js (to places) seems to work perfectly in MediaWiki 1.26 as well.

Will someone fix this in the CategoryTree distribution?

Reply to "Unable to expand arrows in sidebar"

Setting more than one attribute not working

4
Stoettner (talkcontribs)

All,

when setting

<categorytree mode=pages hideprefix=always>Root</categorytree>

the result considers only the first attribute mode=pages.

What is the correct syntax for setting more than one attribute?

many thanks,

wiley

Kghbln (talkcontribs)

I can imaging that

<categorytree mode="pages" hideprefix="always">Root</categorytree>

might do the trick. Not tested this though. Perhaps one cannot add more that one option which would be sad. Did not use this so far.

Stoettner (talkcontribs)

Sadly not working. Instead using

$wgCategoryTreeOmitNamespace = true;

to globally disable NS rendering in categories. Can't believe that an extension with such broad usage is not allowing this.

Kghbln (talkcontribs)

Ah, yeah, this would have been too easy. I just saw on the docu that newer versions should probably use

$wgCategoryTreeDefaultOptions['hideprefix'] = true;

Not to mention that the docu is rather a disaster. :( Anyways, glad it works.

Well, if WMF does not have a usecase or sees the need the chances are pretty low that we will be getting something like this via the tag.

Reply to "Setting more than one attribute not working"

Customized collapse/expand/empty images broken after update

3
Rbirmann (talkcontribs)

Hi,

I am having an issue with this extension after upgrading MW from 1.22 to 1.26. I have also updated my CategoryTree extension from whatever version I had installed a couple of years ago to the latest available version, so I am not sure to which of these upgrades my issue is related.

In our wiki, back in MW 1.22 and the old CT version, we had changed the color of the category tree bullets by changing MediaWiki:categorytree-collapse-bullet, MediaWiki:categorytree-expand-bullet and MediaWiki:categorytree-empty-bullet to something like this:

<span style="color:#ffd15a;">▼</span>

This was working fine, but now, in MW 1.26 with the latest CT version, if I click on a ► bullet to expand the category tree, the clicked bullet is replaced by:

<span style="color:#ffd15a;">▼</span>

... as if the contents of MediaWiki:categorytree-collapse-bullet were enclosed in <nowiki> tags.

Is this intentional behaviour? Or is it a bug?

Either way, how can I change the color (or content) of the bullets in the latest CategoryTree version?

Maybe (just thinking out loud here), editing MediaWiki:Common.css and adding a CategoryTreeToggle style definition there? Haven't tried this...

Thanks in advance

12.156.206.58 (talkcontribs)

just started working on a mediawiki site and had issues with the CategoryTree 1.26 extension. I ended up using an older version (I used 1.23). My issue with the 1.26 CategoryTree extension was it hid all of the WYSIWG buttons for the wiki editor.

I did change the color of my triangles. The CSS looks different than yours in my version of CategoryTree. The triangle element had a class surrounded it, so it was easy to target. Hope that helps

178.251.183.178 (talkcontribs)

I never ment to do this. I can take full blame and I do. You are really a wonderful person who works hard. in all forms and thats respectable by all individuals I will vouch for you and push people who are against you to think twice. I know i put u down. I really dragged a lot of people down so dont feel to discouraged. I wasnt even that happy when we were dating. the last year was when i was losing confidence. It was so strange we were dating to me. I knew it wouldnt last forever. The fact that we lastest two years was supper and i thought well two years means forever. I quickly now understand things dont get to last forever. unless you take drugs and thats just got to hurt you in the butt. well not all the time. i thought taking a bottle of this concerta was going to kill me today but instead i discovered this new tree and that i want inside

Reply to "Customized collapse/expand/empty images broken after update"

Insert CategoryTree right of Content?

5
AmazingTrans (talkcontribs)

How can i insert the categoryTree to the right of the Contents box? Also, can i encapsulate the categoryTree in a box like the Content?

174.78.145.241 (talkcontribs)

yeah, just put it inside a div. so, surround the code calling for the category tree with something like

<div style="float:right; display:block; brackground-color:grey; border:1px solid black">

category tree coding

</div>

Meriware (talkcontribs)

Hrm. That appears to lose the toggles to contract / expand the tree.

Reply to "Insert CategoryTree right of Content?"

force categorytree to update when add new page.

4
Siggiae (talkcontribs)

I am invoking categorytree with the syntax {{#categorytree:Embryo|mode=pages|showcount|depth=2 etc. When I create a new page and add it to the category Embryo, categorytree will not list the new page. I can close/open the page that invoked categorytree, login again with no effect. If I look directly at the page Category:Embryo the new member page is listed immediately. The only way I can get the {{#categorytree:Embryo etc to update is to resave the page where it occurs. Same behavior if I use the tag syntax.

There must be a better way, I thought this function was dynamic. No obvious warnings of this behavior on the relevant help page or in discussions. Suggestions?

91.192.31.192 (talkcontribs)

I'm also seeing this. shouldn't it populate the tree automaticly?

178.251.183.178 (talkcontribs)

yes it should make the tree grow even tho right not my tree isnt growing

Reply to "force categorytree to update when add new page."

CategoryTree menu disappeared

3
Summary by Tacsipacsi

The problem was with another extension.

Castroblop (talkcontribs)

When I upgrade to Mediawiki 1.26.2, CategoryTree disappeared from bottom of edit page. Where previously there were drop-down menus of parent-child-grandchild categories, there is only now the parent category and a orphan category. Do you know how this can be solved?? My LocalSettings.php for CategoryTree

require_once( "$IP/extensions/CategoryTree/CategoryTree.php" );
$wgUseAjax = true;
$wgCategoryTreeDynamicTag="True";
$wgCategoryTreeSidebarRoot="BS";
$wgCategoryTreeDefaultOptions['mode'] = 'all';

And the wiki is running

  • MediaWiki 1.26.2
  • PHP 5.5.9-1ubuntu4.14
  • MySQL 5.5.47-0ubuntu0.14.04.1
  • Vector skin
  • CategoryTree (11fd8ec)

Here is an example of how the CategoryTree menu now looks http://beyond-social.org/wiki/images/7/7b/SelectCategory-edit.png thanks a

Tacsipacsi (talkcontribs)

I don't know why does it work at all, I don't see any configuration turning it on (if the wiki is beyond-social.org). The documentation says nothing that these variables should do this, neither see I anything in the MediaWiki namespace. If you speak about another wiki, what is that? Making it publicly editable (at least in some namespaces) for a few days would help me to debug.

Castroblop (talkcontribs)

I confused CategoryTree with SelectCategory. Apologies

Jeffatcw (talkcontribs)

At least for the purposes of my site, it would be better to have the articles for a category listed before the subcategories so that you have the following:

Category name

article 1

article 2

> Subcategory 1 name

> Subcategory 2 name

and then when you expand a subcategory, you get the articles in that subcategory listed before it's subcategories, etc.

If this is doable, I can't see it. Can it be done?

Jeffatcw (talkcontribs)

Of course, when I say "article", I use it to mean the same as "page".

Reply to "A more logical sort order"
PascalKT (talkcontribs)

We get some error in the apache log due to the CategoryTree extension. (using MDW 1.26)

PHP Warning:  OutputPage::getModuleStyles: style module should define its position explicitly: ext.categoryTree.css

any ideas ?

2620:0:1000:1704:359F:C020:9E78:B83C (talkcontribs)

I fixed it by going to /public_html/extensions/CategoryTree/CategoryTree.php, and adding the position field:

$wgResourceModules['ext.categoryTree.css'] = array(

'position' => 'top',

'styles' => 'ext.categoryTree.css',

) + $commonModuleInfo;

Reply to "PHP Warning : ext.categoryTree.css"

Clicking the ► has no effect in the sidebar

1
Gigajoule (talkcontribs)

Mediawiki 1.26.2.

First I got only one level depth while visualing the tree. So I set in CategoryTreeFunctions.php file the following line

$linkattr['style'] = 'display: none;'; // Unhidden by JS

to

$linkattr['style'] = 'display: inline !important;'; // Unhidden by JS

After that, clicking the ► has no effect in the sidebar

The javascript intended to switch the tag style is somehow buggy. I confirm.

Reply to "Clicking the ► has no effect in the sidebar"