• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar

WP SITES

2784

Original Genesis Tutorials & 6000+ Guaranteed Code

Snippets

  • Consultation
  • Full Access
  • Log in

Toggle Read More Button To Show Full Content On Single Posts

This code enables you to add a Read More button which toggles the full content when clicked. When expanded the button text changes to Read Less and enables you to slide back up to only show the 1st paragraph.

Watch the following video demo to see exactly what the code does.

The code works on single posts, single static pages and single custom post types. It wraps the content in a div, excluding the 1st paragraph and adds the button after the last paragraph. Use this solution if you need this functionality on archive page types.

Installation

There’s 3 steps using the code in the members download folder :

Step 1 : From the download folder, upload the file named readmore.js to your child themes root directory.

Step 2 : From the download folder, copy & paste the PHP to the end of your child themes functions.php or template where you want to use the toggle function.

Step 3 : From the download folder, copy and paste the CSS to the end of your child themes style.css and clear caching.

Register or login to access the download folder :

Register for full access

Related Tutorials

  • Toggle Full Content On Archives Only When Content Contains More Than 1 Paragraph
  • Toggle Read More Excerpts To Show Full Content On Genesis Archives

Accordion & Toggle

Reader Interactions

Leave a Reply Cancel reply

You must be logged in to post a comment.

Primary Sidebar

Code written by Brad Dalton specialist for Genesis, WooCommerce & WordPress theme customization. Read More…

Advertise · WPEngine · Genesis · Log in

  • Access Problems
  • Account Details
  • Consulting
  • Tags