Tagged: ,

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #320469

    Hello,

    I read this post: https://kriesi.at/support/topic/sidebarwidget-issues-2/

    because I want to place the contents of the ‘displayed everywhere’ widget above post and page widget data. However, it’s an older post and I cannot find the string that was mentioned to be deleted.

    Thanks

    Andrew

    #320920

    Hey awilson3rd!

    Thank you for using Enfold.

    Find this code on line 71 of sidebar.php:

    //global sidebar
            if (dynamic_sidebar('Displayed Everywhere')) : $default_sidebar = false; endif;
    

    Then go look for this code on line 44:

      if($custom_sidebar)
            {
                dynamic_sidebar($custom_sidebar);
                $default_sidebar = false;
            }

    Replace it with this code:

     //global sidebar
            if (dynamic_sidebar('Displayed Everywhere')) : $default_sidebar = false; endif;
    
            if($custom_sidebar)
            {
                dynamic_sidebar($custom_sidebar);
                $default_sidebar = false;
            }
    

    Cheers!
    Ismael

    #321041

    Thanks Ismael, I’ll give it a go.

    Andrew

    #321171

    Hi!

    Please try and let us know Andrew

    Best regards,
    Yigit

    #321250

    Hello,

    I’m not sure if I am doing this right? I have added this:

    //global sidebar
    if (dynamic_sidebar(‘Displayed Everywhere’)) : $default_sidebar = false; endif;

    if($custom_sidebar)
    {
    dynamic_sidebar($custom_sidebar);
    $default_sidebar = false;
    }

    But now the default does come first (which is what I want) then the custom sidebar but then the default again.

    To be honest I was a bit confused with Ismael’s reply:

    Find this code on line 71 of sidebar.php:

    //global sidebar
    if (dynamic_sidebar(‘Displayed Everywhere’)) : $default_sidebar = false; endif;

    What do I do when I find the above code?

    Thanks

    Andrew

    #321256

    Got it, I added the following to line 44

    //global sidebar
    if (dynamic_sidebar(‘Displayed Everywhere’)) : $default_sidebar = false; endif;

    if($custom_sidebar)
    {
    dynamic_sidebar($custom_sidebar);
    $default_sidebar = false;
    }

    Then deleted this on line 91:

    //global sidebar
    if (dynamic_sidebar(‘Displayed Everywhere’)) : $default_sidebar = false; endif;

    It works but is that correct?

    Thanks

    Andrew

Viewing 6 posts - 1 through 6 (of 6 total)
  • The topic ‘Sidebar Widgets’ is closed to new replies.