blog-img

How To Decode HTML In Different Situation

person Posted:  Ainy Waya
calendar_month 26 Aug 2022
mode_comment 0 comments

The purpose of these scripts is to explain how to "hide" HTML and/or javascript from other people viewing the source code of your page. It's not foolproof, but it makes the source code harder to read and understand. Due to the nature of how these scripts work, the explanation may seem complex and lengthy, but be patient and it should make sense once you get a bit of experience with them. You don't actually need to know the details of these scripts, but it will help you understand how and why they work. So sit back and I'll do my best to make it look as uncomplicated as possible.

You wil learn Html decode process and its types of conversion.

The first part of this page explains how to "escape" any text, HTML or Javascript, to make it generally unreadable to the average user. URL Escape Codes are two-character hexadecimal (8-bit) values ​​preceded by a % character. This is mainly used in browser URLs or for use in creating cookies for characters that would otherwise not work, usually because they are reserved characters (like spaces and such).

 

For example, if you had an HTML file name of page one, the URL code would look like page%201. %20 is the default value for the space. Normally you would only escape special characters (generally any character other than a-z, A-Z and 0-9), but the script below actually escapes all text simply by replacing all characters with their equivalents. So if you were to completely escape the word first page, it would look like this: %70%61%67%65%20%6F%6E%65. Now, no text is easily decipherable, even though most of it was normal characters.

 

Since the browser can inherently handle escape codes, this can be used quite easily without adding an extra script to decrypt them.

The two text boxes below allow you to completely escape and unencode any text you want. Simply type any text/HTML/JavaScript you want into the left field and click the -- button to exit completely. Similarly, click the -- button to convert it back to normal text to verify that it is the same as the original. You can copy and paste the above code into your page (don't forget to use the unescape() and document.write() methods).

Encoding/decoding

By now you've probably figured out that you can hide an entire HTML page using the above method; but this has two disadvantages: Size and ease of "decoding" the code.

 

When you completely leave the entire page, every single character becomes 3 characters. This will triple the size of your page. It's not a big deal if the page is only about 10-50KB in size; but when you have a fairly large page (100KB), the file size will grow quickly. This would slow down loading times for surfers without broadband.

 

Also, if someone were to look at your source code, it would be pretty easy to figure out what you're doing. They can then simply copy and paste the code and create a small script to display the normal content. There's no absolutely foolproof (client-side) way to stop someone from tracking your feed if they're determined enough; the best you can hope for is to make it as uncomfortable as possible.

 

So to solve both problems you can encode/decode the text. Again, it won't be reliable to stop people from stealing your source content if they really want to. I'm really using the terms "encode" and "decode" loosely here; what the following script does is not considered real coding, but it's easier to say it that way. The encoded output will be slightly longer than the original text, but much less than if you simply escaped it all.

 

The above part just escapes from the text. The part below actually shifts the Unicode values ​​so the result looks like gibberish. Try it and see; be sure to try different code key values ​​from the dropdown list.


Setting Pannel

Style Setting
Theme

Menu Style

Active Menu Style

Color Customizer

Direction
settings
Share
Facebook
Twitter
Instagram
Google Plus
LinkedIn
YouTube