Subject:*
<
Name/Email:*
<
Message Icon:*
<
Select*
<
Message:*
<



Click the Preview to see the content in action.
Options:*
<
Confirmation Code*
<
7 + 8 = ?  
Input the result from the expression
Maximum attempts you can try: 10
*
<
     

Re: Header hack, why a hack?
by DaveHaviland on 2005/5/9 14:15:44

Thanks so much for your attention guys, I have a lot of ideas for xoops, and I hope to be able to contribute in any way that I can.
Re: Header hack, why a hack?
by Mithrandir on 2005/5/9 7:38:11

The change is mainly in kernel/blockinstance.php in the assignBlocks() method that is done more dynamic now.

However, to be able to set a new block position, you will need to both add it to the $sides array there as well as to the <select>s in modules/system/admin/blocksadmin.php and blockform.php.

I'll work a little more on it, adding more information about a block instance to what is assigned to Smarty.
Re: Header hack, why a hack?
by LazyBadger on 2005/5/9 4:00:49

Quote:

Mithrandir wrote:
However, what I have done just two minutes ago is a cleanup of the code so new block positions can be added simply by adding new entries to three places in kernel/block.php and the blocks administration files.

And it can be tested in nearest nightlies?! Can you say, what can be changed (diff -u fulfill my needs)?
Re: Header hack, why a hack?
by DaveHaviland on 2005/5/9 3:45:51

I love it, maybe in time for 2.1? - either way I have a related question;

this just assigns it to an array and makes it ..._up, or ..._down

if ( $block_arr[$i]->getVar('weight') < 10)

what would happen if I modified my template to use that statement loop for the upper, ie = <10, and the use another statement at the bottom for = >10 ?

I would think that would work, but I haven't tried it yet. - and I'm not a real pro with php at all, I just gather what the jist of the statement is.

edit - eh, but I see they modify the header.php file to get the if statement in there, could that be done on a theme level?

I don't know the theme.html context weill enough to include that - without just a <php statement, and that seems cluttered.
Re: Header hack, why a hack?
by Mithrandir on 2005/5/7 18:09:44

We've been hearing this suggestion a number of times now and I would like to stress that I am not against it, but the downside is that it will only be applicable for new themes.

However, what I have done just two minutes ago is a cleanup of the code so new block positions can be added simply by adding new entries to three places in kernel/block.php and the blocks administration files.

Can be improved along the way.

Who's Online

149 user(s) are online (127 user(s) are browsing Support Forums)


Members: 0


Guests: 149


more...

Donat-O-Meter

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

Latest GitHub Commits