WordPress.org

Forums

how to remove sidebar from blog pages (7 posts)

  1. souleye
    Member
    Posted 3 years ago #

    I'm working on a project in which client has sidebar only on two pages. I tried to use conditionals to make the sidebar appear on some pages and not on others. then I found a different template that doesn't use sidebar. I'm using that template for the blog page but when I post blogs on it, the sidebar appears. I don't know how to get rid of it. I tried to tweak the page.php file but to disastrous results, getting errors all over the place. any assistance with this issue will be appreciated. thanks.
    souleye

  2. esmi
    Forum Moderator
    Posted 3 years ago #

    Assuming your client's site is using a static front page, the main posts page will use the current theme's index.php template file automatically - irrespective of what page template you try to apply via Edit Page.

  3. souleye
    Member
    Posted 3 years ago #

    thank you for your reply. I'm assuming that there should be a way, using conditionals to show the sidebar if some conditions are met and hide it otherwise. I would like to be able to show the sidebar ideally only on two pages but it can show up on all of the pages. but on the blog pages, for esthetic reasons, I would like it remove so that listings flow.

  4. esmi
    Forum Moderator
    Posted 3 years ago #

    which I understand doesn't apply to pages

    Not strictly true. See this Codex entry.

    how do you remove that meta info from the blogs

    Assuming by "blogs", you mean Posts. you will need to edit the relevant template files in the theme and remove the references to date and, if necessary, categories & tags. So that's index.php, single.php, archive.php, category.php and tag.php (although your theme may not have all of those template files).

    At a slight tangent, what ecommerce plugin are you using?

  5. souleye
    Member
    Posted 3 years ago #

    we're not using ecommerce, which makes it even dicier. products are listed just for specification. though they're for sale, they're not sold on the website. I have looked at a few plugins, but none will allow to display images along the product listings. at a pinch I thought I could use an image gallery but the text that goes with the images is 3 to 5 paragraphs long.

  6. esmi
    Forum Moderator
    Posted 3 years ago #

    I'm biased as I help to develop & support it but have you had a look at http://wordpress.org/extend/plugins/eshop/ It just uses the WP core featured image functionality to place product images on Pages or Posts. It also has some product listing shortcodes that would allow you to list sub-Page products complete with an automated "read more" type link. and you can handle orders offline/manually using a the Cash/Bank pseudo gateways if needed.

  7. souleye
    Member
    Posted 3 years ago #

    that's the one that I first started looking at but it dumped menu items that I didn't need. too much complication. client sells 'green' servers. so the listings are just for his clients to read up on the specs of the machines. that's all. he doesn't have thousands of them, just a bunch. I modified the files that you referenced. the meta data is gone. that's at least one issue off the list. thank you. next is to make the sidebar go away from the posts page.

Topic Closed

This topic has been closed to new replies.

About this Topic