本文整理汇总了PHP中Redux_Functions::parseCSS方法的典型用法代码示例。如果您正苦于以下问题:PHP Redux_Functions::parseCSS方法的具体用法?PHP Redux_Functions::parseCSS怎么用?PHP Redux_Functions::parseCSS使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Redux_Functions
的用法示例。
在下文中一共展示了Redux_Functions::parseCSS方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: output
public function output()
{
if ((!isset($this->field['output']) || !is_array($this->field['output'])) && !isset($this->field['compiler'])) {
return;
}
if (!empty($this->value)) {
$mode = isset($this->field['mode']) && !empty($this->field['mode']) ? $this->field['mode'] : 'color';
if ($this->value['alpha'] == "0.00" || empty($this->value['color'])) {
$style = $mode . ':transparent;';
} elseif (!empty($this->value['color'])) {
$style = $mode . ':rgba(' . Redux_Helpers::hex2rgba($this->value['color']) . ',' . $this->value['alpha'] . ');';
}
if (!empty($this->field['output']) && is_array($this->field['output'])) {
$css = Redux_Functions::parseCSS($this->field['output'], $style, $this->value);
$this->parent->outputCSS .= $css;
}
if (!empty($this->field['compiler']) && is_array($this->field['compiler'])) {
$css = Redux_Functions::parseCSS($this->field['compiler'], $style, $this->value);
$this->parent->compilerCSS .= $css;
}
}
}
示例2: output
/**
* Output Function.
*
* Used to enqueue to the front-end
*
* @since 1.0.0
* @access public
* @return void
*/
public function output()
{
if (!empty($this->value)) {
$style = '';
$mode = isset($this->field['mode']) && !empty($this->field['mode']) ? $this->field['mode'] : 'color';
$color_val = $this->getColorVal();
$style .= $mode . ':' . $color_val . ';';
if (!empty($this->field['output']) && true == $this->field['output']) {
$css = Redux_Functions::parseCSS($this->field['output'], $style, $color_val);
$this->parent->outputCSS .= $css;
}
if (!empty($this->field['compiler']) && true == $this->field['compiler']) {
$css = Redux_Functions::parseCSS($this->field['compiler'], $style, $color_val);
$this->parent->compilerCSS .= $css;
}
}
}
示例3: output
public function output()
{
$style = '';
if (!empty($this->value)) {
$mode = isset($this->field['mode']) && !empty($this->field['mode']) ? $this->field['mode'] : 'color';
$style .= $mode . ':' . $this->value . ';';
if (!empty($this->field['output']) && is_array($this->field['output'])) {
$css = Redux_Functions::parseCSS($this->field['output'], $style, $this->value);
$this->parent->outputCSS .= $css;
}
if (!empty($this->field['compiler']) && is_array($this->field['compiler'])) {
$css = Redux_Functions::parseCSS($this->field['compiler'], $style, $this->value);
$this->parent->compilerCSS .= $css;
}
}
}