I was looking at the text_resize.module, and I noticed that all the CSS and js is being added through text_resize_init(). But that means that the CSS and javascript will be added on every page, regardless of whether the block is on a given page or not. Pages without the block are getting unnecessary css and js overhead.

It may be better for those to be added in text_resize_block() (where $op == 'view') so that they are only loaded when needed.

Comments

attheshow’s picture

Category: support » feature
Status: Active » Postponed

Do you have a patch that includes code suggestions on how you mean to go about this?

http://drupal.org/patch/create

attheshow’s picture

Version: 6.x-1.6 » 7.x-1.x-dev
Status: Postponed » Closed (fixed)

Pushed a fix for this to 7.x branch.