Posts for June 2011

IE8 CSS grouped selectors bug

Posted: 3:33pm 29th Jun 2011

Here's an annoying bug I ran into today, which curiously seems only to apply to IE8 and not IE7.

If you declare a selector block in a stylesheet with a pseudo-class that IE8 does not recognise, mixed with one that it does, IE8 won't recognise either of them. Here's an example

Running views during hook_cron which require admin privileges

Posted: 10:24am 27th Jun 2011

When needing to set up scheduled task in custom drupal modules, it is common to handle these with a hook_cron function. When this hook is triggered, it usually runs as the drupal anonymous user, but in some situations you want to run code during cron which requires certain higher level privileges.