Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
api [2012/08/07 17:11]
lisa [Action: Third Party Web Service]
api [2012/08/07 17:31]
lisa [WorkXpress API Data Formats]
Line 754: Line 754:
 values: values:
    
-<​code>​e11|<​selectOptionId>,​e11|<​selectOptionId>​ (ex. e11|a36789,​e11|a36791)</​code>​+<​code>​e11|<​selectOptionId>,​e11|<​selectOptionId>​ (ex. e11|a36789,​e11|a36791)
 or or
  
-<​code>​<​title>,<​title>​ (ex. Pounds,​Feet) or +<​title>,<​title>​ (ex. Pounds,​Feet) or 
  
 <​altTitle>,<​altTitle>​ (ex. lbs,​ft)</​code>​ <​altTitle>,<​altTitle>​ (ex. lbs,​ft)</​code>​
Line 775: Line 775:
 standard date or date time format into a Unix time stamp: standard date or date time format into a Unix time stamp:
   ​   ​
 +<WRAP center round box 80%>
 <​code>​ <​code>​
 // convert a date value // convert a date value
Line 787: Line 788:
 $time = '11:35 AM'; $time = '11:35 AM';
 $time_stamp = strtotime('​January 1, 1970 '​.$time);</​code>​ $time_stamp = strtotime('​January 1, 1970 '​.$time);</​code>​
 +</​WRAP>​
 +
  
 For more information on Date Fields, visit For more information on Date Fields, visit
Line 800: Line 803:
 into the encoded file part of the XML.  In PHP you would using the following code: into the encoded file part of the XML.  In PHP you would using the following code:
    
-<WRAP center round box 60%>+<WRAP center round box 80%>
 <​code>​ <​code>​
 $file_path = '/​path/​to/​file.odf';​ $file_path = '/​path/​to/​file.odf';​
Line 820: Line 823:
    
  
-//Attributes://  +^Attributes:^^^  
-id String The name of the part.  Valid +|id |String ​|The name of the part.  Valid values include:| 
-values include: +| ::: | ::: |filename – The name to be given to the file, including extension.| 
- +| ::: | ::: |mime_type – The file's mime type. | 
-filename – The name to be +| ::: | ::: |size – The file's size in bytes.| 
-given to the file, including +| ::: | ::: |encoded_file – The base 64 encoded file. |
-extension. +
- +
-mime_type – The file's mime +
-type. +
- +
-size – The file's size in bytes. +
- +
-encoded_file – The base 64 +
-encoded file. +
  
 **Example:​** ​ **Example:​** ​
    
-<WRAP center round box 60%>+<WRAP center round box 80%>
 <​code>​ <​code>​
 <?xml version=”1.0”?>​ <?xml version=”1.0”?>​
Line 865: Line 859:
 **<​part></​part>​** - Defines the value for a single part of the Field. ​ **<​part></​part>​** - Defines the value for a single part of the Field. ​
  
-//Attributes:// +^Attributes:^^^ 
-id String The name of the part.  Valid  +|id |String ​|The name of the part.  Valid values include:| 
-  +| ::: | ::: |street – The value for the first street part.| 
-values include: +| ::: | ::: |street2 – The value for the second street part.| 
- +| ::: | ::: |street3 – The value for the third street part, only used for international ​addresses.| 
-street – The value for the first +| ::: | ::: |city – The value for the city.| 
-street part. +| ::: | ::: |state – The value for the state, up to three characters for international ​and two characters for United States.| 
- +| ::: | ::: |zip_code – The value for the postal code.  Should be numeric for United States addresses.| 
-street2 – The value for the +| ::: | ::: |country – The value for the country. ​ Should be the countries full fame or the ISO 3166-1 alpha-3 formatted country code (see http://​en.wikipedia.org/​wiki/​IS O_3166-1_alpha-3).| 
-second street part. +| ::: | ::: |type – Should be either International or United States.| 
- +| ::: | ::: |sort_value – Which street value should be used to sort this field. Should be either street, street2 or street3. ​ Only used for International address. ​|
-street3 – The value for the third +
-street part, only used for +
-International ​addresses. +
- +
-city – The value for the city. +
- +
-state – The value for the state, +
-up to three characters for +
-International ​and two +
-characters for United States. +
- +
-zip_code – The value for the +
-postal code.  Should be +
-numeric for United States +
-addresses. +
- +
-country – The value for the +
-country. ​ Should be the +
-countries full name or the ISO +
-3166-1 alpha-3 formatted +
-country code (see +
-http://​en.wikipedia.org/​wiki/​IS +
-O_3166-1_alpha-3). +
- +
-type – Should be either ​ +
-International or United States. +
-  +
-sort_value – Which street value +
-should be used to sort this field. ​ +
-Should be either street, street2 +
-or street3. ​ Only used for +
-International address. ​+
    
 **Example:​** **Example:​**
    
-<​code>​<WRAP center round box 60%>+<WRAP center round box 80%><​code>
 <?xm version=”1.0”?>​ <?xm version=”1.0”?>​
 <​multi_part_field>​ <​multi_part_field>​
Line 924: Line 886:
     <part id=”sort_value”>​street2</​part>​     <part id=”sort_value”>​street2</​part>​
 </​multi_part_field>​ </​multi_part_field>​
-</WRAP></code>+</code></WRAP>
    
  
Line 941: Line 903:
    
  
-//Attributes://  +^Attributes:^^^  
-id String The name of the part.  Valid values +|id |String ​|The name of the part.  Valid values include:| 
-include: +| ::: | ::: |area_code – The value for the area code.  Should be three digits for United States and up to five alphanumeric characters for International.| 
- +| ::: | ::: |prefix – For United States phone numbers, this is the three digits immediately following the area code.  This is not used for International numbers.| 
-area_code – The value for the area +| ::: | ::: |line_number – For United States phone numbers, this is the last four digits of the number. ​ For International phone numbers, this is the entire number ​ after the area code. | 
-code.  Should be three digits for +::: | ::: |extension – The value for the extension (if any).| 
-United States and up to five alphanumeric +| ::: | ::: |country_code – The country calling code for International Phone Numbers. ​ Should be 1 for United States. | 
-characters +| ::: | ::: |type – Should be either International or United States. ​|
-for +
- +
-International. +
- +
-prefix – For United States phone +
-numbers, this is the three digits +
-immediately following the area +
-code.  This is not used for +
-International numbers. +
- +
-line_number – For United States +
-phone numbers, this is the last four +
-digits of the number. ​ For +
-International phone numbers, this is +
-the entire number after the area +
-code.  +
- +
-Example +
-  +
-<​code><?​xm version=”1.0”?>​ +
-<​multi_part_field>​ +
-    <part id=”area_code”>​717</​part>​ +
-    <part id=”prefix”>​609</​part>​ +
-    <part id=”line_number”>​0029</​part>​ +
-    <part id=”extension”>​123</​part>​ +
-    <part id=”country_code”>​1</​part>​ +
-    <part id=”type”>​United States</​part>​ +
-</​multi_part_field>​ </​code>​ +
-  +
- +
-extension – The value for the +
-extension (if any). +
- +
-country_code – The country calling +
-code for International Phone +
-Numbers. ​ Should be 1 for United +
-States+
- +
-type – Should be either International +
-or United States. ​+
  
 **Example:​** ​ **Example:​** ​
    
-<​code>​<WRAP center round box 60%>+<WRAP center round box 80%
 +<code>
 <?xm version=”1.0”?>​ <?xm version=”1.0”?>​
 <​multi_part_field>​ <​multi_part_field>​
Line 1002: Line 925:
     <part id=”type”>​United States</​part>​     <part id=”type”>​United States</​part>​
 </​multi_part_field>​ </​multi_part_field>​
-</WRAP></code>+</code> 
 +</WRAP> 
  
 ====== Display Format Parts ====== ====== Display Format Parts ======
api.txt · Last modified: 2016/09/14 14:19 (external edit)
Copyright WorkXpress, 2020