Retroceder   Foros del Web > Programación para sitios web > XML

Respuesta
 
Herramientas Desplegado
Antiguo 11-nov-2004, 13:32   #1 (permalink)
luisvasquez está en el buen camino
 
Avatar de luisvasquez
 
Fecha de Ingreso: diciembre-2003
Ubicación: Venezuela
Mensajes: 600
Pregunta Recibir y enviar info en XML usando ASP

Estimados amigos,

Tengo una tarea que considero complicada, dadas mis limitaciones en el conocimiento de XML.

Necesito recibir información en XML en mi web que está en ASP, luego almacenar esos datos en Access y enviar una respuesta en XML a la aplicación que me envió los datos.

Llamemos X a la aplicación que me envía los datos y luego me solicita una respuesta.

La aplicación X debe activar un URL en mi web para que yo pueda recibir los datos y luego mi web debe activar un url en el servidor donde está X para enviar la respuesta.

El formato que recibo es el siguiente:

<ProcessMORequest>
<brandID>string</brandID> //Brand to which the user belongs
<terminalID>int</terminalID> //Terminal on which the MO was received
<source>string</source> //MIN of the user that sends the MO
<destination>string</destination> //Port which the MO is directed to
<keyword>string</keyword> //Keyword typed by the user
<parameters>string</parameters> //Additional text typed by the user
<extTxnID>string</extTxnID> Transaction ID provided by SMSC
</ProcessMORequest>

De alli debo extraer los datos, almacenarlos en la b/d y luego enviar la respuesta. De acuerdo con las especificaciones de la compañía X, puedo enviar la respuesta usando alguno de estos 3 metodos: SOAP, GET y POST.

Los detalles aca:

SOAP

POST /WISXMLWMPWebService/WISXMLWMP.asmx HTTP/1.1
Host: 65.82.150.59
Content-Type: text/xml; charset=utf-8
Content-Length: length
SOAPAction: "http://www.cyclelogic.com/webdev/SubmitWMPMessage"
<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Body>
<SubmitWMPMessage xmlns="http://www.cyclelogic.com/webdev/">
<strBrandID>string</strBrandID>
<strServiceName>string</strServiceName>
<strSender>string</strSender>
<strOriginator>string</strOriginator>
<strMsgContentType>string</strMsgContentType>
<strMsgMarkingCode>string</strMsgMarkingCode>
<strMsgComponentDescriptor>string</strMsgComponentDescriptor>
<strMsgCallback>string</strMsgCallback>
<strMsgExpiry>string</strMsgExpiry>
<strMsgPriority>string</strMsgPriority>
<strMsgText>string</strMsgText>
<strNotificationID>string</strNotificationID>
<strNotificationURL>string</strNotificationURL>
<strEvents>string</strEvents>
<strSessionID>string</strSessionID>
<strSessionURL>string</strSessionURL>
<strSessionReplyTo>string</strSessionReplyTo>
<strRecipientsCheckValidity>string</strRecipientsCheckValidity>
<strRecipients>string</strRecipients>
<strSubscriptionMode>string</strSubscriptionMode>
<strChargePrice>string</strChargePrice>
<strChargeMode>string</strChargeMode>
<strChargePartyType>string</strChargePartyType>
<strCreditPrice>string</strCreditPrice>
<strCreditMode>string</strCreditMode>
<strCreditPartyType>string</strCreditPartyType>
<strCreditPartyID>string</strCreditPartyID>
<strProviderID>string</strProviderID>
<strProviderPwd>string</strProviderPwd>
</SubmitWMPMessage>
</soap:Body>
</soap:Envelope>
HTTP/1.1 200 OK
Content-Type: text/xml; charset=utf-8
Content-Length: length

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Body>
<SubmitWMPMessageResponse xmlns="http://www.cyclelogic.com/webdev/">
<SubmitWMPMessageResult>string</SubmitWMPMessageResult>
</SubmitWMPMessageResponse>
</soap:Body>
</soap:Envelope>


GET
GET /WISXMLWMPWebService/WISXMLWMP.asmx/SubmitWMPMessage?strBrandID=string&strServiceName= string&strSender=string&strOriginator=string&strMs gContentType=string&strMsgMarkingCode=string&strMs gComponentDescriptor=string&strMsgCallback=string& strMsgExpiry=string&strMsgPriority=string&strMsgTe xt=string&strNotificationID=string&strNotification URL=string&strEvents=string&strSessionID=string&st rSessionURL=string&strSessionReplyTo=string&strRec ipientsCheckValidity=string&strRecipients=string&s trSubscriptionMode=string&strChargePrice=string&st rChargeMode=string&strChargePartyType=string&strCr editPrice=string&strCreditMode=string&strCreditPar tyType=string&strCreditPartyID=string&strProviderI D=string&strProviderPwd=string HTTP/1.1
Host: 65.82.150.59
HTTP/1.1 200 OK
Content-Type: text/xml; charset=utf-8
Content-Length: length
<?xml version="1.0" encoding="utf-8"?>
<string xmlns="http://www.cyclelogic.com/webdev/">string</string>

POST

POST /WISXMLWMPWebService/WISXMLWMP.asmx/SubmitWMPMessage HTTP/1.1
Host: 65.82.150.59
Content-Type: application/x-www-form-urlencoded
Content-Length: length

strBrandID=string&strServiceName=string&strSender= string&strOriginator=string&strMsgContentType=stri ng&strMsgMarkingCode=string&strMsgComponentDescrip tor=string&strMsgCallback=string&strMsgExpiry=stri ng&strMsgPriority=string&strMsgText=string&strNoti ficationID=string&strNotificationURL=string&strEve nts=string&strSessionID=string&strSessionURL=strin g&strSessionReplyTo=string&strRecipientsCheckValid ity=string&strRecipients=string&strSubscriptionMod e=string&strChargePrice=string&strChargeMode=strin g&strChargePartyType=string&strCreditPrice=string& strCreditMode=string&strCreditPartyType=string&str CreditPartyID=string&strProviderID=string&strProvi derPwd=string
HTTP/1.1 200 OK
Content-Type: text/xml; charset=utf-8
Content-Length: length

<?xml version="1.0" encoding="utf-8"?>
<string xmlns="http://www.cyclelogic.com/webdev/">string</string>


Despues de toda esta sarta de improperios (para mi lo son, ciertamente entiendo muy poco de XML) la pregunta es:

Como recibo los datos con ASP?
Acaso los recibo como una parametro de entrada asi:
http://misitio.com/mipagina.asp?xml=xxx donde xxx es una variable que contiene todo los datos?

Espero que me perdonen si estoy diciendo algo inapropiado, pero es que ando bastante perdido...

Saludos y gracias,

Luis Vásquez
__________________
“La genialidad puede pasar desapercibida, pero la estupidez es imposible esconderla”
luisvasquez está desconectado   Responder Citando
Antiguo 28-nov-2004, 10:55   #2 (permalink)
luisvasquez está en el buen camino
 
Avatar de luisvasquez
 
Fecha de Ingreso: diciembre-2003
Ubicación: Venezuela
Mensajes: 600
Podrian ayudarme amigos??

Aun estoy en este aprieto...
__________________
“La genialidad puede pasar desapercibida, pero la estupidez es imposible esconderla”
luisvasquez está desconectado   Responder Citando
Respuesta
No hay votos aún.


Herramientas
Desplegado

Normas de Publicación
No puedes crear nuevos temas
No puedes responder temas
No puedes subir archivos adjuntos
No puedes editar tus mensajes

BB code is Activado
Caritas están Activado
[IMG] está Activado
Código HTML está Desactivado


La Zona horaria es GMT -6. Ahora son las 05:21.


Message Board Statistics

LinkBacks Enabled by vBSEO 3.1.0

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93