js server address
js server address
- Started
- Last post
- 5 Responses
- ldww
how do you get the server address into a variable in js? thanks.
- UndoUndo0
youll need to use ASp or PHP to return the value from the server to the JS
if var sIP="";
- ldww0
oh your kidding me. that blows.
I can not put php inside a .js file so i would have to pass it in. Yuk.
- UndoUndo0
yeah JS is client side. you can put php in a js file if you have access to htacess? let me know and ill show you
- heavyt0
are you sure that you dont just want the URL?
if so, use window.location in JS.