dhtml in .js??

They have: 164 posts

Joined: Nov 2001

can dhtml scripts save as .js??

i wanted to add my dhtml scripts in a file saved as .js, but it's not working..

Suzanne's picture

She has: 5,507 posts

Joined: Feb 2000

depends on the dhtml -- if it needs to be on the page to work, then no. (document.write stuff).

you can make a whole bunch of .js files, though, and that should work, placing them where needed.

dk01's picture

He has: 516 posts

Joined: Mar 2002

Well if the document.write is in a function then it should be ok.
As long as the function is called inside the page from another script tag and not from an event.
-dk

Want to join the discussion? Create an account or log in if you already have one. Joining is fast, free and painless! We’ll even whisk you back here when you’ve finished.