Click to See Complete Forum and Search --> : javascript function access question


txp200
April 27th, 2004, 12:21 AM
i have a site that uses multiple frames and html files for centering. is there a way to write a javascript function so that when a link is click it will open a page and then access a fuction on another page that changes 2 frames at once? i have a function written already but it only works when im on the page that the javascript is written in.

im not very familiar with javascript and i have searched around a lot not able to find a specific answer to my question. any help is appreciated. thanks.

man_with_hat
April 29th, 2004, 08:35 AM
Hi
if i get you then
why dont you place your function in a 'js file' and use a link in each page to that js file holding the function
thus
<SCRIPT language="JavaScript" src="jsfile.js" type="text/javascript"></SCRIPT>

you can create a js file using textpad
name it with a .js extension and place it in a sutible folder you can access from your html pages

hope this helps