Ashley I have a project and use script to access localhost but, nothing happens in "Debug" mode, only in normal mode.
============= Edit ============
Preview Layout working script...
http://i66.tinypic.com/2yuktjn.jpg
Debug Layout not working script...
http://i65.tinypic.com/2584j1x.jpg