473,404 Members | 2,137 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,404 software developers and data experts.

javascript include files

Hello:

Can a javascript file that is included with a webpage with SRC="filename.js"
be read and/or saved by a user?

I thought not, but now I wonder....

Thanks

John.
Jul 20 '05 #1
8 10594
"JohnS" <Pl**********@myaccount.com> writes:
Can a javascript file that is included with a webpage with SRC="filename.js"
be read and/or saved by a user?
Ofcourse.
There might not be a direct way to see it (like View Source), but if he
wants to see it, he can, due to all the usual reasons.
I thought not, but now I wonder....


Anything that is sent by a server can be inspected by a user.

/L
--
Lasse Reichstein Nielsen - lr*@hotpop.com
Art D'HTML: <URL:http://www.infimum.dk/HTML/randomArtSplit.html>
'Faith without judgement merely degrades the spirit divine.'
Jul 20 '05 #2
THanks for your reply! But I found an easy way to do the trick:

1. For links within the site add a "onClick='console=false'".
2. In the popup window function, before open window, check if the
'console' is true, and before the function set console as true.

Alex
--
==================================================
Cell Phone Batteries at 30-50%+ off retail prices!
http://www.pocellular.com
==================================================
"Lasse Reichstein Nielsen" <lr*@hotpop.com> :d6**********@hotpop.com...
"JohnS" <Pl**********@myaccount.com> writes:
Can a javascript file that is included with a webpage with SRC="filename.js" be read and/or saved by a user?


Ofcourse.
There might not be a direct way to see it (like View Source), but if he
wants to see it, he can, due to all the usual reasons.
I thought not, but now I wonder....


Anything that is sent by a server can be inspected by a user.

/L
--
Lasse Reichstein Nielsen - lr*@hotpop.com
Art D'HTML: <URL:http://www.infimum.dk/HTML/randomArtSplit.html>
'Faith without judgement merely degrades the spirit divine.'


Jul 20 '05 #3
JohnS wrote on 11 jul 2003 in comp.lang.javascript:
Can a javascript file that is included with a webpage with
SRC="filename.js" be read and/or saved by a user?

I thought not, but now I wonder....


just type the complete url in the IE addrressbar:

http://myorg.org/jslib/myjslib.js

--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
Jul 20 '05 #4
"Alex Shi" <ch****@eol.ca> writes:
THanks for your reply! But I found an easy way to do the trick:

1. For links within the site add a "onClick='console=false'".
2. In the popup window function, before open window, check if the
'console' is true, and before the function set console as true.


I am not sure exactly what you are suggesting to do, or what it is
supposed to have as effect.

Are you trying to prevent people from opening more than one window at
the time or something?

/L
--
Lasse Reichstein Nielsen - lr*@hotpop.com
Art D'HTML: <URL:http://www.infimum.dk/HTML/randomArtSplit.html>
'Faith without judgement merely degrades the spirit divine.'
Jul 20 '05 #5
No, actually that just renders a page with just <html></html>.

But, ...Bedankt (thanks in Dutch)

John.

"Evertjan." <ex**************@interxnl.net> wrote in message
news:Xn********************@194.109.133.29...
JohnS wrote on 11 jul 2003 in comp.lang.javascript:
Can a javascript file that is included with a webpage with
SRC="filename.js" be read and/or saved by a user?

I thought not, but now I wonder....


just type the complete url in the IE addrressbar:

http://myorg.org/jslib/myjslib.js

--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)

Jul 20 '05 #6
Ok, that makes sense. The question then becomes... how?

I have some code (partnumbers) in my javascript that I would like to be
"secret"

When I incude the js files,with only functions, I cannot see them with my
regurlar IE6 browser.

How could I see them? or again... could I?

Thanks,

John.

p.s
"Lasse Reichstein Nielsen" <lr*@hotpop.com> wrote in message
news:d6**********@hotpop.com...
"JohnS" <Pl**********@myaccount.com> writes:
Can a javascript file that is included with a webpage with SRC="filename.js" be read and/or saved by a user?


Ofcourse.
There might not be a direct way to see it (like View Source), but if he
wants to see it, he can, due to all the usual reasons.
I thought not, but now I wonder....


Anything that is sent by a server can be inspected by a user.

/L
--
Lasse Reichstein Nielsen - lr*@hotpop.com
Art D'HTML: <URL:http://www.infimum.dk/HTML/randomArtSplit.html>
'Faith without judgement merely degrades the spirit divine.'

Jul 20 '05 #7
JohnS wrote on 11 jul 2003 in comp.lang.javascript:
No, actually that just renders a page with just <html></html>.

But, ...Bedankt (thanks in Dutch)

John.

"Evertjan." <ex**************@interxnl.net> wrote in message
news:Xn********************@194.109.133.29...
JohnS wrote on 11 jul 2003 in comp.lang.javascript:
> Can a javascript file that is included with a webpage with
> SRC="filename.js" be read and/or saved by a user?
>
> I thought not, but now I wonder....
>


just type the complete url in the IE addrressbar:

http://myorg.org/jslib/myjslib.js

No, actually that just renders a page with just <html></html>.


Not here, the file opens in Notepad.
But perhaps this depands on your windows .js-file execution settings.

view-source:http://myorg.org/jslib/myjslib.js

however should always work.
--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
Jul 20 '05 #8
Correct!

Thanks,

John.
"Evertjan." <ex**************@interxnl.net> wrote in message
news:Xn********************@194.109.133.29...
JohnS wrote on 11 jul 2003 in comp.lang.javascript:
No, actually that just renders a page with just <html></html>.

But, ...Bedankt (thanks in Dutch)

John.

"Evertjan." <ex**************@interxnl.net> wrote in message
news:Xn********************@194.109.133.29...
JohnS wrote on 11 jul 2003 in comp.lang.javascript:

> Can a javascript file that is included with a webpage with
> SRC="filename.js" be read and/or saved by a user?
>
> I thought not, but now I wonder....
>

just type the complete url in the IE addrressbar:

http://myorg.org/jslib/myjslib.js

No, actually that just renders a page with just <html></html>.


Not here, the file opens in Notepad.
But perhaps this depands on your windows .js-file execution settings.

view-source:http://myorg.org/jslib/myjslib.js

however should always work.
--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)

Jul 20 '05 #9

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

25
by: Martin Walke | last post by:
Hi, This may seem like a client side problem but.... I have web pages that are made up of a number of javascript include files as well as 'in page' script. They all work fine running locally...
0
by: Martin Walke | last post by:
Hi guys, For those who responded before here's an update from hell!!! I think I confused people before when I said on the 'page load' and Chris suggested using the body onload. I was using the...
9
by: David D. | last post by:
Does the file extension matter when including a JavaScript file in an HTML page? Normally, one would include a JavaScript file in an HTML page using <script src="foo.JS" type="text/javascript">...
9
by: Trenqo 0 | last post by:
I'm looking for a way to include javascript files from within a ".js" file. This would allow me to only need to link to one ".js" file, and yet still organize my functions into non gargantuan files...
3
by: Justin | last post by:
I am using asp.net with a C# code behind and I need to figure out how to include a javascript file for use with my code. It was simple to do this in classic ASP: <!-- #include File="md5.js" --> ...
3
by: fbwhite | last post by:
I am having an issue (maybe two issues) in my application regarding a stylesheet not loading and I am getting Javascript Errors. If I clean out a client's temporary internet files and then browse...
7
by: McKirahan | last post by:
Has anyone experienced this (and found a solution)? I have five files: a .htm that invokes four .js include files. Only the first alert in the first include is displayed. This only happens...
2
by: Nathan Sokalski | last post by:
I am moving my website from my machine to my webhost, and need some help with what extra files I need to include due to the fact that I used AJAX in my site. Everything on the site is obviously...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.