Are you working on a website design in Irvine? Perhaps your website is dedicated to reviewing movies or other forms of media like video games. You need to make sure that you are not revealing any spoilers. Spoilers can ruin the fun of entertainment for users. In this case, you need to know how to show and hide text in your WordPress posts and pages. 

In some cases, you may want users to view hidden content when they click on a certain link on your website. This feature can be especially handy when you want to reveal a frequently asked questions section on one of your webpages. You may have seen FAQ pages on the internet that already make use of the toggle effect. These pages show the frequently asked questions but hide the answers with the effect.

In this article, we will discuss two different ways that you can show and hide text in WordPress with the toggle effect.

Before we begin,  it is important to note that WordPress does not have a built-in toggle effect.  Make sure that you first install and activate the Show-Hide/Collapse-Expand plugin. 

 

why-is-the-toggle-effect-important-to-web-design-irvine-Pinterest-Pin

 

Show Hide Text With a Shortcode

If you choose this way, you have to manually add a shortcode, or a code shortcut, in WordPress to show or hide text. 

If you want to easily add a shortcode in WordPress, all you need to do is click ‘Appearance’ on the sidebar, then ‘Widgets,’ and then paste your shortcode. You can save the changes and preview them. You will see a clickable ‘Show More’ link. This link will show the hidden text.

You do not have to have a plain link. Other alternatives are a button, icons, or even a custom CSS within the shortcode.

 

Show Hide Text with a Visual Editor

If you use the visual editor method, you must add the ‘Classic’ block in your WordPress content editor. All you need to do is click on the ‘Add New’ block button, then find and insert the ‘Classic’ block. A visual editor with formatting buttons will then appear.

In the toolbar, you will then click the ‘Collapse-Expand’ button which will reveal a popup labeled ‘Insert Collapse-Expand Shortcode’. This popup allows you to configure the shortcode parameters visually. You will be able to pick the link or button as well as the text to display for show and hide. 

Once you’ve configured the parameters, you need to click the ‘OK’ button to insert it into your WordPress post. After this step, you will be able to add the text that you want to hide between the shortcode start and end tags. Be sure to save your post or page and check your website to see the changes.

 

Conclusion

When it comes to developing your website design in Irvine, you need to make sure that you understand the ins and outs of WordPress. After reading this article, you now know the two ways of showing and hiding text in WordPress posts and pages with the toggle effect.