Difference between revisions of "Pandora - Variables Replace"
From SmartWiki
m (Change "contact" to "content") |
|||
(2 intermediate revisions by 2 users not shown) | |||
Line 7: | Line 7: | ||
!Description | !Description | ||
|- | |- | ||
− | |'''Flag'''||True or false, send synchronously or asynchronously. | + | |'''Flag'''|| True or false, send synchronously or asynchronously. |
|- | |- | ||
− | |'''Callbackfunc''' ||Function to be used after the asynchronous function call. | + | |'''Callbackfunc''' || Function to be used after the asynchronous function call. |
|- | |- | ||
− | |'''objecttype'''|| Type of object to be processed (30:company, 40: user, 23: level one, | + | |'''objecttype'''|| Type of object to be processed (30: company, 40: user, 23: level one, 8: level 2, 8: level 3, 122: invoice, 78: transaction). |
|- | |- | ||
− | |'''object id'''||The ID of the object to be processed | + | |'''object id'''||The ID of the object to be processed. |
|- | |- | ||
− | |''' | + | |'''content'''|| The string that contains the text in which the variables are to be replaced. For ex. if the content were set to "welcome @firstname@ @lastname@" and the object ID were set to the current user then the return value would be: "Welcome Sample User" |
|- | |- | ||
| '''Returns''' || Formatted string | | '''Returns''' || Formatted string |
Latest revision as of 06:31, 24 August 2012
This function invokes the variable processor and returns formatted content.
variables_replace(flag,callbackfunc,objecttype,objectid,content)
Parameter | Description |
---|---|
Flag | True or false, send synchronously or asynchronously. |
Callbackfunc | Function to be used after the asynchronous function call. |
objecttype | Type of object to be processed (30: company, 40: user, 23: level one, 8: level 2, 8: level 3, 122: invoice, 78: transaction). |
object id | The ID of the object to be processed. |
content | The string that contains the text in which the variables are to be replaced. For ex. if the content were set to "welcome @firstname@ @lastname@" and the object ID were set to the current user then the return value would be: "Welcome Sample User" |
Returns | Formatted string |