• Resolved El Pablo

    (@el-pablo)


    I have created 3 widget area’s in my footer in my functions.php file. In the first widget area, I have put and image widget + a text widget. In the second and the third widget, I have put a text widget. On the frontend however, I see 4 columns. Why is that? What is wrong with my code?

    My code: https://prnt.sc/p0qzc2
    In the backend: https://prnt.sc/p0r09p

    The page I need help with: [log in to see the link]

Viewing 5 replies - 1 through 5 (of 5 total)
  • Moderator Steven Stern (sterndata)

    (@sterndata)

    Volunteer Forum Moderator

    I see 4 widget areas.

    See https://i.imgur.com/oLdum9m.png

    Please show your code. Does your theme already have one footer widget?

    Steve’s image does not show 4 widget areas. It shows four widgets. But they don’t seem to match what the code for registering the widget areas would output.
    Is the linked site using the code that is shown?

    Widgets would be next to each other because of their styling. They could be limited in width and floating, or be inline-block.
    Typically the markup for the widget areas is slightly different, to distinguish one from the other. Using IDs for styling is often a hassle for the user (child theme or user CSS) because of its specificity, so unique classes in the markup are better.

    Thread Starter El Pablo

    (@el-pablo)

    Hi guys, like I already mentioned in my initial message, this is the code to create the widget areas: https://prnt.sc/p0qzc2. And like you see on this screenshot (https://prnt.sc/p0r09p), the widget areas are properly disposed in the backend as well.

    So, @joyously , if I understand you well, I need to make unique classes for every widget area?

    Moderator Steven Stern (sterndata)

    (@sterndata)

    Volunteer Forum Moderator

    So if they appear next to each other, giving 4 across, then it’s just a matter of CSS. Giving them different classes makes it easier to target individual sidebar areas.

    Thread Starter El Pablo

    (@el-pablo)

    It is no matter of css, but more a matter of html. To solve my problem I put a container around each ‘dynamic sidebar’: https://prnt.sc/p1jndo

Viewing 5 replies - 1 through 5 (of 5 total)

The topic ‘Creating widget area’s’ is closed to new replies.