Forum Replies Created

Viewing 13 replies - 1 through 13 (of 13 total)
  • Thread Starter Gwen

    (@collegecheese)

    Ahhh thanks so much!
    The last one worked!
    🙂

    Thread Starter Gwen

    (@collegecheese)

    Ahh thank you!

    MY WEBSITE

    Thread Starter Gwen

    (@collegecheese)

    It worked!!! Thank you so much Bojan!!!
    🙂

    Thread Starter Gwen

    (@collegecheese)

    I tried both!

    Thread Starter Gwen

    (@collegecheese)

    Still isn’t working :\

    Thread Starter Gwen

    (@collegecheese)

    HERE:

    <?php
    /**
     * aThemes functions and definitions
     *
     * @package aThemes
     */
    
    if ( ! function_exists( 'athemes_setup' ) ) :
    /**
     * Sets up theme defaults and registers support for various WordPress features.
     *
     * Note that this function is hooked into the after_setup_theme hook, which runs
     * before the init hook. The init hook is too late for some features, such as indicating
     * support post thumbnails.
     */
    function athemes_setup() {
    
    	/**
    	 * Make theme available for translation
    	 * Translations can be filed in the /lang/ directory
    	 * If you're building a theme based on aThemes, use a find and replace
    	 * to change 'athemes' to the name of your theme in all the template files
    	 */
    	load_theme_textdomain( 'athemes', get_template_directory() . '/lang' );
    
    	/**
    	 * Add default posts and comments RSS feed links to head
    	 */
    	add_theme_support( 'automatic-feed-links' );
    
    	// Set the content width based on the theme's design and stylesheet.
    	global $content_width;
    	if ( ! isset( $content_width ) ) {
    		$content_width = 640; /* pixels */
    	}	
    
    	/**
    	 * Enable support for Post Thumbnails on posts and pages
    	 *
    	 * @link http://codex.wordpress.org/Function_Reference/add_theme_support#Post_Thumbnails
    	 */
    	add_theme_support( 'post-thumbnails' );
    	add_image_size( 'thumb-small', 50, 50, true );
    	add_image_size( 'thumb-medium', 300, 135, true );
    	add_image_size( 'thumb-featured', 640, 250, true );
    
    	/**
    	 * This theme uses wp_nav_menu() in one location.
    	 */
    	register_nav_menus( array(
    		'top' => __( 'Top Menu', 'athemes' ),
    		'main' => __( 'Main Menu', 'athemes' ),
    	) );
    }
    endif; // athemes_setup
    add_action( 'after_setup_theme', 'athemes_setup' );
    
    /**
     * Register widgetized area and update sidebar with default widgets
     */
    function athemes_widgets_init() {
    	register_sidebar( array(
    		'name'          => __( 'Sidebar', 'athemes' ),
    		'id'            => 'sidebar-1',
    		'before_widget' => '<aside id="%1$s" class="widget %2$s">',
    		'after_widget'  => '</aside>',
    		'before_title'  => '<h3 class="widget-title">',
    		'after_title'   => '</h3>',
    	) );
    	register_sidebar( array(
    		'name'          => __( 'Header', 'athemes' ),
    		'id'            => 'sidebar-2',
    		'before_widget' => '<div id="%1$s" class="widget %2$s">',
    		'after_widget'  => '</div>',
    		'before_title'  => '<h3 class="widget-title">',
    		'after_title'   => '</h3>',
    	) );
    	register_sidebar( array(
    		'name'          => __( 'Sub Footer 1', 'athemes' ),
    		'id'            => 'sidebar-3',
    		'before_widget' => '<div id="%1$s" class="widget %2$s">',
    		'after_widget'  => '</div>',
    		'before_title'  => '<h3 class="widget-title">',
    		'after_title'   => '</h3>',
    	) );
    	register_sidebar( array(
    		'name'          => __( 'Sub Footer 2', 'athemes' ),
    		'id'            => 'sidebar-4',
    		'before_widget' => '<div id="%1$s" class="widget %2$s">',
    		'after_widget'  => '</div>',
    		'before_title'  => '<h3 class="widget-title">',
    		'after_title'   => '</h3>',
    	) );
    	register_sidebar( array(
    		'name'          => __( 'Sub Footer 3', 'athemes' ),
    		'id'            => 'sidebar-5',
    		'before_widget' => '<div id="%1$s" class="widget %2$s">',
    		'after_widget'  => '</div>',
    		'before_title'  => '<h3 class="widget-title">',
    		'after_title'   => '</h3>',
    	) );
    	register_sidebar( array(
    		'name'          => __( 'Sub Footer 4', 'athemes' ),
    		'id'            => 'sidebar-6',
    		'before_widget' => '<div id="%1$s" class="widget %2$s">',
    		'after_widget'  => '</div>',
    		'before_title'  => '<h3 class="widget-title">',
    		'after_title'   => '</h3>',
    	) );
    }
    add_action( 'widgets_init', 'athemes_widgets_init' );
    
    /**
     * Count the number of footer sidebars to enable dynamic classes for the footer
     *
     * @since aThemes 1.0
     */
    function athemes_footer_sidebar_class() {
    	$count = 0;
    
    	if ( is_active_sidebar( 'sidebar-3' ) )
    		$count++;
    
    	if ( is_active_sidebar( 'sidebar-4' ) )
    		$count++;
    
    	if ( is_active_sidebar( 'sidebar-5' ) )
    		$count++;
    
    	if ( is_active_sidebar( 'sidebar-6' ) )
    		$count++;
    
    	$class = '';
    
    	switch ( $count ) {
    		case '1':
    			$class = 'container site-extra extra-one';
    			break;
    		case '2':
    			$class = 'container site-extra extra-two';
    			break;
    		case '3':
    			$class = 'container site-extra extra-three';
    			break;
    		case '4':
    			$class = 'container site-extra extra-four';
    			break;
    	}
    
    	if ( $class )
    		echo 'class="' . $class . '"';
    }
    
    /**
     * Enqueue scripts and styles
     */
    function athemes_scripts() {
    
    	//Load the fonts
    	$headings_font = esc_html(get_theme_mod('headings_fonts'));
    	$body_font = esc_html(get_theme_mod('body_fonts'));
    	if( $headings_font ) {
    		wp_enqueue_style( 'athemes-headings-fonts', '//fonts.googleapis.com/css?family='. $headings_font );
    	} else {
    		wp_enqueue_style( 'athemes-headings-fonts', '//fonts.googleapis.com/css?family=Oswald:300,400,700');
    	}
    	if( $body_font ) {
    		wp_enqueue_style( 'athemes-body-fonts', '//fonts.googleapis.com/css?family='. $body_font );
    	}
    
    	wp_enqueue_style( 'athemes-symbols', get_template_directory_uri() . '/css/athemes-symbols.css' );
    
    	wp_enqueue_style( 'athemes-bootstrap', get_template_directory_uri() . '/css/bootstrap.min.css' );
    	wp_enqueue_style( 'athemes-style', get_stylesheet_uri() );
    
    	wp_enqueue_script( 'athemes-bootstrap-js', get_template_directory_uri() . '/js/bootstrap.min.js', array( 'jquery' ) );
    	wp_enqueue_script( 'athemes-superfish', get_template_directory_uri() . '/js/superfish.js', array( 'jquery' ) );
    	wp_enqueue_script( 'athemes-supersubs', get_template_directory_uri() . '/js/supersubs.js', array( 'jquery' ) );
    	wp_enqueue_script( 'athemes-settings', get_template_directory_uri() . '/js/settings.js', array( 'jquery' ) );
    
    	if ( is_singular() && comments_open() && get_option( 'thread_comments' ) ) {
    		wp_enqueue_script( 'comment-reply' );
    	}
    }
    add_action( 'wp_enqueue_scripts', 'athemes_scripts' );
    
    /**
     * Load html5shiv
     */
    function athemes_html5shiv() {
        echo '<!--[if lt IE 9]>' . "\n";
        echo '<script src="' . esc_url( get_template_directory_uri() . '/js/html5shiv.js' ) . '"></script>' . "\n";
        echo '<![endif]-->' . "\n";
    }
    add_action( 'wp_head', 'athemes_html5shiv' );
    
    function se_athemes_auto_excerpt_more( $more ) {
    	return '';
    }
    add_filter( 'excerpt_more', 'se_athemes_auto_excerpt_more' );
    
    /**
     * Custom functions that act independently of the theme templates.
     */
    require get_template_directory() . '/inc/extras.php';
    
    /**
     * Custom template tags for this theme.
     */
    require get_template_directory() . '/inc/template-tags.php';
    
    /**
     * Add social links on user profile page.
     */
    require get_template_directory() . '/inc/user-profile.php';
    
    /**
     * Add custom widgets
     */
    require get_template_directory() . '/inc/custom-widgets.php';
    /**
     * Customizer additions.
     */
    require get_template_directory() . '/inc/customizer.php';
    /**
     * Dynamic styles
     */
    require get_template_directory() . '/styles.php';

    (you can see where I’ve added what Maruti suggested^).

    Thread Starter Gwen

    (@collegecheese)

    It’s definitely in the right file! But still not working?

    Thread Starter Gwen

    (@collegecheese)

    Is there a specific place where I should add it in the functions.php file?

    Thread Starter Gwen

    (@collegecheese)

    Hmmm didn’t work. Tried both methods. Do I need to erase anything from the functions.php file?

    Gwen

    (@collegecheese)

    #main-navigation .sf-menu > ul > li:after {
    	width: 6px;
    	float: left;
    	margin-top: 16px;
    	content: "";
    	display: block;
    	color: #ffffff;
    	font-size: 1.8em;
    	font-family: Arial, Helvetica, sans-serif;
    	}

    See where it says content^^ that’s where it is! 🙂

    Gwen

    (@collegecheese)

    Got to your stylesheet. Use command->f (or ctrl->f if you are on PC) and search for “/” or ‘/’ and just erase the slash in the parenthesis. Or you could replace it w/ something like | if you wanted.

    Pretty sure that’s how I did it!

    Thread Starter Gwen

    (@collegecheese)

    Thank you for your response Maruti!

    I’m using the excerpts for affiliate purpose so there is like nothing to actually continue reading. It’s kind of an OCD thing. Haha 🙂

    MY WEBSITE.

    Gwen

    (@collegecheese)

    How do I get rid of the “continue reading ->” link below the excerpt?

Viewing 13 replies - 1 through 13 (of 13 total)