Google Map API Direction Service steps shows Chinese letters - google-maps-api-3

I am using direction services and I get response like the following:
"Head north on Piazza del Duomo toward Piazza S. Giovanni/圣若望广场/聖若望廣場"
I saw this several times for sites in Florence.
For example, between Florence Cathedral and Battistero but there are more.
Is there anything I can do to fix this?
Thanks,
Amir

It must be a bug(data-defect?).
These chinese characters seem to be a real translation of Piazza S. Giovanni(of course the translation should not be there).
When I e.g. set the language to german I even get more translations(russian, hebrew,hungarian,greek)
I'm afraid the only thing you can do so far is to send a bug-report: https://code.google.com/p/gmaps-api-issues/issues/entry?template=Directions%20API%20-%20Bug

Related

Here API - Need guidance defining query, q, value

The HERE api seems really picky about what is uses for the q parameter in API calls. According to the documentation you can use a street address, partial address, name of place, etc (documentation: https://developer.here.com/documentation/places/topics/free-text-search.html)
Im trying to take an address and return the name of the store, building, business at that location (a few million of these) In some cases I have a human typed name of the place at the address but this can be quite messy and inaccurate in a lot of cases so Im trying not to use this information. Address however Im quite confident in.
in summary Im trying to provide here with an input like "15300 Cedar Ave, Apple Valley, MN 55124" and output "Best Buy"
Here seems to be really finicky on what your q input is..
When I put in the address and geocode info, Best Buy doesn’t appear on the results list
q=15300 Cedar Ave, Apple Valley, MN 55124
in=44.7287,-93.2147;r=800
https://places.demo.api.here.com/places/v1/discover/search?q=15300+Cedar+Ave%2C+Apple+Valley%2C+MN+55124&in=44.7287%2C-93.2147%3Br%3D800&Accept-Language=en-US%2Cen%3Bq%3D0.9&app_id=DemoAppId01082013GAL&app_code=AJKnXv84fjrb0KIHawS0Tg
Based on this Im thinking maybe this info just isnt in here's database, but when I run this query which includes best buy in the search it finds it right away at the correct address!!
q=best buy 15300 Cedar Ave, Apple Valley, MN 55124
in=44.7287,-93.2147;r=800
https://places.demo.api.here.com/places/v1/discover/search?q=best+buy+15300+Cedar+Ave%2C+Apple+Valley%2C+MN+55124&in=44.7287%2C-93.2147%3Br%3D800&Accept-Language=en-US%2Cen%3Bq%3D0.9&app_id=DemoAppId01082013GAL&app_code=AJKnXv84fjrb0KIHawS0Tg
It seems like a no-brainer to me that HERE would use the q value as an address search but that doesnt always appear to be the case. Looking for guidance on how to make this smarter
if the point of interest(POI) needs to be searched by specific address, then q is significant for fetching the records. As the API will fetch only those records which have those keywords in that area.
if POIs need to be searched at specific lat-long and around defined meter range, then q is not significant.
https://places.demo.api.here.com/places/v1/discover/around?in=44.7287%2C-93.2147%3Br%3D800&Accept-Language=en-US%2Cen%3Bq%3D0.9&app_id=DemoAppId01082013GAL&app_code=AJKnXv84fjrb0KIHawS0Tg
Is it mandatory for you to pass address all the time, or lat-long can also work ?

Google Analytics Filter SPAM contain a word by campaign source

My website is under attack by click-bait bots disguised as a SEO solutions.
Those bots are messing with my numbers everyday...
When ever i discover a fake referral URL trying to get me, I filter / block them by their campaign source that usually includes the word "SEO".
Filter works fine for explicit source, but those bots hit me every-time with a new URL campaign source. So I end-up with tens of filters desperate trying to block all those!
Here are some examples:
autoseo-b2b-seo-service.com
seo-services-wordpress.com
krumbleead-ads.info
seo-services-b2b.com
growth-hackingead.info
autoseo-b2b-services.com
seo-b2b-analytics.com
seo-b2b.com
seo-for-b2b.com
I'm looking for RegEx filter solution to block any referrer that includes the word "seo-" SEO word with a dash.
I'm not RegEx savvy... But i just added (as exclude) & trying out the following:
.*seo-.*$
Q1. Does this look correct?
Q2. Better solution to block all those F**** bots?
Q3. How many cups of coffee did you have today? :P
Im a bit rusty on regex. Buuut last time i checked:
Q1: Does this look correct?
If you want to check for it as a single, full word, it's \bTest\b\b represents a "word boundary"
So ^.*\b(seo)\b.*$ I believe =)
Q2: Better solution to block all those expletive bots?
I think its best solution you can have really.
Q3: How many cups of coffee did you have today?
I drink tea. Mint tea normally. But i've been busy all day so i've only had one! Mainly making my way through this large bottle of water
Further Reading: https://www.regular-expressions.info/completelines.html

GraceNote - generate playlist with music of a given country

I would like to use GraceNote to generate play-lists which contain songs likely to appeal to, or, at least, be known to, residents of a given country. E.G, Japan, Korea, Turkey, Brazil, France ...
They don't necessarily have to be in the local language, as I don't think that I can do that with GraceNote (can I ?), but local artists would be nice. Is there any way, for instance, to query and generate a playlist using artist origin?
I realize that something like Gangnam Style might be known in most countries ;-) and that play-list generation is inexact when used this way, but I would be happy with a 70 or 80% "I know that song" reaction.
Can it be done? If so, how? #cweichen, can you help?
It seems likely you are referring the the Rhythm API. As you probably can see from the function definition, you cannot create a playlist using 'ARTIST_ORIGIN'.
The closest thing I can think of is creating a playlist (aka radio station) using on a popular song in the given country as a seed.
You may try configuring the 'focus_similarity' value to get a wider variety of songs. This is just a suggestion and I am not sure if this will get you what your looking for.
*Pygn currently does not support 'focus_similarity' configuration but it should not be too difficult to add yourself.

Google Analytics Reporting API: how can I filter by multiple cities?

I am working with the Google Analytics Reporting API. The problem I am running in to is that as far as I can tell the city dimension is not necessarily unique (i.e. multiple cities can have the same name.) So in order to filter to a specific city I need something like ga:country=France;ga:city=Paris which works fine, unless I want everything from Paris OR London. But the OR operator has a higher precedence than the AND operator in the filter expressions, and it doesn't look like there is a way to group expressions together.
So,
Are the strings returned by google analytics for ga:city uniquely identifiy a city?
Is there any way to group expressions together like (ga:country=France;ga:city=Paris),(ga:country=UK,ga:city=London)?
If neither of the above, is there any other workaround?
One of the examples on the reference guide is:
Operating system is (Windows OR Macintosh) AND browser is (Firefox OR Chrome):
ga:operatingSystem==Windows,ga:operatingSystem==Macintosh;ga:browser==Firefox,ga:browser==Chrome
In your situation you could do it in the way of (United Kingdom OR France) AND (Paris OR London) but it would still have your problem if there was a paris in the UK or a london in France.
A workaround would be to make one request where you query the cities in France, and a second different request where you query for the cities in the UK. It would mean making more requests but usually in these kind of cases having smaller but more specific requests is better practice. (And probably easier to manage)

Google translate text-to-speech in British

I'm using the (unofficial) Google translate TTS api to retrieve mp3s to support disabled learners to read web pages. It all works fine, however we have an American accent (we're in the UK!). When I use Google translate however, it fetches the mp3 with a British accent - how do I invoke this behavior?
I've used the same GET request URL so I can assume it's not that:
http://translate.google.com/translate_tts?q=testing+1+2+3&tl=en
(I've played with other language codes (en-gb) with no luck - fr works for french however.)
Many thanks
You can specify a regional variation in the tl parameter after an _ character, e.g.
http://translate.google.com/translate_tts?q=testing+1+2+3&tl=en_us
http://translate.google.com/translate_tts?q=testing+1+2+3&tl=en_gb
http://translate.google.com/translate_tts?q=testing+1+2+3&tl=en_au
By using google's ".co.uk" translate site's GET request, you can generate British English.
So for example: translate.google.co.uk/translate_tts?q=Your+soundcard+works+perfectly&tl=en

Resources