Handle dynamic addition of attributes

Handles dynamic addition of attributes to <link rel=stylesheet>
elements.

Fixes #3361
Merge pull request #3432 from gilles-leblanc/issue-3361

Handle dynamic addition of attributes

Reviewed-by: jdm