Metal Storm logo
Parsing of links in the shoutbox



‹‹ Back to Bugs
Posts: 9   Visited by: 67 users
28.05.2010 - 13:51
corrupt
With a lowercase c
Simple one. A link like http://www.setlist.fm/search?query=primal+fear is only parsed until the + sign. It will result in

[link] fear

instead of

[link]

I guess it's a regex thing somewhere.
----
Loading...
31.05.2010 - 20:05
Ivan
Retired Admin
Fixed. The problem was with passing the input through URL (AJAX) and "+" being decoded as space.
Loading...
17.04.2011 - 23:31
Ragana
Rawrcat
Okay, so the problem still exists - this link (http://webcache.googleusercontent.com/search?q=cache:N8M-C8x1SegJ:www.esn.lv/content/cafes-pubs-clubs-riga+metal+bars+riga&cd=2&hl=en&ct=clnk&source=www.google.com) also didn't look that good in the shoutbox (it appeared as: [link] bar in riga&cd=7&hl=en&ct=clnk& source=www.google.com ).


// I edited this post & added the correct address.
Loading...
17.04.2011 - 23:42
corrupt
With a lowercase c
Actually, Ragana seems to have discovered two bugs there:

In http://citycatalogue.com/latvia/riga/bars,-pubs/6589791/, the shoutbox stops parsing at the comma, which is one of the reserved characters in the URL standard (RFC 2396).

The second one is peculiar. It seems to parse the first two '+' signs and then stop for some reason. Notice that it also cuts the 's' after 'bar'. That error is reproducible.
----
Loading...
19.04.2011 - 10:59
Ivan
Retired Admin
Fixed.
Loading...
19.04.2011 - 18:59
corrupt
With a lowercase c
Written by Ivan on 19.04.2011 at 10:59

Fixed.

Just shouted Raganas google search as posted above and, no. Not fixed. I left the shout online for confirmation. But the 's' in 'bars' did stay this time
----
Loading...
19.04.2011 - 23:47
Ivan
Retired Admin
Written by corrupt on 19.04.2011 at 18:59

Written by Ivan on 19.04.2011 at 10:59

Fixed.

Just shouted Raganas google search as posted above and, no. Not fixed. I left the shout online for confirmation. But the 's' in 'bars' did stay this time

Are you sure your Javascript was reloaded? Because that link worked fine for me.
Loading...
20.04.2011 - 00:04
corrupt
With a lowercase c
Written by Ivan on 19.04.2011 at 23:47

Written by corrupt on 19.04.2011 at 18:59

Written by Ivan on 19.04.2011 at 10:59

Fixed.

Just shouted Raganas google search as posted above and, no. Not fixed. I left the shout online for confirmation. But the 's' in 'bars' did stay this time

Are you sure your Javascript was reloaded? Because that link worked fine for me.

Wait, you're doing that client-side? I don't have time to check what you changed right now, as load_shoutbox() looks the same to me, but ever thought of just base64'ing the whole shit and then storing links in the backend as escaped html? That at least is what I thought you did until I started digging into the structure and js of metalstorm. Otherwise stuff like this is bound to happen again.
But it is working now, my mistake.
----
Loading...
20.04.2011 - 09:44
Ivan
Retired Admin
Written by corrupt on 20.04.2011 at 00:04

Wait, you're doing that client-side? I don't have time to check what you changed right now, as load_shoutbox() looks the same to me, but ever thought of just base64'ing the whole shit and then storing links in the backend as escaped html? That at least is what I thought you did until I started digging into the structure and js of metalstorm. Otherwise stuff like this is bound to happen again.
But it is working now, my mistake.

Shoutbox uses AJAX. To send the shout I need to pass it through javascript. Parsing the displayed shouts is done server-side.
Loading...