We want to change the list of URL appearing at bottom of print pages and PDF. Especially we want to remove URLs linking to Drupal admin pages while page is printing or preparing PDF while logged in as admin.

hook_print_url_list_alter() is not useful to remove URLs.

I see function _print_friendly_urls() keeping URLs in a static variable and I thought to manipulate that variable in a hook_preprocess_print_url_list() implementation, but I can't with that current code using plan static variable. If it is using drupal_static() then it is possible to get that same static variable by passing function name, _print_friendly_urls, to drupal_static().

CommentFileSizeAuthor
#2 use-drupal-static-3023200-2.patch419 bytesjunaidpv
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

junaidpv created an issue. See original summary.

junaidpv’s picture

Status: Active » Needs review
FileSize
419 bytes

Here is that simple patch.

jcnventura’s picture

Status: Needs review » Reviewed & tested by the community
jcnventura’s picture

  • jcnventura committed 2c49baa on 7.x-2.x authored by junaidpv
    Issue #3023200 by junaidpv, jcnventura: Use drupal_static() instead of...
jcnventura’s picture

Status: Reviewed & tested by the community » Fixed

Thanks!

Status: Fixed » Closed (fixed)

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