안녕하세요, 저는 Windows Phone 8을 (를) 개발하고 있습니다. PHP를 사용하여 타일 푸시 알림을 보내고받을 필요가 있습니다. 타일 푸시 알림을 내 기기에서 수신하지 못했습니다. 아래 오류가 나타납니다. 아무도 왜이 문제에 직면하고 있다고 말할 수 있습니까?Windows Phone 타일 푸시 알림을 수신하지 못합니까?
오류 : I 코드를 사용하고
HTTP/1.1 200 OK Cache-Control: private Server: Microsoft-IIS/7.5 X-DeviceConnectionStatus: Connected X-NotificationStatus: Suppressed X-SubscriptionStatus: Active X-MessageID: 00000000-0000-0000-0000-000000000000 ActivityId: d4a926a3-345c-432f-9a96-2f9c62ce8013 X-Server: DB3MPNSM036 X-AspNet-Version: 4.0.30319 X-Powered-By: ASP.NET Date: Tue, 01 Oct 2013 09:08:33 GMT Content-Length: 0
다음과 같다 :
여기HttpNotificationChannel pushChannel;
// The name of our push channel.
string channelName = "TileSampleChannel";
InitializeComponent();
// Try to find the push channel.
pushChannel = HttpNotificationChannel.Find(channelName);
// If the channel was not found, then create a new connection to the push service.
if (pushChannel == null)
{
pushChannel = new HttpNotificationChannel(channelName);
// Register for all the events before attempting to open the channel.
pushChannel.ChannelUriUpdated += new EventHandler<NotificationChannelUriEventArgs>(PushChannel_ChannelUriUpdated);
pushChannel.ErrorOccurred += new EventHandler<NotificationChannelErrorEventArgs>(PushChannel_ErrorOccurred);
pushChannel.Open();
// Bind this new channel for Tile events.
pushChannel.BindToShellTile();
}
else
{
// The channel was already open, so just register for all the events.
pushChannel.ChannelUriUpdated += new EventHandler<NotificationChannelUriEventArgs>(PushChannel_ChannelUriUpdated);
pushChannel.ErrorOccurred += new EventHandler<NotificationChannelErrorEventArgs>(PushChannel_ErrorOccurred);
// Display the URI for testing purposes. Normally, the URI would be passed back to your web service at this point.
System.Diagnostics.Debug.WriteLine(pushChannel.ChannelUri.ToString());
// MessageBox.Show(String.Format("Channel Uri is {0}",pushChannel.ChannelUri.ToString()));
}
void PushChannel_ChannelUriUpdated(object sender, NotificationChannelUriEventArgs e)
{
Dispatcher.BeginInvoke(() =>
{
// Display the new URI for testing purposes. Normally, the URI would be passed back to your web service at this point.
System.Diagnostics.Debug.WriteLine(e.ChannelUri.ToString());
// MessageBox.Show(String.Format("Channel Uri is {0}", e.ChannelUri.ToString()));
});
}
void PushChannel_ErrorOccurred(object sender, NotificationChannelErrorEventArgs e)
{
// Error handling logic for your particular application would be here.
Dispatcher.BeginInvoke(() => MessageBox.Show(String.Format("A push notification {0} error occurred. {1} ({2}) {3}",e.ErrorType, e.Message, e.ErrorCode, e.ErrorAdditionalData)));
}