Aller au contenu
View in the app

A better way to browse. Learn more.

Next

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

reponse xml dans fault

Featured Replies

Posté(e)

Bonjour,

dans la réponse de ma requête, je reçois un fichier xml, si c'est la bonne réponse, je recois le fichier xml dans result, mais ci c'est fault je ne le recoit pas, je recoit un code erreur 500.

est ce possible de récupérer le fichier xml dans fault?

Posté(e)
  • Auteur

supposons que j'ai un code comme celui là :

<?xml version="1.0" encoding="utf-8"?>

<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute" creationComplete="init()">

<mx:Script>

<![CDATA[

import mx.controls.Alert;

import mx.collections.ArrayCollection;

import mx.rpc.events.ResultEvent;

import mx.rpc.events.FaultEvent;

import mx.managers.CursorManager;

private function init():void

{

monService.send();

CursorManager.setBusyCursor();

}

private function monServiceResultHandler(event:ResultEvent):void

{

maListe.dataProvider = event.result.films.film as ArrayCollection;

CursorManager.removeBusyCursor();

}

private function monServiceFaultHandler(event:FaultEvent):void

{

CursorManager.removeBusyCursor();

Alert.show (event.fault.message);

}

]]>

</mx:Script>

<mx:HTTPService id="monService" url="films.xml" result="monServiceResultHandler(event)" fault="monServiceFaultHandler(event)"/>

<mx:List id="maListe" labelField="titre"></mx:List>

</mx:Application>

dans la fonction monServiceResultHandler je récupère le fichier xml. dans mon cas je voudrais aussi récupérer un fichier xml dans monServiceFaultHandler. est ce possible, etant donné qu'il n'y a pas de .result... pour le FaultEvent?

Archivé

Ce sujet est désormais archivé et ne peut plus recevoir de nouvelles réponses.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.