Adding new widget in the end of post

Posted in: Newspaper
Post count: 27

Hello,
I am trying to add new widget to the end of post (Article) so i can put a newsletter form or latest article ! Any tip how to add this.

Thanks

Post count: 6600

Hi,

You can check if the widget can be added using shortcode then use the do_shortcode() function to echo it into the posts template you want to display it.
Should look something like this: http://screencast.com/t/XE7lJ2FW

Thanks

Post count: 27

Thanks for your replay, i am trying to add a newsletter form, it can work by shorcode ! and i want also add latest stories with “module 4” How i can do that, or how i can create a widget placement with php code in the template, i am familiar with Drupal, its easy to do it ! but with wordpress, i have no idea ! can you guide me please, i am trying to launch something similar to upworthy viralnova, in the end of article you may find a newsletter form and placement to add advertising or widget ! I can use some plugin like quick adsense to add php code, but i don’t know how to call a widget created by the theme like “Latest stories”.

Post count: 6600

Hi,

You can use the same method I have suggested above. Here are the steps:

1. Use the page builder to create and customize block 5(which is made using module 4) to show the latest articles from all categories: http://screencast.com/t/UmiKiMHW
2. after you added and edited the block switch to classic mode: http://screencast.com/t/oNsv2jvf5po and get the shortcode for the block: http://screencast.com/t/J88Sz3HwG
3. You can add the block using the do_shortcode() function to echo the block into the posts template you want to display it, like I pointed above: http://screencast.com/t/TxqQdtaD7
Will show up like this on post page: http://screencast.com/t/BDU8KNvdk

Thanks

Viewing 4 posts - 1 through 4 (of 4 total)
You must be logged in to reply to this topic.