Jump to content

[TOPIC: topicViewTemplate]
[GLOBAL: userSmallPhoto]
Photo

tripadvisor review from an app
Started by carloscosta Nov 08 2017 09:09 AM

- - - - -
No replies to this topic
[TOPIC CONTROLS]
This topic has been archived. This means that you cannot reply to this topic.
[/TOPIC CONTROLS]
[modOptionsDropdown]
[/modOptionsDropdown]
[reputationFilter]
[TOPIC: post.html]
#1

carloscosta

[GLOBAL: userInfoPane.html]
carloscosta
  • Contributor

  • 687 posts
  • Corona SDK

Hi.

 

I have a client that wants an app to have a review page that goes directly to TripAdvisor reviews.

 

I didn't find a way to do this because as far as I know TripAdvisor won't lets to do that.

 

what i did found was a widget that users can put on a webpage and from there the widget will link to the tripavisor review system.

 

what i did on my app was create and local html with the widget created from tripavisor website, and open it on a webview.

 

on an apple device, it worked like a charme. it will open the tripavisor app (on the correct client page) and you could review it from there or if you don't have the tripavisor app, it will suggest to download it.

 

on android it fails bad. with or without tripadisor app on my device, it tries to open the app it will give the error:

 

"Error!

net::ERR_UNKNOWN_URL_SCHEME"

 

what can i do on my side to resolve this?

 

i could detect on my side if its android with this code:

local appIcon = display.newImage("android.app.icon://com.tripadvisor.tripadvisor",160,-200)
if appIcon then
-- App is installed.
display.remove(appIcon)
appIcon = nil
appinstalled = true
else
-- App is not installed.
appinstalled = false
end

i could then have an display box asking the user if they want to download it or not if yes:

 

it would go to this code:

local options =
{
   androidAppPackageName = "com.tripavisor.tripadvisor",
   supportedAndroidStores = { "google" }
}
native.showPopup( "appStore", options )

my problem is, this won't resolve the problem because even when i have the app installed it will give the error i mention before just resolves the part that on android the widget wont detect if the app is installed and suggest to download it like on apple does.

 

i thought also if i could open the tripavisor app with some sort of parameters i could open it with the client page but didnt found nothing about this.

 

anyone was able to work with tripadvisor from an app with success?

 

Am I thinking right here? or there is another solution that I'm missing?

 

regards,

 

Carlos.




[topic_controls]
[/topic_controls]