Jump to content
xisto Community
Sign in to follow this  
-Sky-

Stop Your Html Codes From Being Stolen Stop your Html codes from being stolen on your HTML pages.

Recommended Posts

Hello people! Obviously a lot of people use these little scripts to stop you from right clicking on websites/HTML pages etc. I know many many people use near enough the same kind of coding as the one I just made. I decided not to put this in the Tutorials section because I know alot of other codes do exactly the same thing as this one I am going to be sharing with you!

 

This code may be re-distributed if you wish. I have no copyright on it, but please put some kind of "Thanks for the no right-click script".

 

Here it is:

 

oncontextmenu="return false" onselectstart="return true" ondragstart="return false">

This code must be placed below </head> and at <body>.

 

So It's:

<body oncontextmenu="return false" onselectstart="return false" ondragstart="return false">

I am also going to add my News bar script here, for EVERYONE to use. I have decided It's not very good for me to only allow the use of it for just Xisto and my site.

 

Script Name: News Link

Description of Script: This "News Link" script puts a header in the top middle of the board under "<% BOARD HEADER %>" and above "<% MEMBER BAR %>".

Screenshots: http://forums.xisto.com/topic/61172-req-suggest-news-link-suggestion-and-request/

IPB: 1.3x and 2.0x.

Script code:

<br><script type="text/javascript" src="jscripts/ipb_forum.js"></script><table cellspacing="0" class="newslink">	<tr>		<td><td align="center"><b><font color="-[HEX color code here]-">Central-Gaming latest news: <a href="http://central-gaming.trap17.com/forums/index.php?showtopic=14&view=getnewpost">Changes</a></b></p><br/></td>		<td align="right" valign="middle">				</td>	</tr></table><br>

 

Change "Central-Gaming latest news:" text to your desired name, and change the link

 

to the news forum:
Attention Notice: If you wish to use this news bar script PLEASE Thank me by putting something like "A big Thanks to -Sky- for the News Bar Script" HTML code:
<p><a href=""http://forums.xisto.com/user/67096-sky/;
.

 

This script/modification will work only for Invision Power Board (IPB) 1.3x. This means also it will work on IP.Boards 2.0x.

 

Thank you

Share this post


Link to post
Share on other sites

ctrl-u
(a fancy way - bookmark this (unless you're in IE)) java script:window.location="view-source:"+document.URL

What's that all about? Did I forget to add something else to the description?

Anyways, I hope you all enjoy. :lol:

-Sky

Share this post


Link to post
Share on other sites

Trying to prevent people from "stealing" your HTML is unnecessary and a waste of effort. Even if you disable their right-click, there are still ways of getting passed that. Then there is their cache, where they can right click (:lol:) and pick "Open with...". But there's really no point in trying to "steal" HTML from others. Also, any HTML specialist can not only figure out how the site is structured and coded, but also won't have any need for "your" HTML. Even if you prevent your pages from being cached, there's still ways around that. But that'll just increase your bandwidth consumption.

Share this post


Link to post
Share on other sites

True. Eh, well theres my news script you can all still enjoy. :D All though I could search for ways to disable the cache from being viewed etc. It may not work but still...at least it stops script noobs from ripping my stuff. I hate it when people steel my signatures/avatars and use them for themselves like RedAlert did, with both my avatar and my signature banner. :lol:Thanks anyway Fusion. ^_^

Share this post


Link to post
Share on other sites

Not only meaningless - impossible. If you want the page to be displayed properly, all the information (e.g. HTML/CSS, images) must be sent to the visitor's browser, and therefore the visitor's computer. You can try any script to prevent "theft" but it always comes to the fact that everything is given to the user the moment he opens a page of your web site.

Share this post


Link to post
Share on other sites

As has been said its really impossible to do such things. A classic way is to prevent right clicking, but in most cases disabling javascript will thwart most scripts as most rely on JS. also clicking left and right button together fools the system. In general the script looks for the numbers corresponding to a mouse click, something like "1" is left, "2" is right, so if the mouseclick == 2 it was a right click so block it. but if i click both buttons and generate a 3 then the script is useless :P also View>source There are i think programs that claim to hide your HTML by somehow encrypting it but telling the browser how to display it or something. I dont know if they actually exist/work but im sure ive seen them advertised for high prices.But as Pyost said, for a browser to render a page it needs unrestricted access to the HTML code. and to display the code to the browser is to display it to the user!Of course you could always make your websute using flash or something and then the source is hidden, though thre are ways to get fragments back :)

Share this post


Link to post
Share on other sites

There are i think programs that claim to hide your HTML by somehow encrypting it but telling the browser how to display it or something. I dont know if they actually exist/work but im sure ive seen them advertised for high prices.

I saw one of those being sold for 30 dollars. As it turns out, it put all the HTML on one line. Thirty dollars, for that. And that's why I don't trust the Internet.

Share this post


Link to post
Share on other sites

Disabling right click is one of the most annoying things you can do if you own a website. It is especially annoying when a message comes up saying "No right click allowed" or something like that, it just makes me more tempted to steal the source code. But then again the kind of people who put this on their website can't design websites for anything, so there really isn't even the point of wasting the energy moving my mouse up to the "View" menu. As pyost said, the data needs to be sent to the browser so even if you were able to tell most standard browsers to disable the "view source" menu item, it would be fairly easy just to download the the source of the website via other means. If you put this content up in a place where people can access it, then just know that it can be stolen. There's no use fighting it. If you are able to design a website that is good enough that others may want to steal it, then you should feel proud of your web design abilities.Now on to the uses of this script. *Everybody gasps*. Yes, returning false on right click actually can be implemented very well if you know what you are doing. Google is one such example, where they replace your right click menu with their menu in Google Docs when you right click in the input area, allowing them to insert their own items. They are clearly not attempting to thwart others from accessing their source, they are trying to make their website more user friendly, and more advanced.

Edited by galexcd (see edit history)

Share this post


Link to post
Share on other sites

Usually you can find some free encryption software to stop codes being stolen. Although , the only codes I'd be worried about being stolen are CCS or Javascript , as HTML code does not usually give away much code to your website , so encrypting the CSS file / Javascript file is the only real thing to do about it , other than disabling right click enforcing major copyright , both of which show aggresion and are extremely ennoying >_<

Share this post


Link to post
Share on other sites

"Stopping" someone to "steal"? :) your codes is utterly stupid and not necessarry. If you were smart to design a beatiful website (according to you)* then you should be proud?of people stealing your code because it proves how 1337 your coding sk11lz are! :P

 

* I say according to you because a website isn't good if it blocks you from using JavaScript in any means. (For example those lame piczo pages which say: "You should contact the site owner if you like pictures!" and is stupid because the pics could be stolen by any means, for example:

 

Disabling JavaScript. Easy as pie in Opera: F12 -> Enable JavaScript (should be unticked)

Looking into the source of the website: Ctrl-U

Taking a screenshot of the area you want and the crop it, etc. etc.

As almost everyone before me said in here, you can't hide the source, you can just obscure it, but it can be look at 100% of the source if you are patient and little skilled :P

Share this post


Link to post
Share on other sites

There are a couple of ways of stopping people getting your code,1. use PHP to generate a PDF version2. Use scripting to generate an image version of the site, before it is sent to the browser, thus only an IMG tag is needed.Both are impractical, and would waste bandwidth, also, wouldn't work for people without the right software to view, or with images disabled, or with screen readers etc.another way, is a flash site, perfectly practical, but not everyone can use them because they don't have flash player etc.There is no way of stopping people seeing HTML code, for an HTML site, as the browser needs the code to be able to interpret it.Even if you make it so the page cannot be cached, right clicked, downloaded or anything, people would just write browsers which saved the source when it downloaded, like youtube - they tried to stop people downloading, it doesn't work, there not protected so that people can see them, so people can download them when their browser does or with other methods.Stealing people code isn't legal, but people still do it. unfortunately, n one can stop it.accept, that if its on the web, people can use it.A good thing to do, is to put comment tags in, just saying your name, and "please do not remover this comment"of course, some people will, but as its not seen by anyone who doesn't view the source, some people may well leave it in place, that way, if the source is taken, people at least knew who made it and you get some credit.

Share this post


Link to post
Share on other sites

There are a couple of ways of stopping people getting your code,1. use PHP to generate a PDF version
2. Use scripting to generate an image version of the site, before it is sent to the browser, thus only an IMG tag is needed.
Both are impractical, and would waste bandwidth, also, wouldn't work for people without the right software to view, or with images disabled, or with screen readers etc.

another way, is a flash site, perfectly practical, but not everyone can use them because they don't have flash player etc.


Let's not forget search engines! Search bots crawling the web cannot see what is on a certain picture, nor can they read the contents of a flash file. That is why pure textual code is the best solution, even with the risk of it being stolen.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×
×
  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.