js remote script eh ?
- Started
- Last post
- 5 Responses
- mikotondria3
hrm..so when I put these functions on a page:
function doStaff(){
document.getElementById('staff...
document.getElementById('contact...
}function doCty(){
alert('this did');
}they get called and work fine...
When I put them in a .js file and link it on the page, then it claims that doCty() isnt defined ??
What ??
- uan0
is it loaded yet when you call it?
- mikotondria30
well it should be yeh, cause doCty is only called onClick of a button..
- neferiu0
I have run into this before... i was behind schedule so I just said FUCK YOU and left it embedded in the page instead of figuring it out. lemme know if you figure it out.
- mikotondria30
ah, I generally brutalised my workflow, said fuck it, and included it in like the 'parent' document of a series of includes and templating set ups that I've got going..
Bizarrely, I just pulled up the .js in a browser and it DIDNT have the function there, almost as if it had be bastardly caching it and ignoring my ftping... I added the function to the js, ftpd as normal, refreshed in the browser and there it was...
Naturally it worked on the page, and I didnt get the error.
I hate it when code - entirely written by me, seems to conspire to fuck me up and rob me of a good chunk of a friday afternoon when I should have nailed this thing by lunchtime.
- SteveJobs0
it doesn't care for your careless semantic slang, and refuses to recognize them.
try naming them, engageStaffOrgy(), and paintTownRed() respectively.
- man, I seriously hope noone ever reads most of the code Ive done where I thought only I would ever read it.....mikotondria3