Connecting Tech Pros Worldwide Forums | Help | Site Map

myscript.js

Johny
Guest
 
Posts: n/a
#1: Jul 23 '05
I have copied my right click script into a text file and the put the
following code in its place on the site

<script src="right-click.js"></script>

It works ok but won't work on the pages in folders unless I copy the text
file to that folder.

How can I get the the above line of code to look in one place for the text
file?

J



Evertjan.
Guest
 
Posts: n/a
#2: Jul 23 '05

re: myscript.js


Johny wrote on 09 apr 2005 in comp.lang.javascript:
[color=blue]
> I have copied my right click script into a text file and the put the
> following code in its place on the site
>
> <script src="right-click.js"></script>
>
> It works ok but won't work on the pages in folders unless I copy the
> text file to that folder.
>
> How can I get the the above line of code to look in one place for the
> text file?
>[/color]

Text files won't do, you will need a html files, where you put.

<script src="/myJsFiles/right-click.js"></script>


--
Evertjan.
The Netherlands.
(Replace all crosses with dots in my emailaddress)

Johny
Guest
 
Posts: n/a
#3: Jul 23 '05

re: myscript.js


As soon as i pressed send on the previous message I thought of a way to do
it,

<script src="../../right-click.js"></script>

Cheers
J


"Johny" <not_today_my_good_friend@TheNet.com> wrote in message
news:d3898n$olo$1@news6.svr.pol.co.uk...[color=blue]
> I have copied my right click script into a text file and the put the
> following code in its place on the site
>
> <script src="right-click.js"></script>
>
> It works ok but won't work on the pages in folders unless I copy the text
> file to that folder.
>
> How can I get the the above line of code to look in one place for the text
> file?
>
> J
>
>[/color]


Rebecca Seal
Guest
 
Posts: n/a
#4: Jul 23 '05

re: myscript.js


Or you can use the full URL.

"Johny" <not_today_my_good_friend@TheNet.com> wrote in message
news:d389k8$jlg$1@news7.svr.pol.co.uk...[color=blue]
> As soon as i pressed send on the previous message I thought of a way to do
> it,
>
> <script src="../../right-click.js"></script>
>
> Cheers
> J
>
>
> "Johny" <not_today_my_good_friend@TheNet.com> wrote in message
> news:d3898n$olo$1@news6.svr.pol.co.uk...[color=green]
>> I have copied my right click script into a text file and the put the
>> following code in its place on the site
>>
>> <script src="right-click.js"></script>
>>
>> It works ok but won't work on the pages in folders unless I copy the text
>> file to that folder.
>>
>> How can I get the the above line of code to look in one place for the
>> text
>> file?
>>
>> J
>>
>>[/color]
>
>[/color]


Closed Thread