I use seperate subdomains for images, css and javascript/jquery
css.domain.com
images.domain.com
js.domain.com
Altough this results in 4 DNS lookups, this is within the acceptible range of 2 - 4 (the lower this number the better). This results in more parallel downloads, helping your pages load quicker.
As I work on Linux, I place sensitive php scripts in a directory below the root when creating my own applications, and I know most turnkey applications such as Wordpress, osCommerce etc, don't have this setup, but hey, thats how I go.