background image

 

Grandstream Networks, Inc. 

XML Application Guide

  

Page 21 of 24 

 

 

Last Updated:  3/2009

 

 
 
 
 
 
 
 
 

Each softkey is bound by a URI, and pressing the soft key will call the corresponding URI. If the second 
softkey is pressed 

http://www.XMLquestionnaire.com/questionnaire.php?ans=yes

 is called. The server now 

knows the client response because the URI given to each soft key is unique. Once the answer is received, 
the server will send a 200 ok with another XML attached. 

  

<GS_XML_Application> 
 <Display> 
  <Screen> 
   <DisplayString 

valign=”Center”> 

 <X>0</X> 
 <Y>0</Y> 

 

<DisplayStr> Thank you for taking the </DisplayStr> 

</DisplayString > 

   <DisplayString 

       <X>0</X> 

<Y>10</Y> 
<DisplayStr>Survey</DisplayStr> 

</DisplayString > 

   <DisplayString 

halign=”Right” 

valign=”Bottom”> 

<X>0</X> 
<Y>0</Y> 
<DisplayStr>Surveyor</DisplayStr> 

</ DisplayString> 

  </Screen> 
 </Display> 
 

 

 <SoftKeys> 

<SoftKey> 

  <Label>Previous</Label> 
  <Action> 
  <UseURL> 

               <URL>

http://www.XMLquestionnaire.com/questionnaire.php?do=prev

 </URL> 

</UseURL> 
</Action> 
 

 </SoftKey> 
 <SoftKey> 
  <Label>Quit</Label> 
  <Action> 

<QuitApp/> 

 </Action> 

  <SoftKey> 
 </SoftKeys> 

</GS_XML_Application> 

 

In this XML, note that the last word, “Survey”, displayed at the center of the screen is in a new Line element. 
Otherwise, it would be displayed off the screen and look like this screen: 

 
 
 
 
 
 
 
 

Do you have a 
spouse? 

Previous    Yes    No         Next

Summary of Contents for XML

Page 1: ...Grandstream XML Application Guide Three XML Applications PART A Application Explanations PART B XML Syntax Technical Detail File Examples...

Page 2: ...XML Application Guide PART A Three XML Applications Grandstream GXP Series supports both simple and advanced XML applications Part A of this application note will describe Grandstream s XML applicati...

Page 3: ...IP endpoints XML enables our SIP phones to serve as output devices for many exciting applications The XML infrastructure allows our phones to interact with external applications in a flexible and prog...

Page 4: ...p to 128 characters that contains a path to the XML file It must follow the host path format i e directory grandstream com engineering The XML feature is activated when Enable Idle Screen XML Download...

Page 5: ...manually remove edited entries on download YES NO default NO P333 possible values 0 1 other values ignored The XML phonebook feature is activated when Enable Downloadable Phonebook is set to YES HTTP...

Page 6: ...009 Grandstream XML Application Guide PART B XML Syntax Technical Detail File Examples Part B of this application note will guide you through the technical details of our three applications 1 XML Cust...

Page 7: ...mplexType xs element xs complexType name BitmapType xs sequence xs element name Bitmap type xs base64Binary minOccurs 1 maxOccurs 1 xs element name X type xs integer minOccurs 1 maxOccurs 1 default 0...

Page 8: ...ion value a1reg xs enumeration value a2reg xs enumeration value a3reg xs enumeration value a4reg xs enumeration value a5reg xs enumeration value a6reg xs enumeration value a1voiceMsg xs enumeration va...

Page 9: ...ion value MissedCalls xs enumeration value CallReturn xs enumeration value PhoneBook xs enumeration value MainMenu xs enumeration value VoiceMail xs restriction xs simpleType xs element xs element nam...

Page 10: ...DisplayString font f13b halign Center a1reg true DisplayStr X DisplayStr X 65 X Y 26 Y DisplayString DisplayString halign Center valign Bottom DisplayStr I DisplayStr X 65 X Y 48 Y DisplayString Idle...

Page 11: ...ey Label New Call Label Action NewCall Action SoftKey SoftKey Label Missed Calls Label Action MissedCalls Action displayCondition conditionType missCall conditionType displayCondition SoftKey SoftKey...

Page 12: ...pType minOccurs 0 maxOccurs unbounded nillable true xs element name DisplayString type StringType minOccurs 0 maxOccurs unbounded nillable true The DisplaySoftKey element apply only to GXP 2020 2010 a...

Page 13: ...r LCD resolution Anything not bound to the above restriction is dropped and ignored You may use Windows Paint to change an existing BMP file to 1 bit depth Elements X and Y This element contains X and...

Page 14: ...12 y This variable is replaced with the current year in 2 digit number for example 06 07 13 P This variable is replaced with the current AM PM status in upper case possible values AM PM 14 p This vari...

Page 15: ...lignmentType xsd simpleType name HorizontalAlignmentType xsd restriction base xsd string xsd enumeration value Left xsd enumeration value Center xsd enumeration value Right xsd restriction xsd simpleT...

Page 16: ...curs 1 maxOccurs 1 xsd element name country type xsd string minOccurs 1 maxOccurs 1 xsd sequence xsd complexType xsd element xsd element name Phone xsd complexType xsd sequence xsd element name phonen...

Page 17: ...eir escape sequence Characters Name Escape Sequence Ampersand amp Quote quot Apostrophe apos Left Angle Bracket lt Right Angle Bracket gt GRANDSTREAM XML OBJECT GXP2020 XML Display As illustrated abov...

Page 18: ...e display showLineLabels Screen Attribute Optional Boolean Enable or disable line labels display to extend xml application display area DisplayString Screen Body Optional Display a string on the scree...

Page 19: ...ftkey Body Mandatory Action to be taken UseURL Action body Choice URL to call to QuitApp Action Body Choice Quit the current XML application Dial Action Body Choice Dial a number The remote server may...

Page 20: ...espond with a 200 OK with the XML attached to the packet The XML syntax may look like this GS_XML_Application Display Screen DisplayString X 0 X Y 0 Y DisplayStr Do you have a spouse DisplayStr Displa...

Page 21: ...ter X 0 X Y 0 Y DisplayStr Thank you for taking the DisplayStr DisplayString DisplayString X 0 X Y 10 Y DisplayStr Survey DisplayStr DisplayString DisplayString halign Right valign Bottom X 0 X Y 0 Y...

Page 22: ...howLineLabels false DisplayString X 0 X Y 0 Y DisplayStr wrap true Hello Please press Dial to start dialing and hang up the phone to exit the application DisplayStr DisplayString Screen Display SoftKe...

Page 23: ...plication Guide Page 23 of 24 Last Updated 3 2009 Action Event Events GS_XML_Application Pressing Dial dials 3051 with Account 1 After the survey is finished and the user hangs up the survey is ended...

Page 24: ...ou ll just need to navigate to the URL of the soft key as can be seen in the XML code For example on 12 34 56 78 test_gs xml you ll see that the first soft key is set to make the phone browse to 12 34...

Reviews: