I am working on my website and am having trouble with the navigation bar. I am using Javascript to write innerHTML and if statements for finding what page I am on. Currently I am trying to figure out how to find out the document name so i could do something like:
but without the full pathname. So that it would beCode:function navigate() { var current = location.pathname; if (current == 'W:\public_html\index.htm') {Does anyone know how to get just the document name? Thanks in advance!Code:(current == 'index.htm')


Reply With Quote
Bookmarks