Currently, the JS is added to the page if there is a box on the page. This JS is not required unless the user can actually administer boxes. Infact, having this JS on the page for anonymous uses is causing some bizare problems in IE7 where clicking on the box results in the content of the box being replaced with a spinning ajax icon!! Not good!

CommentFileSizeAuthor
#1 948970-boxes-nonadmin-nojs.patch574 bytesmrfelton

Comments

mrfelton’s picture

Status: Active » Needs review
StatusFileSize
new574 bytes

This seems to resolve it.

jmiccolis’s picture

Status: Needs review » Needs work

I agree that we should prevent the js from getting added for users who can't utilize it. I'd prefer to do it behind the existing access checks (if possible) instead of adding new ones.

mrfelton’s picture

@jmiccolis - not sure which new access checks you re referring to. boxes_access_admin is an access check already defined by boxes.

tirdadc’s picture

Assigned: Unassigned » tirdadc
Status: Needs work » Closed (fixed)

boxes_access_admin() makes sense since it factors in Spaces too, should it be enabled. Committed to both 6.x and 7.x versions.

http://drupalcode.org/project/boxes.git/commit/a77a243
http://drupalcode.org/project/boxes.git/commit/4cabd0c