Support » Theme: Simon WP Framework » Change Link Color

  • Hello, I’m building a WP theme and am making a home page. If you visit you will see box in the top left with a purple top. The content in that is the latest post, which I got using

    <?php if (have_posts()) : while (have_posts()) : the_post(); ?>
        // Fetch most recent posts, limit to 1
    		$latest_posts = get_posts( array(
    			'posts_per_page' => 1,
    		) );
        // get first and only item in array
    		$latest_post  = $latest_posts[0];
    	<h3><a href="<?php echo get_permalink( $latest_post->ID ); ?>"><?php echo $latest_post->post_title; ?></a></h3>
    	<?php if ( has_excerpt( $latest_post ) ) : ?>
    	<p><?php echo $latest_post->post_excerpt; ?></p>
    	<?php else : ?>
    	<?php echo strip_shortcodes(wp_trim_words( $latest_post->post_content, 50 )); // '250' is number of words ?>
    	<?php endif; ?>

    Now the title “Coming Soon” is green like every other link on the site, but I would like this one to be purple like the box?

    How would I do this

    Thanks in advance


  • The topic ‘Change Link Color’ is closed to new replies.