Redirect to an Application Page in Tizen Store from Tizen Web Application using Deep-Link

Just add this js Code chunk to Redirect from Tizen Web application to an Application Page (Download & Details) in Tizen Store. Thus you can easily advertise applications to your app users encouraging them to download the apps. The functionality is achieved using DeepLink and AppControl API.
function requestAppStore(appStoreUrl) {

	var appControl = new tizen.ApplicationControl("http://tizen.org/appcontrol/operation/view",appStoreUrl, null, null, null);		                               appStoreUrl, null, null, null);
	
	var storeId = "org.tizen.tizenstore";
	
	try {
		tizen.application.launchAppControl(appControl,storeId,null,null,null);
		console.log("Succeeded to Launch your app on appStore.");
	} 
	catch (exc) {
		console.log("Failed to launch your app on appStore.");
		alert("AppControl Exception:" + exc.message);
	} 	
}

/*For example package Id of facebook app ‘com.facebook.tizen’ is used, replace it with your application’s package Id.*/

var applicationPackageId = "com.facebook.tizen";		//or your application's Package ID
var appStoreUrl= "tizenstore://ProductDetail/"+applicationPackageId;
requestAppStore(appStoreUrl);


/*Add this privilege on your config.xml
 <tizen:privilege name="http://tizen.org/privilege/application.launch"/>
*/

Responses

0 Replies