Bitcoin Forum
May 05, 2024, 08:50:56 PM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: URLs with brackets are broken  (Read 880 times)
alani123 (OP)
Legendary
*
Offline Offline

Activity: 2394
Merit: 1412


Leading Crypto Sports Betting & Casino Platform


View Profile
May 16, 2016, 10:02:16 AM
 #1

I just noticed that if a URL contains brackets, it breaks linking.

You could use this one as an example:
https://www.whattomine.com/asic?utf8=%E2%9C%93&factor[sha256_hr]=1155.0&factor[sha256_p]=590.0&scryptf=true&factor[scrypt_hash_rate]=400.0&factor[scrypt_power]=1400.0&factor[cost]=0&sort=Profitability24&volume=0&revenue=24h&factor[exchanges][]=&factor[exchanges][]=bittrex&factor[exchanges][]=bleutrade&factor[exchanges][]=btc_e&factor[exchanges][]=bter&factor[exchanges][]=c_cex&factor[exchanges][]=cryptopia&factor[exchanges][]=poloniex&factor[exchanges][]=yobit&dataset=&commit=Calculate

..Stake.com..   ▄████████████████████████████████████▄
   ██ ▄▄▄▄▄▄▄▄▄▄            ▄▄▄▄▄▄▄▄▄▄ ██  ▄████▄
   ██ ▀▀▀▀▀▀▀▀▀▀ ██████████ ▀▀▀▀▀▀▀▀▀▀ ██  ██████
   ██ ██████████ ██      ██ ██████████ ██   ▀██▀
   ██ ██      ██ ██████  ██ ██      ██ ██    ██
   ██ ██████  ██ █████  ███ ██████  ██ ████▄ ██
   ██ █████  ███ ████  ████ █████  ███ ████████
   ██ ████  ████ ██████████ ████  ████ ████▀
   ██ ██████████ ▄▄▄▄▄▄▄▄▄▄ ██████████ ██
   ██            ▀▀▀▀▀▀▀▀▀▀            ██ 
   ▀█████████▀ ▄████████████▄ ▀█████████▀
  ▄▄▄▄▄▄▄▄▄▄▄▄███  ██  ██  ███▄▄▄▄▄▄▄▄▄▄▄▄
 ██████████████████████████████████████████
▄▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▄
█  ▄▀▄             █▀▀█▀▄▄
█  █▀█             █  ▐  ▐▌
█       ▄██▄       █  ▌  █
█     ▄██████▄     █  ▌ ▐▌
█    ██████████    █ ▐  █
█   ▐██████████▌   █ ▐ ▐▌
█    ▀▀██████▀▀    █ ▌ █
█     ▄▄▄██▄▄▄     █ ▌▐▌
█                  █▐ █
█                  █▐▐▌
█                  █▐█
▀▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▀█
▄▄█████████▄▄
▄██▀▀▀▀█████▀▀▀▀██▄
▄█▀       ▐█▌       ▀█▄
██         ▐█▌         ██
████▄     ▄█████▄     ▄████
████████▄███████████▄████████
███▀    █████████████    ▀███
██       ███████████       ██
▀█▄       █████████       ▄█▀
▀█▄    ▄██▀▀▀▀▀▀▀██▄  ▄▄▄█▀
▀███████         ███████▀
▀█████▄       ▄█████▀
▀▀▀███▄▄▄███▀▀▀
..PLAY NOW..
1714942256
Hero Member
*
Offline Offline

Posts: 1714942256

View Profile Personal Message (Offline)

Ignore
1714942256
Reply with quote  #2

1714942256
Report to moderator
1714942256
Hero Member
*
Offline Offline

Posts: 1714942256

View Profile Personal Message (Offline)

Ignore
1714942256
Reply with quote  #2

1714942256
Report to moderator
1714942256
Hero Member
*
Offline Offline

Posts: 1714942256

View Profile Personal Message (Offline)

Ignore
1714942256
Reply with quote  #2

1714942256
Report to moderator
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
ibminer
Legendary
*
Offline Offline

Activity: 1819
Merit: 2792


Goonies never say die.


View Profile WWW
May 16, 2016, 01:19:48 PM
Last edit: May 17, 2016, 10:19:47 PM by ibminer
 #2

I just noticed that if a URL contains brackets, it breaks linking.

You could use this one as an example:
https://www.whattomine.com/asic?utf8=%E2%9C%93&factor[sha256_hr]=1155.0&factor[sha256_p]=590.0&scryptf=true&factor[scrypt_hash_rate]=400.0&factor[scrypt_power]=1400.0&factor[cost]=0&sort=Profitability24&volume=0&revenue=24h&factor[exchanges][]=&factor[exchanges][]=bittrex&factor[exchanges][]=bleutrade&factor[exchanges][]=btc_e&factor[exchanges][]=bter&factor[exchanges][]=c_cex&factor[exchanges][]=cryptopia&factor[exchanges][]=poloniex&factor[exchanges][]=yobit&dataset=&commit=Calculate

Easiest solution on your end would be:

Left square bracket: [ %5B
Right square bracket: ] %5D

new url:

https://www.whattomine.com/asic?utf8=%E2%9C%93&factor[sha256_hr]=1155.0&factor[sha256_p]=590.0&scryptf=true&factor[scrypt_hash_rate]=400.0&factor[scrypt_power]=1400.0&factor[cost]=0&sort=Profitability24&volume=0&revenue=24h&factor[exchanges][]=&factor[exchanges][]=bittrex&factor[exchanges][]=bleutrade&factor[exchanges][]=btc_e&factor[exchanges][]=bter&factor[exchanges][]=c_cex&factor[exchanges][]=cryptopia&factor[exchanges][]=poloniex&factor[exchanges][]=yobit&dataset=&commit=Calculate

Code:
https://www.whattomine.com/asic?utf8=%25E2%259C%2593&factor%5Bsha256_hr%5D=1155.0&factor%5Bsha256_p%5D=590.0&scryptf=true&factor%5Bscrypt_hash_rate%5D=400.0&factor%5Bscrypt_power%5D=1400.0&factor%5Bcost%5D=0&sort=Profitability24&volume=0&revenue=24h&factor%5Bexchanges%5D%5B%5D=&factor%5Bexchanges%5D%5B%5D=bittrex&factor%5Bexchanges%5D%5B%5D=bleutrade&factor%5Bexchanges%5D%5B%5D=btc_e&factor%5Bexchanges%5D%5B%5D=bter&factor%5Bexchanges%5D%5B%5D=c_cex&factor%5Bexchanges%5D%5B%5D=cryptopia&factor%5Bexchanges%5D%5B%5D=poloniex&factor%5Bexchanges%5D%5B%5D=yobit&dataset=&commit=Calculate


EDIT: grue's way is better! I'm an idiot for putting the crossed-out url above. I usually don't lookup the values and should have just used the urlencode() function to get the url but it seemed easier to lookup the values at the time, and I ended up on a site giving special characters. MY BAD!  Grin

longbob72
Hero Member
*****
Offline Offline

Activity: 574
Merit: 503


V2h5IGFyZSB5b3UgcmVhZGluZyB0aGlzPw==


View Profile
May 16, 2016, 02:30:08 PM
 #3

In some forums using quotes within the url tag (e.g. [ur.l="bitcointalk.org"]) will make it appear correctly even if the url have square brackets  Maybe theymos can do that.


using link shorterners (with no ad) would be easier.

                                                                       
    ▄▄███████▄▄                           ▄      ▄
   ██████████████▄                       ███    ███
  ███▀ ▄▄▄▄▄▄▄ ▀████                     ███    ███
  █████████████▄ ▀███                    ███    ███   █▄ ▄▄
   ▀████▄  ▄▄███  ▀███                   ███    ███  ▄████
   ▄███████████   ▄███                  ███    ███  ▀▀███▀▀
   ███           ▄███         ▄▄▄▄      ███    ███     █    ▄▄  ▄▄▄▄
  ▄███     ▄▄▄▄█████        ▄█████▄    ▄██▀   ▄██▀    ███   █████████
  ███▄    ████████         ▄███▀▀███   ███    ███    ███▀   █████▀████
   ███     ▀▀█████▄      ▄█████▄ ███   ███    ███    ███    ████   ███
   ███         ▀███▄     ███▀███ ███  ███▀   ███▀    ███    ███▀   ███
   ███           ███▄    ███  ▀▀ ███  ███    ███    ███▀   ▄███    ███
   ▀██▄           ███    ███▄  ▄███   ███    ███    ███    ███    ███▀
    ███           ▀███▄   ████████    ███    ███    ███    ███    ███
    ▀██            ▀████   ▀████▀      ██     ██    ▀██    ▀█▀    ▀█▀


.
.
.
        ▄▄▀                ▀▄▄
     ▄ ▀▀                    ▀▀ ▄
   ▄ ▀▀▀                      ▀▀▀ ▄
  ▄▀▀▀                          ▀▀▀▄
 ▀█▄▄                            ▄▄█▀
▄█  ▄                            ▄  █▄
▀█ █▀                            ▀█ █▀
█▄  ▄                            ▄  ▄█
▀█ █                              █ █▀
█▄   █                          █   ▄█
 ██▄█▀                          ▀█▄██
  ▀▀  ▄█                      █▄  ▀▀
  ▀██▄ ▀  █▄              ▄█  ▀ ▄██▀
    ▀▀▀   ██  █▄      ▄█  ██   ▀▀▀
     ▀███▄▄▀  ███    ███  ▀▄▄███▀
        ▀▀▀▀▄▄▄▄▀    ▀▄▄▄▄▀▀▀▀
          ▀▀█████▀▀▀▀█████▀▀
.
.
Free Bitcoins
Chat Lottery & Games
Level Up System with Rewards
▄████████▄  ▄████████▄
██      ██  ██      ██
██      ██  ██      ██
██      ██  ██      ██
██      ██  ██      ██
 ████████    ████████
██      ██  ██      ██
██      ██  ██      ██
██      ██  ██      ██
██      ██  ██      ██
▀████████▀  ▀████████▀
.
grue
Legendary
*
Offline Offline

Activity: 2058
Merit: 1431



View Profile
May 17, 2016, 01:30:34 PM
 #4

The proper way is to url encode it. Your url would encode to:
Code:
https://www.whattomine.com/asic?utf8=%25E2%259C%2593&factor%5Bsha256_hr%5D=1155.0&factor%5Bsha256_p%5D=590.0&scryptf=true&factor%5Bscrypt_hash_rate%5D=400.0&factor%5Bscrypt_power%5D=1400.0&factor%5Bcost%5D=0&sort=Profitability24&volume=0&revenue=24h&factor%5Bexchanges%5D%5B%5D=&factor%5Bexchanges%5D%5B%5D=bittrex&factor%5Bexchanges%5D%5B%5D=bleutrade&factor%5Bexchanges%5D%5B%5D=btc_e&factor%5Bexchanges%5D%5B%5D=bter&factor%5Bexchanges%5D%5B%5D=c_cex&factor%5Bexchanges%5D%5B%5D=cryptopia&factor%5Bexchanges%5D%5B%5D=poloniex&factor%5Bexchanges%5D%5B%5D=yobit&dataset=&commit=Calculate

You can do it within your browser's developer console by using
Code:
encodeURI("your url here")

It is pitch black. You are likely to be eaten by a grue.

Adblock for annoying signature ads | Enhanced Merit UI
deepceleron
Legendary
*
Offline Offline

Activity: 1512
Merit: 1028



View Profile WWW
May 17, 2016, 05:18:49 PM
 #5

If a URL contains brackets, then the webmaster is a dummy.

Unsafe:

   Characters can be unsafe for a number of reasons.  The space
   character is unsafe because significant spaces may disappear and
   insignificant spaces may be introduced when URLs are transcribed or
   typeset or subjected to the treatment of word-processing programs.
   The characters "<" and ">" are unsafe because they are used as the
   delimiters around URLs in free text; the quote mark (""") is used to
   delimit URLs in some systems.  The character "#" is unsafe and should
   always be encoded because it is used in World Wide Web and in other
   systems to delimit a URL from a fragment/anchor identifier that might
   follow it.  The character "%" is unsafe because it is used for
   encodings of other characters.  Other characters are unsafe because
   gateways and other transport agents are known to sometimes modify
   such characters. These characters are "{", "}", "|", "\", "^", "~",
   "[", "]", and "`".

   All unsafe characters must always be encoded within a URL. For
   example, the character "#" must be encoded within URLs even in
   systems that do not normally deal with fragment or anchor
   identifiers, so that if the URL is copied into another system that
   does use them, it will not be necessary to change the URL encoding.
alani123 (OP)
Legendary
*
Offline Offline

Activity: 2394
Merit: 1412


Leading Crypto Sports Betting & Casino Platform


View Profile
May 17, 2016, 06:20:21 PM
 #6

If a URL contains brackets, then the webmaster is a dummy.

Unsafe:

   Characters can be unsafe for a number of reasons.  The space
   character is unsafe because significant spaces may disappear and
   insignificant spaces may be introduced when URLs are transcribed or
   typeset or subjected to the treatment of word-processing programs.
   The characters "<" and ">" are unsafe because they are used as the
   delimiters around URLs in free text; the quote mark (""") is used to
   delimit URLs in some systems.  The character "#" is unsafe and should
   always be encoded because it is used in World Wide Web and in other
   systems to delimit a URL from a fragment/anchor identifier that might
   follow it.  The character "%" is unsafe because it is used for
   encodings of other characters.  Other characters are unsafe because
   gateways and other transport agents are known to sometimes modify
   such characters. These characters are "{", "}", "|", "\", "^", "~",
   "[", "]", and "`".

   All unsafe characters must always be encoded within a URL. For
   example, the character "#" must be encoded within URLs even in
   systems that do not normally deal with fragment or anchor
   identifiers, so that if the URL is copied into another system that
   does use them, it will not be necessary to change the URL encoding.
I certainly wouldn't go contacting every webmaster doing this telling them that it's a bad practice. Brackets in URLs aren't that common but it'd be better for the forum to fix this, not allowing URLs to be broken so easily. Not that it's an urgently needed fix, but more of an aesthetic/time saving feature. 

..Stake.com..   ▄████████████████████████████████████▄
   ██ ▄▄▄▄▄▄▄▄▄▄            ▄▄▄▄▄▄▄▄▄▄ ██  ▄████▄
   ██ ▀▀▀▀▀▀▀▀▀▀ ██████████ ▀▀▀▀▀▀▀▀▀▀ ██  ██████
   ██ ██████████ ██      ██ ██████████ ██   ▀██▀
   ██ ██      ██ ██████  ██ ██      ██ ██    ██
   ██ ██████  ██ █████  ███ ██████  ██ ████▄ ██
   ██ █████  ███ ████  ████ █████  ███ ████████
   ██ ████  ████ ██████████ ████  ████ ████▀
   ██ ██████████ ▄▄▄▄▄▄▄▄▄▄ ██████████ ██
   ██            ▀▀▀▀▀▀▀▀▀▀            ██ 
   ▀█████████▀ ▄████████████▄ ▀█████████▀
  ▄▄▄▄▄▄▄▄▄▄▄▄███  ██  ██  ███▄▄▄▄▄▄▄▄▄▄▄▄
 ██████████████████████████████████████████
▄▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▄
█  ▄▀▄             █▀▀█▀▄▄
█  █▀█             █  ▐  ▐▌
█       ▄██▄       █  ▌  █
█     ▄██████▄     █  ▌ ▐▌
█    ██████████    █ ▐  █
█   ▐██████████▌   █ ▐ ▐▌
█    ▀▀██████▀▀    █ ▌ █
█     ▄▄▄██▄▄▄     █ ▌▐▌
█                  █▐ █
█                  █▐▐▌
█                  █▐█
▀▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▀█
▄▄█████████▄▄
▄██▀▀▀▀█████▀▀▀▀██▄
▄█▀       ▐█▌       ▀█▄
██         ▐█▌         ██
████▄     ▄█████▄     ▄████
████████▄███████████▄████████
███▀    █████████████    ▀███
██       ███████████       ██
▀█▄       █████████       ▄█▀
▀█▄    ▄██▀▀▀▀▀▀▀██▄  ▄▄▄█▀
▀███████         ███████▀
▀█████▄       ▄█████▀
▀▀▀███▄▄▄███▀▀▀
..PLAY NOW..
Gleb Gamow
In memoriam
VIP
Legendary
*
Offline Offline

Activity: 1428
Merit: 1145



View Profile
May 17, 2016, 09:18:01 PM
 #7

I just noticed that if a URL contains brackets, it breaks linking.

You could use this one as an example:
https://www.whattomine.com/asic?utf8=%E2%9C%93&factor[sha256_hr]=1155.0&factor[sha256_p]=590.0&scryptf=true&factor[scrypt_hash_rate]=400.0&factor[scrypt_power]=1400.0&factor[cost]=0&sort=Profitability24&volume=0&revenue=24h&factor[exchanges][]=&factor[exchanges][]=bittrex&factor[exchanges][]=bleutrade&factor[exchanges][]=btc_e&factor[exchanges][]=bter&factor[exchanges][]=c_cex&factor[exchanges][]=cryptopia&factor[exchanges][]=poloniex&factor[exchanges][]=yobit&dataset=&commit=Calculate

Easiest solution on your end would be:

Left square bracket: &#91;
Right square bracket: &#93;

new url:

Code:
https://www.whattomine.com/asic?utf8=%E2%9C%93&factor&#91;sha256_hr&#93;=1155.0&factor&#91;sha256_p&#93;=590.0&scryptf=true&factor&#91;scrypt_hash_rate&#93;=400.0&factor&#91;scrypt_power&#93;=1400.0&factor&#91;cost&#93;=0&sort=Profitability24&volume=0&revenue=24h&factor&#91;exchanges&#93;&#91;&#93;=&factor&#91;exchanges&#93;&#91;&#93;=bittrex&factor&#91;exchanges&#93;&#91;&#93;=bleutrade&factor&#91;exchanges&#93;&#91;&#93;=btc_e&factor&#91;exchanges&#93;&#91;&#93;=bter&factor&#91;exchanges&#93;&#91;&#93;=c_cex&factor&#91;exchanges&#93;&#91;&#93;=cryptopia&factor&#91;exchanges&#93;&#91;&#93;=poloniex&factor&#91;exchanges&#93;&#91;&#93;=yobit&dataset=&commit=Calculate


EDIT: grue's way is better! I thought I was giving you the corresponding html entities but I wasn't, bad google search and not enough thought, the URL will still work but encoding the url is what should be done.



=1155.0&factor[sha256_p]=590.0&scryptf=true&factor[scrypt_hash_rate]=400.0&factor[scrypt_power]=1400.0&factor[cost]=0&sort=Profitability24&volume=0&revenue=24h&factor[exchanges][]=&factor[exchanges][]=bittrex&factor[exchanges][]=bleutrade&factor[exchanges][]=btc_e&factor[exchanges][]=bter&factor[exchanges][]=c_cex&factor[exchanges][]=cryptopia&factor[exchanges][]=poloniex&factor[exchanges][]=yobit&dataset=&commit=Calculate]https://www.whattomine.com/asic?utf8=%E2%9C%93&factor[sha256_hr]=1155.0&factor[sha256_p]=590.0&scryptf=true&factor[scrypt_hash_rate]=400.0&factor[scrypt_power]=1400.0&factor[cost]=0&sort=Profitability24&volume=0&revenue=24h&factor[exchanges][]=&factor[exchanges][]=bittrex&factor[exchanges][]=bleutrade&factor[exchanges][]=btc_e&factor[exchanges][]=bter&factor[exchanges][]=c_cex&factor[exchanges][]=cryptopia&factor[exchanges][]=poloniex&factor[exchanges][]=yobit&dataset=&commit=Calculate
ibminer
Legendary
*
Offline Offline

Activity: 1819
Merit: 2792


Goonies never say die.


View Profile WWW
May 17, 2016, 09:58:44 PM
 #8

I just noticed that if a URL contains brackets, it breaks linking.

You could use this one as an example:
https://www.whattomine.com/asic?utf8=%E2%9C%93&factor[sha256_hr]=1155.0&factor[sha256_p]=590.0&scryptf=true&factor[scrypt_hash_rate]=400.0&factor[scrypt_power]=1400.0&factor[cost]=0&sort=Profitability24&volume=0&revenue=24h&factor[exchanges][]=&factor[exchanges][]=bittrex&factor[exchanges][]=bleutrade&factor[exchanges][]=btc_e&factor[exchanges][]=bter&factor[exchanges][]=c_cex&factor[exchanges][]=cryptopia&factor[exchanges][]=poloniex&factor[exchanges][]=yobit&dataset=&commit=Calculate

Easiest solution on your end would be:

Left square bracket: &#91;
Right square bracket: &#93;

new url:

Code:
https://www.whattomine.com/asic?utf8=%E2%9C%93&factor&#91;sha256_hr&#93;=1155.0&factor&#91;sha256_p&#93;=590.0&scryptf=true&factor&#91;scrypt_hash_rate&#93;=400.0&factor&#91;scrypt_power&#93;=1400.0&factor&#91;cost&#93;=0&sort=Profitability24&volume=0&revenue=24h&factor&#91;exchanges&#93;&#91;&#93;=&factor&#91;exchanges&#93;&#91;&#93;=bittrex&factor&#91;exchanges&#93;&#91;&#93;=bleutrade&factor&#91;exchanges&#93;&#91;&#93;=btc_e&factor&#91;exchanges&#93;&#91;&#93;=bter&factor&#91;exchanges&#93;&#91;&#93;=c_cex&factor&#91;exchanges&#93;&#91;&#93;=cryptopia&factor&#91;exchanges&#93;&#91;&#93;=poloniex&factor&#91;exchanges&#93;&#91;&#93;=yobit&dataset=&commit=Calculate


EDIT: grue's way is better! I thought I was giving you the corresponding html entities but I wasn't, bad google search and not enough thought, the URL will still work but encoding the url is what should be done.



=1155.0&factor[sha256_p]=590.0&scryptf=true&factor[scrypt_hash_rate]=400.0&factor[scrypt_power]=1400.0&factor[cost]=0&sort=Profitability24&volume=0&revenue=24h&factor[exchanges][]=&factor[exchanges][]=bittrex&factor[exchanges][]=bleutrade&factor[exchanges][]=btc_e&factor[exchanges][]=bter&factor[exchanges][]=c_cex&factor[exchanges][]=cryptopia&factor[exchanges][]=poloniex&factor[exchanges][]=yobit&dataset=&commit=Calculate]https://www.whattomine.com/asic?utf8=%E2%9C%93&factor[sha256_hr]=1155.0&factor[sha256_p]=590.0&scryptf=true&factor[scrypt_hash_rate]=400.0&factor[scrypt_power]=1400.0&factor[cost]=0&sort=Profitability24&volume=0&revenue=24h&factor[exchanges][]=&factor[exchanges][]=bittrex&factor[exchanges][]=bleutrade&factor[exchanges][]=btc_e&factor[exchanges][]=bter&factor[exchanges][]=c_cex&factor[exchanges][]=cryptopia&factor[exchanges][]=poloniex&factor[exchanges][]=yobit&dataset=&commit=Calculate

I'm not sure which part of the post the meme is intended but I think I've cleared up my post now Tongue   If your questioning why the URL you posted doesn't work, hover the mouse over the link and look in the status bar, it will not be the full URL, and the values will not be accurate on the site.

Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!