Fork me on GitHub

Search

Donat-O-Meter

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

Learn XOOPS Core

Local Support

Advertisement

XOOPS Code hosted on SourceForge

Cumulus Tag Cloud

- 2 2.5 2.6 3.0 4 6 2013 Abuse adslight Android AntiHarvesting AntiMalUser AntiSpam API Apple Battlefield billige Bootstrap Captcha cell cent chronolabs Clicks content CĂN demo docek download Dresses evden eve facebook Fat floor Food for free Gateway Google Guide herre Home Honeypot HP Human HỘ IP iPhone jQuery Language Law Legal List log Loss mobile module modules Monster new newbb news NHÀ online PARK phone PHP Prevention profile project Protector publisher Rapid RESIDENCE responsive review Rights rmcommon security Sentry site Smartphone Smoking Solution Spam Studio tags tdmcreate template The Theme themes web weight Wishcraft xoops Xortify

New Users

Registering user

# 137852

cricket21

Welcome to XOOPS!




Bottom   Previous Topic   Next Topic  |  Register To Post

(1) 2 3 4 ... 6 »


#1 Posted on: 2005/11/10 6:00 Xoops 2.0.13.2 hack to add centre blocks above and below content block.
Why do this?

At the moment XOOPS contains the following blocks:
* Left Block
* Right Block
* Center Block
* Center Left Block
* Center Right Block.

Depending on your theme, the center blocks display either above or below the content. If you want to display blocks above and below the content block then it is currently not possible.

What this core hack does is give you the following blocks:
* Left Block
* Right Block
* Center Block
* Center Left Block
* Center Right Block
* Center Down Block
* Center Down Left Block
* Center Down Right Block

There is only one caveat that I found so for with this hack and that is the inline notification options content has to changed to Block Style otherwise the Down blocks will display after the Notifications content.

I hope someone else finds this useful or it finds its way into the core.

Download the Diff Patch, Patched Files, and example default theme.

Resized Image

Resized Image

Resized Image

Top


Panther Xoops Modules
xTotal & Xoops Hosting
Digibusters.com
PSP
McNaz
Joined:
2003/4/21 6:36
Group:
Registered Users
Posts: 469
(Show More) (Show Less)


#2 Posted on: 2005/11/10 6:05 Re: Xoops 2.0.13.2 hack to add centre blocks above and below content block.
Nice hack! I've wanted something like this for a VERY long time. IMHO, this would be an excellent addition to the Core.

Have you done any testing of this on 2.2.x?

Best Regards,

James

Top


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.
JMorris
Joined:
2004/4/11 12:55
From 127.0.0.1
Group:
BANNED Users
Posts: 2557
(Show More) (Show Less)


#3 Posted on: 2005/11/10 6:09 Re: Xoops 2.0.13.2 hack to add centre blocks above and below content block.
Very clever work indeed!

Have you looked into doing this for 2.2.3 yet?

Top

davidl2
Joined:
2003/5/25 20:19
Group:
BANNED Users
Posts: 4801
(Show More) (Show Less)


#4 Posted on: 2005/11/10 6:17 Re: Xoops 2.0.13.2 hack to add centre blocks above and below content block.
Hi JMorris and DavidL.

Thanks for the feedback. I must admit that I still haven't dived into XOOPS 2.2.x yet but I am sure I would be able to do a similar hack there.

Cheers.

McNaz.

Top


Panther Xoops Modules
xTotal & Xoops Hosting
Digibusters.com
PSP
McNaz
Joined:
2003/4/21 6:36
Group:
Registered Users
Posts: 469
(Show More) (Show Less)


#5 Posted on: 2005/11/10 8:38 Re: Xoops 2.0.13.2 hack to add centre blocks above and below content block.
this is a cool hack, thanks so much!

cheers

Top


Not right now; I am busy screwing up my site!


Dream Catcher Dezines
Mind Health ...
tjnemez
Joined:
2003/9/21 12:05
From Manitoba
Group:
Registered Users
Posts: 1539
(Show More) (Show Less)


#6 Posted on: 2005/11/10 9:38 Re: Xoops 2.0.13.2 hack to add centre blocks above and below content block.
Ham, I should have done what you did now McNaz, i.e. to post a link to a package with the hacked files, when I did mention it here before (the hack for extra blocks in theme)
(http://www.xoops.org/modules/newbb/vi ... id=185720#forumpost185720)

and here the block admin area:
Resized Image

As it seems it's it - just those 3 files + the language file. But it's only the way the block system on 2.0.x does it, still haven't tried to achieve it on 2.2.x. Wish you have time for it cause it's a really worth hack!

and sorry all for the stretch because of long link

Top

TottoBG
Joined:
2005/8/18 2:43
From Sofia, Bulgaria
Group:
Registered Users
Posts: 111
(Show More) (Show Less)


#7 Posted on: 2005/11/11 5:15 Re: Xoops 2.0.13.2 hack to add centre blocks above and below content block.
I've managed to hack the XOOPS 2.2.3 final core files to produce the same results. It was easier to do in XOOPS 2.2.3

Get the modified files HERE.

Please note that you have to modify your theme.html to take advantage of the new blocks. I've modified the original default theme (renamed blocks) to demonstrate how this is done.

Cheers.

McNaz.

Top


Panther Xoops Modules
xTotal & Xoops Hosting
Digibusters.com
PSP
McNaz
Joined:
2003/4/21 6:36
Group:
Registered Users
Posts: 469
(Show More) (Show Less)


#8 Posted on: 2005/11/11 16:02 Re: Xoops 2.0.13.2 hack to add centre blocks above and below content block.
Thanks again McNaz! In my opinion it's a really usable hack cause giving XOOPS admins more power in ordering site content which in many cases comes needed. I've just inherited this hack on the site I'm administrating and then looked for it deeply to reproduce it on a local testing site. Sure your hack on 2.2.3 will be usable to me too for upgrading some day or for needed new sites And to many other xoopsers too..

Top

TottoBG
Joined:
2005/8/18 2:43
From Sofia, Bulgaria
Group:
Registered Users
Posts: 111
(Show More) (Show Less)


#9 Posted on: 2005/11/11 16:24 Re: Xoops 2.0.13.2 hack to add centre blocks above and below content block.
Quote:
I hope someone else finds this useful or it finds its way into the core.


I'll look at it, but if it's as good as it looks it will soon...

Thanks a lot

skalpa.>

Top


Any intelligent fool can make things bigger, and more complex. It takes a touch of genius, a lot of courage, to move in the opposite direction.
Two things are infinite: the universe and human stupidity; and I'm not sure about the 1st one (A.Einstein)
skalpa
Joined:
2003/4/15 22:46
From City of lights
Group:
Registered Users
Posts: 250
(Show More) (Show Less)


#10 Posted on: 2005/11/11 17:40 Re: Xoops 2.0.13.2 hack to add centre blocks above and below content block.
There is nothing really talking against adding more block positions - except that no themes will support these positions.

This means that the no. 1 question asked in the forums - if we add more block positions - will be "Why won't my [block position] blocks show up???"

We could even make it dynamic - add new positions on the fly... but end up with the same problem.

With XOOPS 2.2.3 a lot more information about each block is available to the themes - its block id, its instance id and its weight. With the weight, it is possible to accomplish what you have done (in theme: If $block.weight < 10 show block before content, else after)

Adding new block positions is something I have wanted for a long time, but we will need some "fallback" measure for a theme to broadcast which positions it has available and perhaps let it define a default block position where all the blocks that are positioned on positions not in the theme will be put.

All in all it is somewhat more than just tinkering with the possible block positions (big thumbs up for the work done so far, though - it's just that it ain't for beginners)

Top


"When you can flatten entire cities at a whim, a tendency towards quiet reflection and seeing-things-from-the-other-fellow's-point-of-view is seldom necessary."

Cusix Software
Mithrandir
Joined:
2003/6/21 11:37
From Copenhagen, Denmark
Group:
Registered Users
Posts: 6094
(Show More) (Show Less)




(1) 2 3 4 ... 6 »



You can view topic.
You cannot start a new topic.
You cannot reply to posts.
You cannot edit your posts.
You cannot delete your posts.
You cannot add new polls.
You can vote in polls.
You cannot attach files to posts.
You cannot post without approval.
You cannot use topic type.
You cannot use HTML syntax.
You cannot use signature.
You cannot create pdf.
You cannot get print page.

[Advanced Search]