• Resolved alanft

    (@alanft)


    Just to announce that the current release of WL doesn’t work fully on 2.8. When you hit ‘Save’ in a widget the AJAX way, the widget comes back without the WL field. refresh the page and it’s there again (and the changes have saved??) – but it’s still teh suck.

    so I have updated the code to make it work with this new bit of 2.8, and it’s available as v 0.46 in the ‘development version’ on the versions page.

    If I don’t hear anything adverse about it (say if it breaks anything important in 2.7, or there’s something else new in 2.8 that i’ve missed) in the next couple of days, I will tag it up as an official update.

Viewing 4 replies - 16 through 19 (of 19 total)
  • Oh no, that will work but only if it is a single condition.

    I have other widgets that I don’t want to appear on several pages including the home page so I need to find another solution. This will not work:

    !is_page(array(‘front_page’,’contact’))

    and neither will this:

    !is_page(array(‘home’,’contact’))

    and neither will this:

    !is_page(array(‘page-name’,’contact’))

    All three of those stop the widget appearing on the Contact page but none of them stop the widget appearing on the Home page.

    I guess I need to address why WordPress can’t figure out which page is the home page and once it knows which is the home page, I can then use the ‘home’ tag.

    Anyone have any ideas?

    Thread Starter alanft

    (@alanft)

    a WP page chosen as your static front page needs the special condition is_front_page() as you worked out. if you want things to appear on that home/frontpage and another page you use

    is_front_page() || is_page(‘contact’)

    or if you want it to appear everywhere except that

    !(is_front_page() || is_page(‘contact’))

    warwell

    (@warwell)

    How can I make a statement so that the wdiget does NOT show on a certain page OR that page’s child pages? Thank you!

    Thread Starter alanft

    (@alanft)

    without testing it, try adapting the last example in the https://www.ads-software.com/extend/plugins/widget-logic/other_notes/ but add a ! (to make NOT). something like:

    global $post; return !(is_page(13) || ($post->post_parent=="13"));

Viewing 4 replies - 16 through 19 (of 19 total)
  • The topic ‘Widget Logic on 2.8’ is closed to new replies.