How do you change the caption on a thickbox window to show the "title" of the image node, not the file name?
duran - January 6, 2009 - 16:03
| Project: | Thickbox |
| Version: | 6.x-1.x-dev |
| Component: | Code |
| Category: | support request |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | active |
Jump to:
Description
As the title says.
Currently the THICKBOX module shows the file name.
How can I change it so it shows the TITLE of the NODE, not the file name of the file attached to the node?
Thank you.

#1
Please try out the 5-dev version of Thickbox and add this on line 204 in the file thickbox.module.
// If the title is empty use alt or the node title in that order.if (empty($item['data']['title'])) {
if (!empty($item['alt'])) {
$item['title'] = $item['alt'];
}
else {
$item['title'] = $node->title;
}
}
It is right before this line:
if (strpos($formatter, 'thickbox][') !== FALSE) {I have not tested this, it's a quick backport from the 6-dev version.
#2
I'm not sure if it was clear in my OP, I apologize.
I'm using ... Thickbox 5.x-2.0
The only DEV branch I see for 5 is http://drupal.org/node/122466 which is a 5.1 dev...
Is that what you mean?
#3
Yes, that’s the one.
#4
Removed the thick box, put in the dev version.
This did not help.
I'm still seeing the file name, not the node title.
#5
I'm having the same issue with Drupal 6.