Tiki Design

Tiki Design

TikiWiki 1.10 Help! Top-menu.tpl? Strange behavior

posts: 17 United States

Okay this will be difficult to explain. I have a couple different 1.10 installations.

One is completely fresh and one is an upgrade from 1.9.9. In the upgraded installation, the Tikipedia theme shows the "top menu", or, the component that has the login link, the "my tiki" link and the search bar adjusted to the right.

In the fresh install, this bar does not display and search crams to the left behind the the edit tabs.

I've gone through the "features" and "look & feel" list of both sites and they are set identically. In the upgraded site, I have "site logo" checked but the site logo does not show up (as explained it wouldn't in the readme), in the "fresh install" site, site logo is checked but does in fact show up.

I've gone through a bunch of suspect tpl files and come up empty. I'm not quite sure where to begin the hunt for the missing/changed tpl files but needless to say there is definately changed behavior between a fresh 1.10 install and an upgraded one.

By any chance is it some kind of legacy Database value? Where do I start this search?

posts: 17 United States

Further information as I learn more:

The layout is controlled by the "tiki.tpl" file in the Tikipedia directory. In this TPL is a check for "$feature_top_bar". This wraps around a call to the file "tiki-top_menu.tpl" in the Tikipedia directory.

For some reason in the fresh deploy, this check is failing. I've confirmed in the database, in table "tiki_preferences" that the "feature_top_bar" value is set to "y". For whatever reason in the fresh deploy, this value is not being retrieved (confirmed by placing debug output before and after the if condition).

So, the question is, why in a fresh deploy would this value not be retrieved correctly but is working fine in an upgraded environment?

posts: 17 United States

To add to the mystery:

Dumping the PHP session info I can confirm that in the "prefs" array, "feature_top_bar" is actually set to "y".

For some reason the tiki.tpl file is *not* seeing this setting for tikipedia despite it being in the session.

posts: 17 United States

Ever have one of those "I'm a noob" moments?

So the culprit is the choice of "Syntax preference" in the general settings page. Tiki Wiki 1.10 uses a new syntax for grabbing preferences. This is set with a drop down.

In a fresh install, this value is set to 1.10. In an upgrade deployment this is left at whatever you had previously.

Hence the issue. So the real question is, do I go through all the tpl files and update them for 1.10 or take a shortcut and go back to 1.9 syntax and what breaks in the process?

posts: 254 Japan

maxfields2000, I give you credit for venturing into the unknown and learning as you go.

About the prefs syntax change, this is one of the biggest changes from 1.9 and 1.10 as far as the template files are concerned because it's global and affects a lot of files. While there is an admin switch to allow use of the old syntax, the forward-looking approach is to use the 1.10 syntax. Replacing $feature with $prefs.feature in templates/styles/(themename) takes care of most of these. I've done that for a few themes already now.

At http://zukakakina.com/110_theme_upgrade_issues I made a table of some upgrade issues I had run across, which may be helpful. (This was on my local (laptop) test site but I put it at Zukakakina in case anyone can use the info.) This isn't complete by any means but has some of the most apparent things.

-- Gary

posts: 17 United States


It's what I get paid to do! Well partially anyway.

Regardless, I did the string replace choice earlier for tikipedia and that resolved nearly all of it (also had to change the page permissions link to object permissions, mentioned that in another post). Still testing but Tikipedia doesn't change too many files (about 10 or so).

Kubrick, thankfully, is just a new tiki.tpl file, and that transferred easily with the string replace as well. I'm sure there's some new features not utilized by the old theme but what is there, works fine.

I don't play with a lot of the new style features yet, such as full screen mode and hideaway left/right columns, once I do these themes might need larger overhauls (though neither or the two above are well suited to column hides, their layouts don't require it).

So far, every time I think Tiki Wiki is about to do me in, i find a solution and move on. Its nice to have some knowledgeable folks to bounce ideas off of though. When I get a moment I'll attach a zip file to this thread of my theme updates to Tikipedia and Kubrick in case any searchers come across the same issue.

posts: 254 Japan

You can see an updated Kubrick here (well, some details not quite there yet): http://zukakakina.com/kubrick and the column-hiding does seem useful though it'd be up to the site admin and users whether to use it or not. I like being able to expand the center column when page editing and so on.

There's a handful of other themes there that will be available for 1.10 but I'm still doing the details and also more or less waiting for the 1.10 beta/rc release so not to have any compatibility problems.

Actually I've changed (simplified) parts of tiki.tpl for Kubrick/1.10, using fewer images for the header and so on, and I'm trying to use the same templates for a number of themes rather than each doing things slightly differently, as much as possible. The basic approach I've been taking is outlined on Tiki_110_Theme_Ideas. For themes like Kubrick, I can't get away from at least one table due to IE7's lack of display:table support, so I'm using a layout like the one described on http://zukakakina.com/Type2+Themes for themes with "fixed-width" content areas and side margins.

For full-width liquid designs, I'm using a table-less method as described on the Tiki 110 Theme Ideas page. This was used for earlier versions of Andreas09, Mittwoch, absE, Fluid Index, etc., and I intend to use it again for the 1.10 versions.

(The only 1.10 thing I haven't been able to figure out so far for the liquid, no-table theme layout is the side-column show/hide + center widening. Adapting the default mechanism works OK to turn on and off the column display, but the center div doesn't automatically expand to fill the space the way a table cell does. Some inline CSS is needed to switch the center div's margin property, I guess, but I don't know how to do both the side-column display switch and the center div margin switch in one click. I'll ask luci (*litecss author) about that, or if you have javascript skills you might take a look at that. wink.)

I intend to put the GPL/LGPL themes I do (or port) in Tiki's CVS (mods). Kubrick and a few others are already there, but while people have modified the files for their own use (generally downloaded from this site) nobody's updated the files in CVS, as far as I know. It'd be good to use the repository more if people are going to be working on the theme files with distribution in mind.

-- Gary

posts: 17 United States

I've just begun to go over your stuff at Zuka. I'm tasked with standing up a internal Intranet in, well, you know, yesterday. Small game development company. I chose TikiWiki for it's large support of base features out of the box. Sure, it wasn't the "prettiest" out of the box, but "pretty" can be fixed far faster than feature set.

Theme wise I'm almost set, Tikipedia for all Wiki sections (most of the intranet will be used as collaborative documentation), Corporate blog (Kubrick, 1.9 theme works fine for this... for now), and primary Intranet homepage. That page, sadly is the one I'm struggling with. I have an effective information layout with tikineat.css but frankly, I want more pizazz.

Andreas09 and Mittvoch I really like, both are on my "too fiddle with" list. I noticed Mozilla's support site uses Tikiwiki and that layout has a lot of potential as simple intranet header pages (too bad they didn't release it). So I'm basically showing off the work this Friday (not that itwas much work, more education, things worked right out of the gate minus the issues I've posted here).

And a proposal to do some UI/Skinning. The hard part for them won't be the idea that it needs work, it's that their IT Director (me) can do it if they give him the time :-)

We'll have no issues contributing the results back to the OpenSource community (in fact we'd be happy to). I've never personally "given back" so I'll ask for guidance here when I have some themeish work I'll stand behind a bit more then my untested hackjobs at the moment!

We also have big plans for the workflow engine in TikiWiki but that's not a discussion for t his board (unless I theme it all too... ugh, gonna be a long couple quarters!).

Switch Theme


Subscribe to Tiki Newsletters!

Delivered fresh to your email inbox!
Newsletter subscribe icon
Don't miss major announcements and other big news!
Contribute to Tiki

Site Config