If using a Node add form context in a panel, the default name for the keyword is "node_add" with an underscore. Keyword substitutions tell you to use "%node_add:type" to display the node type. The problem is that this displays as:

"{node title}_add:type"

where "{node title}" is the actual title of the node you're currently in, essentially replacing the "%node" in "%node_add" with the title and ignoring the underscore and all that comes after it.

Removing the underscore from the keyword in the context setup fixes this problem.

Comments

merlinofchaos’s picture

Status: Active » Fixed

Fixed _ and - both.

merlinofchaos’s picture

Project: Panels » Chaos Tool Suite (ctools)
Version: 6.x-3.0-rc1 » 6.x-1.x-dev
Component: Plugins - contexts » Code

This was actually a ctools bug.

Status: Fixed » Closed (fixed)

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

locomo’s picture

Version: 6.x-1.x-dev » 6.x-1.0-beta4

i'm having trouble with underscores in my keyword substitutions - when i remove them they work fine but when included they print directly to screen without being re-coded

e.i. %content_profile:title shows up in my panel as "%content_profile:title"

i'm using ctools 6.x-1.0-beta4

merlinofchaos’s picture

Let's see:

Date on -beta4: ctools 6.x-1.0-beta4 -- July 12, 2009 - 10:37

Date on my commit above: August 3, 2009 - 13:43

Also, you are posting about bugs 2 versions out of date. Please don't. That wastes everybody's time, including yours.

Rosamunda’s picture

Version: 6.x-1.0-beta4 » 6.x-1.2
Priority: Minor » Normal
Status: Closed (fixed) » Active

Hi!
I´m using 6.x-1.2 and the error seems to be the same that it´s reported here:
I´m trying to use as the panel title "%content_profile:title" and it just won´t show up. I´m using it in APK (Advanced Profile Kit) and it seems that´s a CTools issue.
I think it´s better to reopen this than to open a new issue...
Thanks!
Rosamunda

merlinofchaos’s picture

Status: Active » Fixed

I have double checked and _ is being properly used as of CTools 1.2 -- perhaps there is something else wrong, such as a typo or the context not actually being available.

Status: Fixed » Closed (fixed)

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