WordPress.org

Ready to get started?Download WordPress

Forums

Widget Logic
[resolved] Widget not showing up on blog page (8 posts)

  1. number55
    Member
    Posted 1 year ago #

    I have my blog page set to a page that is not the home page. The blog page is id=11.
    I have tried these:
    is_page(11)
    is_page('news')
    and the widget will not show.

    Here is the site: http://dev.pemtool.com/news/

    What am I doing wrong?

    http://wordpress.org/extend/plugins/widget-logic/

  2. Ronnieinspain
    Member
    Posted 1 year ago #

    I have the same problem, widget logic is working fine on all pages of a site i'm working on with the exception of the blog page, also tried the following:

    is_page ( 1092 ) || is_page ( blog) || is_page ( 'blog' )
    is_page ( array ( 1092, blog, 'blog' ))
    is_page_template ( 'posts.php' )

    currently pulling my hair out, the only way i can get any widget to show on this page is with the HTML Javascript Adder Widget and selecting ALL PAGES.

    Currently running suffusion and the blog page is set to Page of Posts, not that changing it to the WP default makes any difference...

  3. Ronnieinspain
    Member
    Posted 1 year ago #

    To let everyone know the final solution was:

    is_single() || ( is_home() && ! is_page('home') )

    is_single() as i wanted to display on single posts as well as on the blogging page but not any other static pages.

    The rest seems to be due to some confusion in WP/Suffusion in regards to which page is actually the homepage. Tried all settings of Widget Logic options with no result before trying this. Hope it helps someone else.

  4. hectoralvaez
    Member
    Posted 1 year ago #

    Hi Ronnieinspain,

    I found the solution.

    Maybe you changed your home from the theme? I changed it and when I put:

    is_page(blog)

    doesn't works, but:

    is_home()

    It works!

    try it!
    LUCK!

  5. Ronnieinspain
    Member
    Posted 1 year ago #

    Hi Hectoralvaez!
    Yes, something like that is what happened :/
    Thanks for the answer though

  6. Jason Kemp
    Member
    Posted 1 year ago #

    @Ronnieinspain there is a concept of home page and front page which is sometimes important

    is_home()
    will show only on the homepage - so

    is_front_page()
    might be better in some cases

    FWIW statements this plugin uses conditional tags that you can look up over here. I don't believe it has anything to do with the plugin - it is mostly a syntax error.

    You should also close this as it looks very much that the topic is resolved.

    http://codex.wordpress.org/Conditional_Tags#The_Main_Page

  7. Ronnieinspain
    Member
    Posted 1 year ago #

    @Jason Kemp,

    Hi, yes this issue has been resolved so it can indeed be closed; thanks for your input!

  8. neillmcshea
    Member
    Posted 1 year ago #

    Thanks for all the great comments, however I'm still a little lost as to how this works. I too have the issue that one widget in particular is not showing up on the blog page.

    The widget in question needs to display on all pages, except for one. I have checked all the pages in the UI that needs to display this widget, and it works except for the Blog page, and I do need this widget on the blog page also.

    I have read through the posts above, but its still not very clear to me what I need to do/test to make this work on all pages (including http://www.mysitename.com/blog page) with the exception of one other page.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags