publishing issues remain

This commit is contained in:
Chris Punches
2021-01-12 18:21:22 -05:00
parent dfa8ad0b48
commit 00c1b4d7d4
13 changed files with 172 additions and 63 deletions

101
functions.php Executable file → Normal file
View File

@@ -22,6 +22,8 @@ add_action( 'admin_menu', 'example_customizer_menu' );
/**
* Adds the individual sections, settings, and controls to the theme customizer
*/
function copyright_notice( $wp_customize ) {
$wp_customize->add_section(
'Intellectual Property',
@@ -69,7 +71,7 @@ function sidebar_setup( $wp_customize ) {
$wp_customize->add_setting( 'news_feed', array( 'default' => 'http://news.silogroup.org' ) );
$wp_customize->add_setting( 'github_url', array( 'default' => 'https://github.com/cmpunches' ) );
$wp_customize->add_setting( 'linkedin_url', array( 'default' => 'https://www.linkedin.com/in/cmpunches' ) );
$wp_customize->add_setting( 'email_address', array( 'default' => 'punches.chris@gmail.com' ) );
$wp_customize->add_setting( 'email_address', array( 'default' => 'chris.punches@silogroup.org' ) );
$wp_customize->add_setting( 'bio_logo', array() );
$wp_customize->add_control( 'organization_name_textbox', array('label' => 'Organization Name', 'section' => $section_name, 'type' => 'text' ));
@@ -97,6 +99,38 @@ function sidebar_setup( $wp_customize ) {
}
add_action( 'customize_register', 'sidebar_setup' );
function art_ops( $wp_customize ) {
$section_name = 'Art Ops';
$wp_customize->add_section(
$section_name,
array(
'title' => $section_name,
'description' => 'Article Options',
'priority' => 32
)
);
$wp_customize->add_setting( 'article_shows_date', array() );
$wp_customize->add_control( new WP_Customize_Theme_Control( $wp_customize,
'Enable Date',
array(
'label' => __('Show Article Date', 'enable_date'),
'section' => $section_name,
'type' => 'checkbox',
'std' => '1',
'settings' => 'article_shows_date'
)
)
);
print("art_ops is executing");
}
add_action( 'customize_register', 'art_ops');
function titles_setup( $wp_customize ) {
$section_name = "Titles Theming";
@@ -110,27 +144,41 @@ function titles_setup( $wp_customize ) {
);
$wp_customize->add_setting( 'Title Color', array() );
$wp_customize->add_setting( 'Enable Title Shadow', array() );
$wp_customize->add_setting( 'Title Shadow Color', array() );
$wp_customize->add_setting( 'Subtitle Color', array() );
$wp_customize->add_setting( 'Enable Subtitle Shadow', array() );
$wp_customize->add_setting( 'Subtitle Shadow Color', array() );
$wp_customize->add_setting( 'Footer Color', array() );
$wp_customize->add_setting( 'Enable Footer Shadow', array() );
$wp_customize->add_setting( 'Footer Shadow Color', array() );
$wp_customize->add_control( new WP_Customize_Color_Control( $wp_customize,
'Title Color',
array(
'label' => __('Title Color', 'Antikythera' ),
'label' => __('Title Color', 'title_color_s' ),
'section' => $section_name,
'settings' => 'Title Color',
) ) );
$wp_customize->add_control( new WP_Customize_Theme_Control( $wp_customize,
'Enable Title Shadow',
array(
'label' => __('Enable Title Shadow', 'enable_title_shadow'),
'section' => $section_name,
'type' => 'checkbox',
'std' => '1'
)
)
);
$wp_customize->add_control( new WP_Customize_Color_Control( $wp_customize,
'Title Shadow Color',
array(
'label' => __('Title Shadow Color', 'Antikythera' ),
'label' => __('Title Shadow Color', 'title_shadow_color' ),
'section' => $section_name,
'settings' => 'Title Shadow Color',
) ) );
@@ -138,15 +186,26 @@ function titles_setup( $wp_customize ) {
$wp_customize->add_control( new WP_Customize_Color_Control( $wp_customize,
'Subtitle Color',
array(
'label' => __('Subtitle Color', 'Antikythera' ),
'label' => __('Subtitle Color', 'subtitle_color' ),
'section' => $section_name,
'settings' => 'Subtitle Color',
) ) );
$wp_customize->add_control( new WP_Customize_Theme_Control( $wp_customize,
'Enable Subtitle Shadow',
array(
'label' => __('Enable Subtitle Shadow', 'enable_subtitle_shadow'),
'section' => $section_name,
'type' => 'checkbox',
'std' => '1'
)
)
);
$wp_customize->add_control( new WP_Customize_Color_Control( $wp_customize,
'Subtitle Shadow Color',
array(
'label' => __('Subtitle Shadow Color', 'Antikythera' ),
'label' => __('Subtitle Shadow Color', 'subtitle_shadow_color' ),
'section' => $section_name,
'settings' => 'Subtitle Shadow Color',
) ) );
@@ -154,53 +213,67 @@ function titles_setup( $wp_customize ) {
$wp_customize->add_control( new WP_Customize_Color_Control( $wp_customize,
'Footer Color',
array(
'label' => __('Footer Color', 'Antikythera' ),
'label' => __('Footer Color', 'footer_color' ),
'section' => $section_name,
'settings' => 'Footer Color',
) ) );
$wp_customize->add_control( new WP_Customize_Theme_Control( $wp_customize,
'Enable Footer Shadow',
array(
'label' => __('Enable Footer Shadow', 'enable_footer_shadow'),
'section' => $section_name,
'type' => 'checkbox',
'std' => '1'
)
)
);
$wp_customize->add_control( new WP_Customize_Color_Control( $wp_customize,
'Footer Shadow Color',
array(
'label' => __('Footer Shadow Color', 'Antikythera' ),
'label' => __('Footer Shadow Color', 'footer_shadow_color' ),
'section' => $section_name,
'settings' => 'Footer Shadow Color',
) ) );
}
add_action( 'customize_register', 'titles_setup' );
function custom_titles() {
$title_color = get_theme_mod( 'Title Color' );
$title_color_s = get_theme_mod( 'Title Shadow Color' );
$title_shadow_color = get_theme_mod( 'Title Shadow Color' );
$title_shadow_enabled = get_theme_mod( 'Enable Title Shadow' );
$subtitle_color = get_theme_mod( 'Subtitle Color' );
$subtitle_color_s = get_theme_mod( 'Subtitle Shadow Color' );
$subtitle_shadow_color = get_theme_mod( 'Subtitle Shadow Color' );
$subtitle_shadow_enabled = get_theme_mod( 'Enable Subtitle Shadow' );
$footer_color = get_theme_mod( 'Footer Color' );
$footer_color_s= get_theme_mod( 'Footer Shadow Color' );
$footer_shadow_color= get_theme_mod( 'Footer Shadow Color' );
$footer_shadow_enabled = get_theme_mod( 'Enable Footer Shadow' );
?>
<style type="text/css">
.header_title_logo {
color: <?php echo $title_color ?>;
text-shadow: 2px 2px 5px <?php echo $title_color_s ?>;
<?php if ($title_shadow_enabled) { ?> text-shadow: 2px 2px 5px <?php echo $title_shadow_color ?>;<?php }?>
}
.header_subtitle_logo {
color: <?php echo $subtitle_color; ?>;
text-shadow: 2px 2px 5px <?php echo $subtitle_color_s; ?>;
<?php if ($subtitle_shadow_enabled) { ?> text-shadow: 2px 2px 5px <?php echo $subtitle_shadow_color; ?>;<?php }?>
}
.legal {
font-size: 24px;
color: <?php echo $footer_color; ?>;
text-shadow: 2px 2px 5px <?php echo $footer_color_s; ?>;
<?php if ($subtitle_shadow_enabled) { ?> text-shadow: 2px 2px 5px <?php echo $footer_shadow_color; ?>;<?php }?>
}
</style>
<?php
}
add_action( 'wp_head', 'custom_titles' );
function register_my_menu() {