Difference between revisions of "Page Templates:Functions"

From Whirlwind eCommerce Wiki
Jump to: navigation, search
Line 2: Line 2:
 
A series of custom functions are created to allow content management to easily access content they require to build the copy in templates:
 
A series of custom functions are created to allow content management to easily access content they require to build the copy in templates:
  
;Quick Output of State/Country Options in a Form Select
+
;Quick Output of Options Tags for common select boxes
 
*[[functions:addressStateOptions|addressStateOptions]] - returns string of option tags for states
 
*[[functions:addressStateOptions|addressStateOptions]] - returns string of option tags for states
 
*[[functions:addressCountryOptions|addressCountryOptions]] - returns string of option tags for countries
 
*[[functions:addressCountryOptions|addressCountryOptions]] - returns string of option tags for countries
*[[functions:addressCountryNameGet|addressCountryNameGet]] - returns full country name from ISO 2 digit format
+
*[[functions:orderExpDateOptions|orderExpDateOptions]] - returns string of option tags for expiration dates of a credit card
*[[functions:addressZipDetailsGet|addressZipDetailsGet]] - returns data about zip including: city,state,areaCode,county,timeZone,latitude,longitude,dayLightSavings
+
*[[functions:orderPayTypeOptions|orderPayTypeOptions]] - returns string of option tags for pay types
  
 
;Set Variables that Content Managers can use in the WYSIWYG copy editor
 
;Set Variables that Content Managers can use in the WYSIWYG copy editor
Line 49: Line 49:
 
*[[functions:userBlogEntryAddEdit|userBlogEntryAddEdit]] - managers user blog entries
 
*[[functions:userBlogEntryAddEdit|userBlogEntryAddEdit]] - managers user blog entries
 
*[[functions:userBlogSetup|userBlogSetup]] - sets up a user with a blog
 
*[[functions:userBlogSetup|userBlogSetup]] - sets up a user with a blog
 +
 +
;Retrieve additional information from address data
 +
*[[functions:addressCountryNameGet|addressCountryNameGet]] - returns full country name from ISO 2 digit format
 +
*[[functions:addressZipDetailsGet|addressZipDetailsGet]] - returns data about zip including: city,state,areaCode,county,timeZone,latitude,longitude,dayLightSavings
  
 
;Shortcut Functions that just plain make your job easier
 
;Shortcut Functions that just plain make your job easier

Revision as of 12:35, 23 October 2008

Page Template Managers

Page Template Functions

A series of custom functions are created to allow content management to easily access content they require to build the copy in templates:

Quick Output of Options Tags for common select boxes
Set Variables that Content Managers can use in the WYSIWYG copy editor
Retrieve Page Content to Build Pages
Retrieve Order information for perpetual and full shopping carts, checkout stages, order history
  • orderGetSummary - returns summerized order information. Useful for perpetual carts.
  • orderGetPayTypes - returns data relating to active paytypes in the system
  • userGetAddresses - returns data for all addresses belonging to a specific user
  • orderGetShipArray - returns array of shipping options and costs
  • orderGetCompleteArray - returns full order information including payment, item, address, etc. Use for shopping carts, order summaries and receipts of orders.
Retrieve User Content to Build Community (Web 2.0) Pages
  • usersGet - retrieve user data from a list of user ids
  • userBlogEntriesGet - retrieve blog entry data belonging to a specific user
  • userFriendsGet - retrieves data for users in a specific user's 'friend list'
  • userWishListGet - retrieves product data for products in a specific user's wish list
  • usersAmbassadorGet - retrieves user data for users that are classified as 'ambassadors'


Set Tracking Functions
User Management Functions
Retrieve additional information from address data
Shortcut Functions that just plain make your job easier
  • redirect - redirects visitors to another page
  • valueArrayFromQuery - returns a single dimension array of values based on the contents of a specific column in all records of a query
  • dollarFormat - converts a decimal to a dollar value with preceding $ sign.
Functions used by internal actions, you probably will not use