WordPress.org

Ready to get started?Download WordPress

Forums

Add sidebar using a shortcode (1 post)

  1. lukeyates1981
    Member
    Posted 3 years ago #

    Is there a way to include a sidebar in a page using a shortcode?

    Basically, I have a site with a sidebar which needs to have the same content on each page (2 image links - I am using a plugin for this) and the sidebar needs to appear at the top right of the page - all pretty simple and standard so far......

    ...but on the home page I need the sidebar to appear a little way down the page (some of the editable page content needs to appear ABOVE the sidebar).

    Basically, what I am thinking is if I use a page template to display the home page without a sidebar, I could then use a shortcode in the page content itself to place the sidebar wherever I need it (in this case, after the first couple of paragraphs and an image).

    Something like...

    [sidebar "primary-sidebar"]

    ...would be ideal!

    But... is this possible?!

    Thanks for any help :)

Topic Closed

This topic has been closed to new replies.

About this Topic