1
Northern
defining blocks
  • 2007/3/14 2:01

  • Northern

  • Just can't stay away

  • Posts: 420

  • Since: 2004/12/26


what defines the list of modules to go from top to bottom and not from left to right or right to left?

Instead of having the left or right block showing the list of blocks going down, what would it take to make then go sideways?

Just a thought.

2
JMorris
Re: defining blocks
  • 2007/3/14 2:26

  • JMorris

  • XOOPS is my life!

  • Posts: 2722

  • Since: 2004/4/11


I'm not entirely sure I understand what you are meaning.

I think you are saying, "What makes blocks display in a top to bottom order, versus a left to right order on my site?".

If I understood you correctly, the answer is the XHTML and CSS of your theme.

Most themes are structured so that blocks will flow down. You order them by assigning weight in the Blocks admin. However, if you want your blocks to flow left to right, you're going to have 2 options. The easy (read lazy) way, or the right way.

The easy way is to use a table and do an if loop on the table cells. While this is the easiest to do, it is ugly and it is not even remotely what W3C standards specify, so I don't recommend it.

The hard, but proper way would be to do a div loop where the divs have a fixed width. You will be limited in the number of divs by the width of the browsing user's screen. Any divs that extend beyond will automatically start a new row. This will take some tinkering in your CSS to get it right, but it is doable.

If I've missed the mark, let me know and I'll try again.

HTH.

James
Insanity can be defined as "doing the same thing over and over and expecting different results."

Stupidity is not a crime. Therefore, you are free to go.

3
Northern
Re: defining blocks
  • 2007/3/14 2:34

  • Northern

  • Just can't stay away

  • Posts: 420

  • Since: 2004/12/26


You hit the nail on the head.

Is there a place you know of that I could learn this from?

Im making a new theme and this is going to be part of it, it was a last min, brain fart, but non the less, it would make for a unique theme thats up to date.

4
JMorris
Re: defining blocks
  • 2007/3/14 2:44

  • JMorris

  • XOOPS is my life!

  • Posts: 2722

  • Since: 2004/4/11


Quote:

Northern wrote:
You hit the nail on the head.

Is there a place you know of that I could learn this from?

Im making a new theme and this is going to be part of it, it was a last min, brain fart, but non the less, it would make for a unique theme thats up to date.


Well, unfortunately, there isn't an example of a XOOPS theme currently available that does this. However, there is a nice layout available fromhttp://csstinderbox.raykonline.com/ that uses a pure CSS table-less 3 over 4 column layout that would be an excellent starting point. I would also recommend makinghttp://www.w3schools.com/ one of your biggest resources. It is where I picked up a lot of what I've learned.

HTH.

James
Insanity can be defined as "doing the same thing over and over and expecting different results."

Stupidity is not a crime. Therefore, you are free to go.

Login

Who's Online

100 user(s) are online (70 user(s) are browsing Support Forums)


Members: 0


Guests: 100


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: May 31
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits