Chris Craft
Chris Craft

Reputation: 5315

Open Marketplace from Windows Phone 7 browser

Is there a way to open the Windows Phone 7 marketplace from a page being viewed in the mobile browser.

In an WP7 app I can do this:

MarketplaceDetailTask marketplaceDetailTask = new MarketplaceDetailTask();
marketplaceDetailTask.ContentIdentifier = "3cc99ca6-f0e6-df11-a844-00237de2db9e";
marketplaceDetailTask.Show();

On the desktop I can do this in a web page:

http://social.zune.net/redirect?type=phoneApp&id=3cc99ca6-f0e6-df11-a844-00237de2db9e

Is there a way to do this from a web page in the mobile browser?

Upvotes: 21

Views: 4161

Answers (3)

Stephen Perelson
Stephen Perelson

Reputation: 6773

The rules for marketplace links changed and the zune:// links are no longer valid. The proper format for the deep link is:

http://windowsphone.com/s?appid=the_app_id

The appid is the guid assigned to your app and can be found on the details screen for your app in the app hub.

The advantage of this format is that it is a direct link to the app in the user's localized marketplace.

On a Windows Phone, this link opens the web browser, which immediately launches the marketplace app.

Upvotes: 1

Omar Shahine
Omar Shahine

Reputation: 1993

The URL format to launch Marketplace on the phone when a user clicks on a URL is:

zune://navigate/?appID={app guid}

So for your app that would be:

zune://navigate/?appID=3cc99ca6-f0e6-df11-a844-00237de2db9e

If you want this hyperlinked in the browser simply wrap with a href tag.

<a href="zune://navigate/?appID=3cc99ca6-f0e6-df11-a844-00237de2db9e">Download Marketplace Search</a>

Upvotes: 11

Den
Den

Reputation: 16826

The browser on Windows Phone 7 emulator doesn't support direct (type -> navigate) application navigation. What Omar is showing won't work if you type it up in the emulator because there are internal restrictions as to what protocols can called directly, and zune is not one of the supported protocols.

It will, however, work from the email application and the browser as a link.

Upvotes: 2

Related Questions