Ok, I have been looking for this for too long ... I am trying to figure out how I can return the file name on a page that runs javascript included, from within this javascript.
I can easily do this in PHP with $_SERVER['SCRIPT_FILENAME'], but in Javascript it looks a lot more complicated.
Do I need to tune it out location.hrefor is there a more efficient way? Can jQuery help?
source
share