Example #1
0
function vuetiful_get_theme_admin_data()
{
    $theme_color = get_option('vuetiful-theme-color');
    $theme_colors = vuetiful_get_theme_colors();
    $theme_color_names = array_keys($theme_colors);
    $favicon_id = get_option('vuetiful-favicon');
    $favicon_url = '';
    if ($favicon_id) {
        $favicon_url = wp_get_attachment_url($favicon_id);
    }
    return array('themeColor' => in_array($theme_color, $theme_color_names) ? $theme_color : $theme_color_names[0], 'themeColors' => $theme_colors, 'faviconID' => $favicon_id, 'faviconURL' => $favicon_url, 'faviconTitle' => __('Select a Favicon', 'vuetiful'), 'faviconButton' => __('Pick Favicon', 'vuetiful'));
}
Example #2
0
<?php

$theme_color_option = get_option('vuetiful-theme-color');
$theme_colors = vuetiful_get_theme_colors();
$theme_color_names = array_keys($theme_colors);
if (!in_array($theme_color_option, $theme_color_names)) {
    $theme_color_option = $theme_color_names[0];
}
$theme_color = $theme_colors[$theme_color_option][1];
$css = <<<CSS
* { margin: 0; padding: 0; outline: 0; }

body, html { height: 100%; }

body {
\tfont-size: 14px;
\tline-height: 1.3;
\tfont-family: 'Open Sans', arial, helvetica, sans-serif;
\tcolor: #000;
\tbackground: #eee;
}

h1,
h2,
h3,
h4,
h5,
h6 { font-weight: 400; padding-bottom: 0.3em; }

a { color: #777; text-decoration: none; cursor: pointer; transition: color 0.3s; }
a:hover { color: {$theme_color}; }