Add Modal Frame to Taxonomy Help Text

Anyone have any idea how to embed a JS type hyperlink into a Taxonomy (vocabulary) 'Help Text' - which is the bit of text presented to a user in a node edit form under the taxonomy select term dropdown. What I'm trying to do is embed a 'More Help' type link which will generate a modal frame or popup to link to some other site content to give more detailed help to users when selecting taxonomy terms (eg, offer descriptions etc). I've been playing with Batax and TaxiSelect modules for multiple select/autotype (rather than the conventional drop-down), but still need to provide detailed help for newbies.

I think there was heavy sanitization of the 'Help Text' field in a core (taxonomy) security update last year to prevent XSS, so the usual suspects (Thickbox etc) don't work when embedded here. Any text entered in this field is also trimmed to a pretty short length.

So far the cheekiest I can embed in the 'Help Text' is a <a href=LINK_TO_HELP_FILE target='_blank'>More Help</a> type link.

Any ideas, other than hacking core??

Login or register to post comments

The following works fine for

nicholas.alipaz - Tue, 2010-03-02 06:13

The following works fine for me when using shadowbox. I would assume that something similar would work for thickbox:

here is some help, you can use this to find out more, <a href="/node/1" rel="shadowbox;player=iframe;height=140;width=120">more help</a>

edit, left out a bit of code...


oh yeah. remember that to

nicholas.alipaz - Tue, 2010-03-02 06:17

oh yeah. remember that to use this with shadowbox you would have to adjust height/width and enable shadowbox for node/add and node/*/edit pages since it is disabled by default in the shadowbox settings.

You may also need to create a popup that doesn't have a header/footer, that is a custom tpl file and beyond the question you are asking however.


Thanks - Tried Lightbox2 too

snorkers - Tue, 2010-03-02 20:05

Thanks - Shadowbox was great. Also tried out Lightbox2 too. Some really useful guidance at http://drupal.org/node/252260 on creating modal web pages, although the Taxonomy Help Text sanitization seems to strip a few options out of the <rel> tag (specifically the modal page width and height - think it may be the | vertical bar that causes the problem).

I hadn't realized that Thickbox is no longer being maintained as a jQuery library. So will probably move all my work over to Lightbox2, as it seems to be the only lightbox style module that is universally supported by other modules. Great comparison (recently updated) of such Drupal modules at http://drupal.org/node/266126