Mrunay Uttarwar
Mrunay Uttarwar

@MrunayU

14 تغريدة Jul 29, 2022
🔷 About HTML URL Encode
A Thread🧵 👇
📌 HTML URL
→ What is URL?
• URL stands for Uniform Resource Locator.
• A URL is another word for a web address.
• A URL can be composed of words (e.g. example.com) or an Internet Protocol (IP) address (e.g. 192.68.20.50).
• Web browsers request pages from web servers by using a URL.
• A Uniform Resource Locator (URL) is used to address a document (or other data) on the web.
📌 URL Syntax
→ Explanation-
• scheme - defines the type of Internet service (most common is http or https)
• prefix - defines a domain prefix (default for http is www)
• domain - defines the Internet domain name (like example.com)
• port - defines the port number at the host (default for http is 80)
• path - defines a path at the server (If omitted: the root directory of the site)
• filename - defines the name of a document or resource
📌 Different URL Schemes
→ The following table lists some different schemes used in URL with their uses.
• Scheme: http - HyperText Transfer Protocol
• Used for - Common web pages. Not encrypted.
• Scheme: https - Secure HyperText Transfer Protocol
• Used for - Secure web pages. Encrypted
• Scheme: ftp - File Transfer Protocol
• Used for - Downloading or uploading files
• Scheme: file
• Used for - A file on your computer
📌 URL Encoding
→ URLs can only be sent over the Internet using the ASCII character-set.
→ If a URL contains characters outside the ASCII set, the URL has to be converted.
→ URL encoding converts non-ASCII characters into a format that can be transmitted over the Internet.
→ URL encoding replaces non-ASCII characters with a "%" followed by hexadecimal digits.
→ URLs cannot contain spaces. URL encoding normally replaces a space with a plus (+) sign, or %20.
📌 URL Encoding Functions
→ In JavaScript, PHP, and ASP there are functions that can be used to URL encode a string.
→ PHP has the rawurlencode() function, and ASP has the Server.URLEncode() function.
→ In JavaScript you can use the encodeURIComponent() function.
Thanks for reading this thread ❤️
If you like it , make sure you:
🔷 Like the tweet
🔷 Retweet the first tweet ⚡
For more content , follow:
@MrunayU
You can read the unrolled version of this thread here: typefully.com

جاري تحميل الاقتراحات...