Nicholas Posted September 6, 2009 Share Posted September 6, 2009 im wondering does anyone know how to stop people from going on say going on a game, and right clicking the mouse and clicking View Source, to get my coding? does anyone know how to make it so if you click on View Source it wont do nothing. it wont pop up a like notepad thing with the information crap? Quote Link to comment Share on other sites More sharing options...
jon182 Posted September 6, 2009 Share Posted September 6, 2009 Re: question... i dont think such a thing exists. and really its not absolutely necessary as it doesnt show php or anything. as far as im aware it only shows html code which doesnt really matter. Quote Link to comment Share on other sites More sharing options...
a_bertrand Posted September 6, 2009 Share Posted September 6, 2009 Re: question... actually you can steal HTML / CSS / Images and most annoying JS. But not PHP cannot be taken like that. You may however use tricks to make it more difficult to get like using JS to render the HTML or such however it will never be completely safe as the rendering NEED to be on the client side. Quote Link to comment Share on other sites More sharing options...
POG1 Posted September 6, 2009 Share Posted September 6, 2009 Re: question... A few tips. - Leave loads of white space at the top so when the person tries to view source it looks empty. - Make it hard for the thief, a 1 line website is tricky :-D - Use apache to show different images or to not allow the image directory to be viewed. Quote Link to comment Share on other sites More sharing options...
CrazyT Posted September 6, 2009 Share Posted September 6, 2009 Re: question... @POG1 Yeah lol I find it hard to read it all on 1 line on viewing source so i dont do that lol Quote Link to comment Share on other sites More sharing options...
POG1 Posted September 6, 2009 Share Posted September 6, 2009 Re: question... I code so that you can read the php source and keep it a 1 liner (sometimes 2). Look at this.. echo 'hello '. 'my '. 'name '. 'is '. 'mike '. 'ockshuge'; That example would produce.. 'hello my name is mike ockshuge Quote Link to comment Share on other sites More sharing options...
CrazyT Posted September 6, 2009 Share Posted September 6, 2009 Re: question... Yeah i know :P Quote Link to comment Share on other sites More sharing options...
Spudinski Posted September 6, 2009 Share Posted September 6, 2009 Re: question... I don't see the use of all this, if someone really wants to see what your HTML content looks like, they will eventually get it no matter how hard you try to obscure the results. I leave all my HTML content plain, like it is. There is really no use trying to hide the fact that it is, indeed, just markup or an image. Take for instance Myspace, they try so hard so that no-one can download the artists albums, but wiht no avail. Recently they tried to change the flash player, but the techies figured it out before, anything that is transmitted to the client, can be captured. Quote Link to comment Share on other sites More sharing options...
Dominion Posted September 6, 2009 Share Posted September 6, 2009 Re: question... i have one i was testing with but it does not really help much cos its so easy to view source with out right click put it after the php close tag not sure were i got it from but it was free off a site so enjoy <SCRIPT language=JavaScript> var msg='Your msg here'; function disableIE() { if (document.all) {alert(msg);return false;} } function disableNS(e) { if (document.layers||(document.getElementById&&!document.all)) { if (e.which==2||e.which==3) {alert(msg);return false;} Â } } if (document.layers) { document.captureEvents(Event.MOUSEDOWN);document.onmousedown=disableNS; } else { Â document.onmouseup=disableNS;document.oncontextmenu=disableIE; } document.oncontextmenu=new Function('alert(msg);return false') </SCRIPT> edit - first posted here http://criminalexistence.com/ceforums/i ... ic=27917.0 Quote Link to comment Share on other sites More sharing options...
POG1 Posted September 6, 2009 Share Posted September 6, 2009 Re: question... @dominion. Go on that page and press CTRL + U Quote Link to comment Share on other sites More sharing options...
Nicholas Posted September 6, 2009 Author Share Posted September 6, 2009 Re: question... hmm... well monocountry does it. unless it was just my pc at the time lol. Quote Link to comment Share on other sites More sharing options...
a_bertrand Posted September 7, 2009 Share Posted September 7, 2009 Re: question... You could use this: http://www.voormedia.com/en/tools/html- ... ambler.php Which basically produce a JS containing your HTML which is then somehow encoded. It makes it harder (but certainly not impossible) for the "html hackers" to read your code. However, honestly, I would not care much to hide my HTML. I don't think that what I did in HTML was sooo smart that it would need to be completely hided. Personally I find more annoying that my JS cannot be compiled in some sort as this took me a lot of time to create and as my game is heavy on JS, of course it's a good chunk of the game itself. The good side is that even if you take ALL my JS code, you would still miss the server side counter parts, and without them you do nothing. I believe that in your case it's the same for your HTML. Quote Link to comment Share on other sites More sharing options...
POG1 Posted September 7, 2009 Share Posted September 7, 2009 Re: question... That scrambler is useless, i got the source of a file in seconds. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.