' : '';
echo '
';
$menu = wp_nav_menu(array(
'theme_location' => 'nav-menu',
'menu' => 'main-menu',
'container' => 'div',
'container_class' => 'menu-{menu slug}-container',
'container_id' => '',
'menu_class' => 'menu',
'menu_id' => 777,
'echo' => FALSE,
'fallback_cb' => 'wp_page_menu',
'before' => '',
'after' => '',
'link_before' => '',
'link_after' => '',
'items_wrap' => '',
'depth' => 0,
'walker' => ''
));
$menu_name = 'nav-menu';
$locations = get_nav_menu_locations();
$menu_id = $locations[$menu_name];
$menu_object = wp_get_nav_menu_object($menu_id);
if ($menu_object !== FALSE) {
echo '' . $menu_object->name . '
';
} else {
echo '' . esc_html__('Menu', 'back-to-the-90s-free') . '
';
}
echo $menu;
echo '';
}
function back_to_the_90s_header_scripts() {
if ($GLOBALS['pagenow'] != 'wp-login.php' && !is_admin()) {
wp_register_script('back-to-the-90s-free-mpopup', get_template_directory_uri() . '/js/jquery.magnific-popup.min.js', array('jquery'));
wp_register_script('back-to-the-90s-free-scripts', get_template_directory_uri() . '/js/back-to-the-90s-free-scripts.js', array('jquery'));
wp_enqueue_script('jquery');
wp_enqueue_script('back-to-the-90s-free-mpopup');
wp_enqueue_script('back-to-the-90s-free-scripts');
}
}
function back_to_the_90s_styles() {
wp_register_style('back_to_the_90s-css', get_template_directory_uri() . '/style.css', array(), '1.0');
wp_register_style('back_to_the_90s-magnific-popup', get_template_directory_uri() . '/css/magnific-popup.css', array(), '1.0');
wp_enqueue_style('back_to_the_90s-css');
wp_enqueue_style('back_to_the_90s-magnific-popup');
}
function register_back_to_the_90s_menu() {
register_nav_menus(array(
'nav-menu' => esc_html('Main Menu', 'back-to-the-90s-free')
));
}
function back_to_the_90s_nav_menu_args($args = '') {
$args['container'] = FALSE;
return $args;
}
function back_to_the_90s_css_attributes_filter($var) {
return is_array($var) ? array() : '';
}
function back_to_the_90s_remove_category_rel_from_category_list($thelist) {
return str_replace('rel="category tag"', 'rel="tag"', $thelist);
}
function back_to_the_90s_remove_width_attribute($html) {
$html = preg_replace('/(width|height)="\d*"\s/', "", $html);
return $html;
}
if (function_exists('register_sidebar')) {
register_sidebar(array(
'name' => esc_html('Under the Menu Widget Area', 'back-to-the-90s-free'),
'description' => esc_html('Put widgets you want to see under the navigation here.', 'back-to-the-90s-free'),
'id' => 'widget-area-1',
'before_widget' => '',
'after_widget' => '
',
'before_title' => '',
'after_title' => '
'
));
register_sidebar(array(
'name' => esc_html('Right Side Widget Area', 'back-to-the-90s-free'),
'description' => esc_html('These widgets will be shown on the right side of the page.', 'back-to-the-90s-free'),
'id' => 'widget-area-2',
'before_widget' => '',
'after_widget' => '
',
'before_title' => '',
'after_title' => '
'
));
}
function back_to_the_90s_remove_recent_comments_style() {
global $wp_widget_factory;
if (isset($wp_widget_factory->widgets['WP_Widget_Recent_Comments'])) {
remove_action('wp_head', array(
$wp_widget_factory->widgets['WP_Widget_Recent_Comments'],
'recent_comments_style'
));
}
}
function back_to_the_90s_index($length) {
return 50;
}
function back_to_the_90s_custom_post($length) {
return 40;
}
function back_to_the_90s_excerpt() {
global $post;
$output = get_the_excerpt();
$output = apply_filters('wptexturize', $output);
$output = apply_filters('convert_chars', $output);
$output = '' . $output . '
';
echo $output;
}
function back_to_the_90s_blank_view_article($more) {
global $post;
return '... ' . esc_html__('Read More', 'back-to-the-90s-free') . '';
}
function back_to_the_90s_style_remove($tag) {
return preg_replace('~\s+type=["\'][^"\']++["\']~', '', $tag);
}
function back_to_the_90s_remove_thumbnail_dimensions($html) {
$html = preg_replace('/(width|height)=\"\d*\"\s/', '', $html);
return $html;
}
function back_to_the_90s_gravatar($avatar_defaults) {
$myavatar = get_template_directory_uri() . '/img/gravatar.jpg';
$avatar_defaults[$myavatar] = 'Custom Gravatar';
return $avatar_defaults;
}
function back_to_the_90s_enable_threaded_comments() {
if (!is_admin()) {
if (is_singular() AND comments_open() AND (get_option('thread_comments') == 1)) {
wp_enqueue_script('comment-reply');
}
}
}
function back_to_the_90scomments($comment, $args, $depth) {
$GLOBALS['comment'] = $comment;
extract($args, EXTR_SKIP);
if ('div' == $args['style']) {
$tag = 'div';
$add_below = 'comment';
} else {
$tag = 'li';
$add_below = 'div-comment';
}
?>
< id="comment-">
' . do_shortcode($content) . '';
}
function back_to_the_90s_shortcode_demo_2($atts, $content = null) {
return '' . $content . '
';
}
function back_to_the_90s_load_admin_style() {
wp_register_style('back-to-the-90s-free-admin-css', get_template_directory_uri() . '/css/back-to-the-90s-free-admin-style.css', FALSE, '1.0.0');
wp_enqueue_style('back-to-the-90s-free-admin-css');
wp_enqueue_script('back-to-the-90s-free-admin-scripts', get_template_directory_uri() . '/js/back-to-the-90s-free-admin.js');
}
function back_to_the_90s_get_gif1_url() {
$gif_url = get_option('back_to_the_90s_gif1_alt_location');
if (empty($gif_url)) {
$gif_url = esc_url(get_template_directory_uri()) . '/img/gifs/globe.gif';
}
return $gif_url;
}
function back_to_the_90s_print_gif1_if_enabled() {
if (get_option('back_to_the_90s_display_gifs') == 1) {
echo '
';
}
}
function back_to_the_90s_print_gif2_if_enabled() {
if (get_option('back_to_the_90s_display_gifs') == 1) {
echo '
';
}
}
function back_to_the_90s_print_gif3_if_enabled() {
if (get_option('back_to_the_90s_display_gifs') == 1) {
echo '
';
}
}
function back_to_the_90s_return_gif1_if_enabled() {
if (get_option('back_to_the_90s_display_gifs') == 1) {
return '
';
}
return NULL;
}
function back_to_the_90s_return_gif2_if_enabled() {
if (get_option('back_to_the_90s_display_gifs') == 1) {
return '
';
}
return NULL;
}
function back_to_the_90s_prefix_remove_css_section($wp_customize) {
$wp_customize->remove_section('custom_css');
}
function back_to_the_90s_get_the_title($title) {
if (is_front_page()) {
return get_bloginfo('name');
}
global $post;
return $post->post_title;
}
function back_to_the_90s_free_premium_dismiss() {
set_transient('back-to-the-90s-free-premium-dismiss', TRUE, 60*60*24);
wp_die();
}