1

We've published around 200+ pages on our WordPress site and I want to add an iframe to the bottom of selected pages, or every page.

For the sake of time, is there a quick or easy way to do this job with some plugin or trick?

1

Depending on theme you are using there might be hooks available to output content at specific point. There is no generic convention for them, however.

The most general approach to modifying the default output of page would be modifying (or introducing) page.php template. If your base theme is upstream (not developed for specific site) and receives updates you would need to create Child Theme to not lose changes during update process.

0

Finally got solution, I used a wp plugin Bottom of every post

plugin gives us freedom to post custom text on every post

But i managed to change plugin code to work only on pages instead of post.

In the plugin Line no. 27 File name : bottom-of-every-post/bottom_of_every_post.php

code was

if( !is_page( ) && file_exists( $fileName )){

I changed to

if( is_page( ) && file_exists( $fileName )){

It worked on pages instead of posts.

0

If you have the ability to edit your theme files, then Rarst's solution is the proper route to take. However, if you do not have the ability or are unsure how to properly edit a theme file, I have created a plugin here that will allow you to add content to the top or bottom of all your posts, pages, or both.

This plugin gives you the ability to select which post type (including custom post types) you want the content to display on, which in Sharma's case, would have saved him from having to edit the plugin files.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.