Hi there!
Does anyone knows how do I theme the popup help? Modules´ popups have the similar css that merlin´s advanced help popup (with the light blue background). But, it seems that my popups doesn´t have any css style at all.

I haven´t exported all help in a news help module, because my help texts still changes very frecuently.

The stuff that I add to helpinject.css doesn´t work, and I didn´t find any class that I could add to my normal theme style.css file.

Anyway, does anyone has this problem? How can I solve it?

Thanks!!
Rosamunda

CommentFileSizeAuthor
#7 563292-helpinject-popup-style.patch719 bytesmrfelton

Comments

robertdouglass’s picture

Priority: Normal » Critical

You're right that at the moment it's not set up properly for this. I'll make this a critical issue for next release.

Rosamunda’s picture

Thanks!

ianchan’s picture

subscribe

ianchan’s picture

I haven't figured out how to do this in template.php. However, here's how to add theming to pages generated by this module.

1. Copy /drupal-install-path/sites/all/modules/advanced_help/advanced-help-popup.tpl.php to your theme folder.

2. Modify "function helpinject_popup" (around line 122) to this:

function helpinject_popup($node) {
  $content = node_view($node, FALSE, TRUE, FALSE);
  print theme('advanced_help_popup', $content);
  exit;
}

3. Edit the copy of advanced-help-popup.tpl.php that is in your theme folder

Note: $styles within the copy of advanced-help-popup.tpl.php that is in your theme folder does not include theme style sheets.

shaneonabike’s picture

This worked great and it would be awesome to add this to the source code rather than patching the module :)

Actually I poked around Advanced help and found code for popups that I meshed with the code created above...

function helpinject_popup($node) {
  // This technique gets us the title, the rendered body, and everything like
  // uploaded files, but the "authored by" cruft is now doubled.

  // [SB]: Modified these lines so that the output could be themed properly
  $GLOBALS['devel_shutdown'] = FALSE; // Prevent devel module from spewing.
  module_invoke('admin_menu', 'suppress'); // Suppress admin_menu.

  // Previous code adde
  $content = node_view($node, FALSE, TRUE, FALSE);
  print theme('advanced_help_popup', $content);
  exit;
}

Mainly this is good b/c it suppresses the devel and admin_menu in the help popup. I ended up removing the status messages from the tpl file as well so that if there were any messages they wouldn't be displayed (to make this more of a popup style.

Awesome!

Rosamunda’s picture

Thanks for the code!
So this is ready to be commited??
That´s good news!!!

Rosamunda

mrfelton’s picture

Status: Active » Needs review
StatusFileSize
new719 bytes

Here is a patch - popups look a million times better with this.

mrfelton’s picture

Status: Needs review » Needs work

Problem is though, that the breadcrumbs and book navigation links don't work - you jump back to the main site theme when you use them.