/** * Add custom style to login screen * * @return void * @since 0.9.0 */ public function add_login_style() { $bg_color = get_option('yith_login_background_color'); $bg_image = get_option('yith_login_background_image'); $bg_repeat = get_option('yith_login_background_repeat'); $bg_position = get_option('yith_login_background_position'); $bg_attachment = get_option('yith_login_background_attachment'); $logo_img = get_option('yith_login_logo_image'); $logo_color = get_option('yith_login_logo_color'); $logo_width = get_option('yith_login_logo_width'); $logo_height = get_option('yith_login_logo_height'); $container_width = get_option('yith_login_container_width'); /* typography */ $typo_input_text = yit_typo_option_to_css(get_option('yith_login_typo_input')); $typo_general_text = yit_typo_option_to_css(get_option('yith_login_typo_text')); $typo_submit_text = yit_typo_option_to_css(get_option('yith_login_typo_submit')); $custom_style = get_option('yith_login_custom_style'); ?> <?php if (yith_google_fonts_url() != '') { ?> <link rel="stylesheet" media="all" href="<?php echo yith_google_fonts_url(); ?> " /><?php } ?> <style type="text/css"> <?php if ($bg_color || $bg_image) { ?> body.login, html { background: <?php echo $bg_color; ?> <?php if ($bg_image) { ?> url('<?php echo $bg_image; ?> ') <?php echo $bg_repeat; ?> <?php echo $bg_position; ?> <?php echo $bg_attachment; } ?> ; } <?php } ?> <?php if ($container_width) { ?> #login { width: <?php echo $container_width; ?> px; } <?php } ?> <?php if ($logo_img) { ?> .login h1 a { background-image: url('<?php echo $logo_img; ?> '); <?php if ($logo_color) { ?> background-color: <?php echo $logo_color; ?> ;<?php } ?> background-size: <?php echo $logo_width; ?> px <?php echo $logo_height; ?> px; width: 100%; height: <?php echo $logo_height; ?> px; max-width: 100%; } <?php } ?> .mobile #login h1 a { width: 100% } .mobile #login form, .mobile #login .message, .mobile #login_error { margin-left: auto } /* Typography */ .login form .input, .login input[type="text"] { <?php echo $typo_input_text; ?> background-color: <?php echo get_option('yith_login_color_input'); ?> ; border-color: <?php echo get_option('yith_login_border_input'); ?> ; } .login form .input:focus, .login input[type="text"]:focus { background-color: <?php echo get_option('yith_login_color_input_focus'); ?> ; border-color: <?php echo get_option('yith_login_border_input_focus'); ?> ; } .login form .forgetmenot label { <?php echo $typo_general_text; ?> } input#wp-submit { <?php echo $typo_submit_text; ?> background-color: <?php echo get_option('yith_login_submit_color'); ?> ; border-color: <?php echo get_option('yith_login_submit_border_color'); ?> ; } input#wp-submit:hover { color: <?php echo get_option('yith_login_typo_submit_hover'); ?> ; background-color: <?php echo get_option('yith_login_submit_color_hover'); ?> ; border-color: <?php echo get_option('yith_login_submit_border_color_hover'); ?> ; } <?php echo $custom_style; ?> </style> <!--[if lte IE 8]> <style type="text/css"> #rememberme { display: inline-block; } #rememberme + span { display: none } </style> <![endif]--> <?php }
/** * Generate template vars * * @return array * @since 1.0.0 * @access protected */ protected function _vars() { $vars = array('http_status' => get_option('yith_maintenance_http_status', 200), 'background' => array('color' => get_option('yith_maintenance_background_color'), 'image' => get_option('yith_maintenance_background_image'), 'repeat' => get_option('yith_maintenance_background_repeat'), 'position' => get_option('yith_maintenance_background_position'), 'attachment' => get_option('yith_maintenance_background_attachment')), 'color' => array('border_top' => get_option('yith_maintenance_border_top')), 'logo' => array('image' => get_option('yith_maintenance_logo_image'), 'tagline' => get_option('yith_maintenance_logo_tagline'), 'tagline_font' => yit_typo_option_to_css(get_option('yith_maintenance_logo_tagline_font'))), 'mascotte' => get_option('yith_maintenance_mascotte'), 'message' => get_option('yith_maintenance_message'), 'title_font' => yit_typo_option_to_css(get_option('yith_maintenance_title_font')), 'p_font' => yit_typo_option_to_css(get_option('yith_maintenance_paragraph_font')), 'newsletter' => array('enabled' => get_option('yith_maintenance_enable_newsletter_form') == 1, 'submit' => array('color' => get_option('yith_maintenance_newsletter_submit_background'), 'hover' => get_option('yith_maintenance_newsletter_submit_background_hover'), 'label' => get_option('yith_maintenance_newsletter_submit_label'), 'font' => yit_typo_option_to_css(get_option('yith_maintenance_newsletter_submit_font'))), 'form_action' => get_option('yith_maintenance_newsletter_action'), 'form_method' => get_option('yith_maintenance_newsletter_method'), 'email_label' => get_option('yith_maintenance_newsletter_email_label'), 'email_name' => get_option('yith_maintenance_newsletter_email_name'), 'email_font' => yit_typo_option_to_css(get_option('yith_maintenance_newsletter_email_font')), 'hidden_fields' => wp_parse_args(get_option('yith_maintenance_newsletter_hidden_fields'))), 'custom' => get_option('yith_maintenance_custom_style'), 'title' => get_option('yith_maintenance_newsletter_title'), 'socials' => array('facebook' => get_option('yith_maintenance_socials_facebook'), 'twitter' => get_option('yith_maintenance_socials_twitter'), 'gplus' => get_option('yith_maintenance_socials_gplus'), 'youtube' => get_option('yith_maintenance_socials_youtube'), 'rss' => get_option('yith_maintenance_socials_rss'), 'behance' => get_option('yith_maintenance_socials_behance'), 'dribble' => get_option('yith_maintenance_socials_dribble'), 'email' => get_option('yith_maintenance_socials_email'), 'flickr' => get_option('yith_maintenance_socials_flickr'), 'instagram' => get_option('yith_maintenance_socials_instagram'), 'linkedin' => get_option('yith_maintenance_socials_linkedin'), 'pinterest' => get_option('yith_maintenance_socials_pinterest'), 'skype' => get_option('yith_maintenance_socials_skype'), 'tumblr' => get_option('yith_maintenance_socials_tumblr'))); return $vars; }
/** * Generate template vars * * @return array * @since 1.0.0 * @access protected */ protected function _vars() { $countdown_date = yith_prelaunch_unixstamp(get_option('yith_prelaunch_to_date')); $vars = array('background' => array('color' => get_option('yith_prelaunch_background_color'), 'image' => get_option('yith_prelaunch_background_image'), 'repeat' => get_option('yith_prelaunch_background_repeat'), 'position' => get_option('yith_prelaunch_background_position'), 'attachment' => get_option('yith_prelaunch_background_attachment')), 'color' => array('border_top' => get_option('yith_prelaunch_border_top')), 'logo' => array('image' => get_option('yith_prelaunch_logo_image'), 'tagline' => get_option('yith_prelaunch_logo_tagline'), 'tagline_font' => yit_typo_option_to_css(get_option('yith_prelaunch_logo_tagline_font'))), 'mascotte' => get_option('yith_prelaunch_mascotte'), 'message' => get_option('yith_prelaunch_message'), 'title_font' => yit_typo_option_to_css(get_option('yith_prelaunch_title_font')), 'p_font' => yit_typo_option_to_css(get_option('yith_prelaunch_paragraph_font')), 'newsletter' => array('enabled' => get_option('yith_prelaunch_enable_newsletter_form') == 1, 'submit' => array('color' => get_option('yith_prelaunch_newsletter_submit_background'), 'hover' => get_option('yith_prelaunch_newsletter_submit_background_hover'), 'label' => get_option('yith_prelaunch_newsletter_submit_label'), 'font' => yit_typo_option_to_css(get_option('yith_prelaunch_newsletter_submit_font'))), 'form_action' => get_option('yith_prelaunch_newsletter_action'), 'form_method' => get_option('yith_prelaunch_newsletter_method'), 'email_label' => get_option('yith_prelaunch_newsletter_email_label'), 'email_name' => get_option('yith_prelaunch_newsletter_email_name'), 'email_font' => yit_typo_option_to_css(get_option('yith_prelaunch_newsletter_email_font')), 'hidden_fields' => array()), 'custom' => get_option('yith_prelaunch_custom_style'), 'title' => get_option('yith_prelaunch_newsletter_title'), 'socials' => array('facebook' => get_option('yith_prelaunch_socials_facebook'), 'twitter' => get_option('yith_prelaunch_socials_twitter'), 'gplus' => get_option('yith_prelaunch_socials_gplus'), 'youtube' => get_option('yith_prelaunch_socials_youtube'), 'rss' => get_option('yith_prelaunch_socials_rss'), 'behance' => get_option('yith_prelaunch_socials_behance'), 'dribble' => get_option('yith_prelaunch_socials_dribble'), 'email' => get_option('yith_prelaunch_socials_email'), 'flickr' => get_option('yith_prelaunch_socials_flickr'), 'instagram' => get_option('yith_prelaunch_socials_instagram'), 'linkedin' => get_option('yith_prelaunch_socials_linkedin'), 'pinterest' => get_option('yith_prelaunch_socials_pinterest'), 'skype' => get_option('yith_prelaunch_socials_skype'), 'tumblr' => get_option('yith_prelaunch_socials_tumblr')), 'countdown' => array('enabled' => get_option('yith_prelaunch_countdown_enable'), 'to' => $countdown_date - time(), 'days' => yith_countdown_days($countdown_date), 'hours' => yith_countdown_hours($countdown_date) - yith_countdown_days($countdown_date) * 24, 'minutes' => yith_countdown_minutes($countdown_date) - yith_countdown_hours($countdown_date) * 60, 'seconds' => yith_countdown_seconds($countdown_date) - yith_countdown_minutes($countdown_date) * 60, 'num_font' => yit_typo_option_to_css(get_option('yith_prelaunch_numbers_font')), 'label_font' => yit_typo_option_to_css(get_option('yith_prelaunch_labels_font')))); $hidden = get_option('yith_prelaunch_newsletter_hidden_fields'); $hidden_fields = explode('&', $hidden); foreach ($hidden_fields as $field) { list($key, $val) = explode('=', $field); $vars['newsletter']['hidden_fields'][$key] = $val; } return $vars; }
public function add_google_fonts() { /*DA SISTEMARE*/ $this->fonts = array('slogan_font' => yit_typo_option_to_css(get_option('yith_tcountdown_slogan_font')), 'bold_font' => yit_typo_option_to_css(get_option('yith_tcountdown_bold_font')), 'number_font' => yit_typo_option_to_css(get_option('yith_tcountdown_number_font')), 'message_font' => yit_typo_option_to_css(get_option('yith_tcountdown_message_font')), 'button_font' => yit_typo_option_to_css(get_option('yith_tcountdown_button_font'))); }
#prelaunch .countdown .num { <?php echo $countdown['num_font']; ?> } #prelaunch .countdown .label { <?php echo $countdown['label_font']; ?> } #prelaunch .countdown_message{ <?php echo yit_typo_option_to_css(get_option('yith_prelaunch_countdown_message_font')); ?> } #prelaunch .socials .social{ border-color: <?php echo get_option('yith_prelaunch_socials_icon_color'); ?> } #prelaunch .socials .social:hover{ border-color: <?php echo get_option('yith_prelaunch_socials_icon_color_hover'); ?> }