Improve company productivity with a Business Account.Sign Up

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 202
  • Last Modified:

java

i have some java script that i would like to hide from the public but i have no idea how. please could you give me some html code that could hide it or something so that visitors could not copy it please.
0
ZEON101
Asked:
ZEON101
1 Solution
 
ovidiucraciunCommented:
java question?
0
 
lilian_kellyCommented:
If you put your code in a .js file and then include the file then when you do a view source all that will be seen is the name of the js file. But thats does not stop them trying to download the js file.

Place this in the head of the js file.

<SCRIPT SRC="myjsfile.js></SCRIPT>

0
 
yatest5Commented:
If you place everything beween the <SCRIPT> and </SCRIPT> tags in a name.js file you can include it in your HTML by doing

<SCRIPT SRC=name.js></SCRIPT>

This will hide it from the casual browser.  Anything more secure that that is difficult.  You could try getting some obfuscation software which changes the names of things in your code to render it meaningless to the outside world.  I don't know where to find any unfortunately though.

Good luck,

Tom
0
 
yatest5Commented:
Oops, we posted that at the same time - touche Lilian.
0
 
ZEON101Author Commented:
thanx everyone
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now