本文整理匯總了PHP中Style::getStyles方法的典型用法代碼示例。如果您正苦於以下問題:PHP Style::getStyles方法的具體用法?PHP Style::getStyles怎麽用?PHP Style::getStyles使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類Style
的用法示例。
在下文中一共展示了Style::getStyles方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: readData
/**
* @see Page::readData()
*/
public function readData()
{
parent::readData();
// get default values
if (!count($_POST)) {
$sql = "SELECT\t*\n\t\t\t\tFROM\twcf" . WCF_N . "_style_to_package";
$result = WCF::getDB()->sendQuery($sql);
while ($row = WCF::getDB()->fetchArray($result)) {
if ($row['isDefault']) {
$this->defaultStyleIDArray[$row['packageID']] = $row['styleID'];
}
if ($row['disabled']) {
if (!isset($this->disabledStyleIDArray[$row['packageID']])) {
$this->disabledStyleIDArray[$row['packageID']] = array();
}
$this->disabledStyleIDArray[$row['packageID']][] = $row['styleID'];
}
}
}
// get standalone packages
$sql = "SELECT\tpackage.*,\n\t\t\t\tCASE WHEN package.instanceName <> '' THEN package.instanceName ELSE package.packageName END AS packageName\n\t\t\tFROM\twcf" . WCF_N . "_package package\n\t\t\tWHERE\tpackage.packageID IN (\n\t\t\t\t\tSELECT\tpackageID\n\t\t\t\t\tFROM\twcf" . WCF_N . "_package_dependency\n\t\t\t\t\tWHERE\tdependency IN (\n\t\t\t\t\t\t\tSELECT\tpackageID\n\t\t\t\t\t\t\tFROM\twcf" . WCF_N . "_package\n\t\t\t\t\t\t\tWHERE\tpackage = 'com.woltlab.wcf.system.style'\n\t\t\t\t\t\t)\n\t\t\t\t)\n\t\t\t\tAND standalone = 1";
$result = WCF::getDB()->sendQuery($sql);
while ($row = WCF::getDB()->fetchArray($result)) {
$this->packages[] = $row;
}
// get available styles
$this->styles = Style::getStyles();
}
示例2: readData
/**
* @see Page::readData()
*/
public function readData()
{
parent::readData();
// get available styles
$this->styles = Style::getStyles();
}