img regular expressions

0 views
Skip to first unread message

Xavier Verges

unread,
May 20, 2008, 3:51:22 PM5/20/08
to TiddlyWikiDev
Google Charts urls can contain the "|" character
http://code.google.com/apis/chart/

Sample url:
http://chart.apis.google.com/chart?cht=r&chs=200x200&chd=t:10,20,30,40,50,60,70,80,90|20,30,40,50,60,70,80,90,100
http://is.gd/jhw

Of course, these urls cannot work when not using the "alt" element
[img[http://example.com/image.jpg]]
but they probably should work when providing an "alt" text
[img[This is shown as a tooltip|http://example.com/image.jpg]]

I'm under the impression that there is one too many ^\| in the regular
expression, but before opening a ticket, I'd like to know if I'm
missing something
http://tiddlywiki.pastebin.com/m217ae552

Is that a cut'n'paste leftover, or does it have some purpouse that I'm
missing?

Xavier Verges

unread,
May 20, 2008, 3:53:59 PM5/20/08
to TiddlyWikiDev

Those urls also break google groups regular expresion parsing :-)
Use the short url to access a sample url
http://is.gd/jhw

-Xv

Paul Downey

unread,
May 20, 2008, 3:57:01 PM5/20/08
to Tiddly...@googlegroups.com
Hola Xavier,

> Google Charts urls can contain the "|" character
> http://code.google.com/apis/chart/
>
> Sample url:
> http://chart.apis.google.com/chart?cht=r&chs=200x200&chd=t:10,20,30,40,50,60,70,80,90
> |20,30,40,50,60,70,80,90,100
> http://is.gd/jhw

any reason why URI escaping the '|' to %7c isn't good enough? i.e:

http://chart.apis.google.com/chart?cht=r&chs=200x200&chd=t:10,20,30,40,50,60,70,80,90%7c20,30,40,50,60,70,80,90,100

Paul
--
http://blog.whatfettle.com

Xavier Verges

unread,
May 20, 2008, 4:10:42 PM5/20/08
to TiddlyWikiDev
>
> any reason why URI escaping the '|' to %7c isn't good enough? i.e:
>
Reason: I'm a copy'n'paste parasite :-)

Gracias!

-Xv
Reply all
Reply to author
Forward
0 new messages