theme_location == 'primary' ){
$menu .= '' . esc_html( 'Get A Quote','builders-landing-page' ) . '';
}
return $menu;
}
function construction_landing_page_customizer_theme_info( $wp_customize ) {
$wp_customize->add_section( 'theme_info' , array(
'title' => __( 'Demo and Documentation' , 'builders-landing-page' ),
'priority' => 6,
));
$wp_customize->add_setting('theme_info_theme',array(
'default' => '',
'sanitize_callback' => 'wp_kses_post',
));
$theme_info = '';
$theme_info .= '' . __( 'here', 'builders-landing-page' ) . '
';
$theme_info .= '' . __( 'here', 'builders-landing-page' ) . '
';
$theme_info .= '' . __( 'here', 'builders-landing-page' ) . '
';
$theme_info .= '' . __( 'here', 'builders-landing-page' ) . '
';
$theme_info .= '' . __( 'here', 'builders-landing-page' ) . '
';
$wp_customize->add_control( new Construction_Landing_Page_Theme_Info( $wp_customize ,'theme_info_theme',array(
'section' => 'theme_info',
'description' => $theme_info
)));
}
function builders_landing_page_get_posts( $post_type = 'post', $slug = false ){
$args = array(
'posts_per_page' => -1,
'post_type' => $post_type,
'post_status' => 'publish',
'suppress_filters' => true
);
$posts_array = get_posts( $args );
// Initiate an empty array
$post_options = array();
$post_options[''] = __( 'Choose Post/Page', 'builders-landing-page' );
if ( ! empty( $posts_array ) ) {
foreach ( $posts_array as $posts ) {
if( $slug ){
$post_options[ $posts->post_title ] = $posts->post_title;
}else{
$post_options[ $posts->ID ] = $posts->post_title;
}
}
}
return $post_options;
wp_reset_postdata();
}
function construction_landing_page_get_section_header( $section_title ){
$header_query = new WP_Query( array(
'p' => $section_title,
'post_type' => 'page'
));
if( $section_title && $header_query->have_posts() ){
while( $header_query->have_posts() ){ $header_query->the_post();
?>