QR code not encoding full product URL

54 views
Skip to first unread message

monkey

unread,
Oct 29, 2011, 5:57:45 PM10/29/11
to Google Visualization API
While trying to dynamically create qr codes for some client sites I
have found that some types of URL's don't fully encode with the QR
creator..

http://chart.apis.google.com/chart?cht=qr&choe=UTF-8&chs=300x300&chl=online_store/?slug=product_info.php&products_id=33
produces a QR code for
http://chart.apis.google.com/chart?cht=qr&choe=UTF-8&chs=300x300&chl=online_store/?slug=product_info.php
You can substitute /showcaseproductdetail.htm?ID=157729&Used=1& and
get /showcaseproductdetail.htm?ID=157729 with the same inaccurate
results.

This is a very inconvenient issue since the links that don't produce
the right QR are their product links. I know that the link has to be
converted somehow so that it would read with characters like this:
http://chart.apis.google.com/chart?cht=qr&chs=350x350&chl=online_store%2F%3Fslug%3Dproduct_info.php%26products_id%3D33

Unfortunately I have not found a way to do that with any kind of
simple, self-enclosed, method [See Below] and it's looking like I
won't. changing the choe value and moving it around doesn't seem to
have any effect at all. From what I can tell jQuery or zxing could do
it but again, I am no kind of programmer. I have been so confounded by
this I was considering trying to work out a link shortening solution,
as of now I am trying to follow all the way through to keep my
original approach.

-----

PLEASE Someone help me with a suggestion. At the very least a clue or
hint to what I am not seeing. This is the script I am using to create
QR's for the pages:

<script language="JavaScript">
document.write ("<a href=http://chart.apis.google.com/chart?
cht=qr&amp;chs=300x300&amp;chl="+location.href+"?qr target=_blank>
<img height=300 width=300 border=0 src=http://chart.apis.google.com/
chart?cht=qr&amp;chs=300x300&amp;chl="+location.href+"?qr></a>")
</script>

Jinji

unread,
Oct 31, 2011, 8:03:14 AM10/31/11
to google-visua...@googlegroups.com
This is the right forum for questions regarding Google Chart API. Please refer there.


--
You received this message because you are subscribed to the Google Groups "Google Visualization API" group.
To post to this group, send email to google-visua...@googlegroups.com.
To unsubscribe from this group, send email to google-visualizati...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/google-visualization-api?hl=en.


monkey

unread,
Oct 31, 2011, 9:16:37 AM10/31/11
to Google Visualization API
Thanks. My apologies.

On Oct 31, 7:03 am, Jinji <ji...@google.com> wrote:
> This <http://groups.google.com/group/google-chart-api> is the right forum
> for questions regarding Google Chart API. Please refer there.
>
>
>
>
>
>
>
> On Sat, Oct 29, 2011 at 11:57 PM, monkey <onebadmon...@gmail.com> wrote:
> > While trying to dynamically create qr codes for some client sites I
> > have found that some types of URL's don't fully encode with the QR
> > creator..
>
> >http://chart.apis.google.com/chart?cht=qr&choe=UTF-8&chs=300x300&chl=...
> > produces a QR code for
>
> >http://chart.apis.google.com/chart?cht=qr&choe=UTF-8&chs=300x300&chl=...
> > You can substitute  /showcaseproductdetail.htm?ID=157729&Used=1&  and
> > get  /showcaseproductdetail.htm?ID=157729 with the same inaccurate
> > results.
>
> > This is a very inconvenient issue since the links that don't produce
> > the right QR are their product links. I know that the link has to be
> > converted somehow so that it would read with characters like this:
>
> >http://chart.apis.google.com/chart?cht=qr&chs=350x350&chl=online_stor...
Reply all
Reply to author
Forward
0 new messages