本文整理汇总了PHP中TikiLib::tikiURL方法的典型用法代码示例。如果您正苦于以下问题:PHP TikiLib::tikiURL方法的具体用法?PHP TikiLib::tikiURL怎么用?PHP TikiLib::tikiURL使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类TikiLib
的用法示例。
在下文中一共展示了TikiLib::tikiURL方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: add
/**
* Add Tiki object change information to reports cache
* and remove it from the $watches array so that it is not
* send to the user in a single email.
*
* @param array $watches a list of users watching the changed object and some information about the object itself
* @param array $data information about the changed object
* @param array $users a list of users that are using periodic reports
* @return null
*/
public function add(&$watches, $data, $users)
{
$data["base_url"] = TikiLib::tikiURL();
//Store $base_url in the database. Use it to construct links in the email.
foreach ($watches as $key => $watch) {
// if user in the watch has enabled periodic reports
if (in_array($watch['user'], $users)) {
// add data to report cache
$this->table->insert(array('user' => $watch['user'], 'event' => $data['event'], 'data' => serialize($data), 'time' => $this->dt->format('Y-m-d H:i:s')));
// remove data from $watches array so that the user doesn't receive a email
// notification for the event
unset($watches[$key]);
}
}
}