Title: Odd Sidebar Question
Last modified: August 18, 2016

---

# Odd Sidebar Question

 *  [hardy24](https://wordpress.org/support/users/hardy24/)
 * (@hardy24)
 * [19 years, 4 months ago](https://wordpress.org/support/topic/odd-sidebar-question/)
 * Hi, odd question.
 * I need to put something, some content into the top of my sidebar, but it’s significantly
   wider than everything else in my sidebar, so I don’t want to simply increase 
   the width of the sidebar to accomodate it.
 * So what I want to do is to place it before the sidebar, at the top. Which i’m
   pretty sure I can do. My question comes when I get to thinking about the main
   content to the left of the sidebar. The posts beside the wider content need to
   have a smaller width to make room for it, but then posts below it should just
   be regular width.
 * As far as i’m aware there is no way to differ the width of the posts because 
   it’s just one command which gets and places the posts. No way to say get posts
   1 & 2 with this width, then posts 3 onwards with this width.
 * Anyone – any ideas are greatfully received

Viewing 1 replies (of 1 total)

 *  [wedgemccloud](https://wordpress.org/support/users/wedgemccloud/)
 * (@wedgemccloud)
 * [19 years, 4 months ago](https://wordpress.org/support/topic/odd-sidebar-question/#post-517010)
 * I can only speak figuratively as I know very little PHP, but you would probably
   use variables.
 * In your loop, you would increase a variable for your width by one for each post.
   Then, with each post, check that variable and if it’s less than three (posts 
   1 and 2) they would use one loop coding, otherwise (the ‘else’ case) they would
   use a second code (for the third post and onward).
 * The implementation is similar to alternating colors for comments, I think. It
   seems easy if you know how to code PHP, but I know little of variables so I can’t
   give you code right away. I would if I could, though.

Viewing 1 replies (of 1 total)

The topic ‘Odd Sidebar Question’ is closed to new replies.

## Tags

 * [width](https://wordpress.org/support/topic-tag/width/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 1 reply
 * 2 participants
 * Last reply from: [wedgemccloud](https://wordpress.org/support/users/wedgemccloud/)
 * Last activity: [19 years, 4 months ago](https://wordpress.org/support/topic/odd-sidebar-question/#post-517010)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
