I was finally able to hunt down what's happening. Try this and let me know if anyone can reproduce --

1. Setup Themekey and select node:nid as a valid property. Also say that theme can be set on the node edit form
2. Go to a node and hit edit and set it to another theme. Save and you shouldn't see any change
3. Now go back to the themekey setting/properties page and look at the table. The property shows up here. Hit save at the bottom (even though you didn't make any changes)
4. Go back to the node you set the theme on originally and it'll NOW be in the different theme.

What is happening -- Themekey from the node edit form is setting the property in the themekey_properties table to be nid. nid is the OLD convention themekey looked for to detect what I theme should be equal to. The problem with this is that now it uses the convention node:nid. When you hit save, it resets all those table of settings so that nid now is node:nid.

Solution -- Go into themekey_ui_helper.inc and change line 17 from:

$item = array('property' => 'nid', 'value' => $nid, 'theme' => $theme);

$item = array('property' => 'node:nid', 'value' => $nid, 'theme' => $theme);

IF YOU DON"T ADD THE node: PART IT WON'T WORK!

Comments

garbanzito’s picture

had the same problem and applying the fix above worked for me too, Themekey now seems to properly store the per-node theme settings

btopro’s picture

It does, unfortunately if you go back and reload the node I'm seeing that it doesn't find the default property correctly. Instead what it's doing is storing ANOTHER record on node_save that's as if it was the "default theme" option (or whatever you set). When the query is run to influence the theme though it just grabs the first record it can find so it's still getting the theme that was initially set when the node was first created. All edits after the fact don't take affect, haven't been able to find the root of this problem but I'll need to soon and hopefully post a solution as it's affecting 2 sites we have now and is extremely annoying.

profix898’s picture

Oh, yes. I missed that completely. Sorry and thx for reporting.
Should be fixed in CVS version now. I plan to tag a bugfix release in 1-2 days.

profix898’s picture

Status: Active » Fixed

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.