Conditionally Wrap Genesis Featured Posts Widget Title In Span Tags

This code snippet enables you to add a span class to the Genesis Featured Posts widget title. You can also add the span conditionally so its only added on specific pages or conditionals.

In this case, its only added on the front page.

Here’s the default HTML output showing the h3 tag :

You can see the span tag added in the following screenshot :

You could also wrap the widget title in span tags like this without removing or modifying the default HTML tags :

Register or login to access the code :

One response to “Conditionally Wrap Genesis Featured Posts Widget Title In Span Tags”

  1. Debbie Hastings Avatar
    Debbie Hastings

    AWESOME! Thanks!!

Was This Tutorial Helpful?

Free

$0

Access only to all free tutorials per month.



Monthly

$75

Access to 10 premium tutorials per month.


Tutorial Request


Includes code guarantee and coding support.

Yearly

$500

Access to 15 premium tutorials per month.


Monthly Tutorial Request


Includes code guarantee and priority coding support.