30.4.08

Another Joomla! wishlist

I am about to create another Joomla! hack. What I would like to have is to create a way to specify a template for each page that I am about to create.

An idea came to me to extend (yet again) joomla com_content component to include (at the backside) a way to "insert" another field, specifically a template field that will load the specific template or the default template if there is none specified.

Good luck for me on this "hack"

22.4.08

Joomla 1.0 :: Hack : styling individiual menu items

Yet again, a Joomla 1.0 Hack:

In file : joomlainstallation/modules/mod_mainmenu.php:

at around line 132, I added these:

$menu_class_add = preg_replace("/[^A-Za-z0-9]+/", "_", strtolower($mitem->name));
$txt = '<a href="'. $mitem->link .'" class="'. $menuclass . "-" . $menu_class_add .'" '. $id .'>'. $mitem->name .'</a>';

This will make your menu items' class be specific to what they contain. For example, your link's display reads: Link To Some Content. what will happen is that the class would read : somclass-link_to_some_content. From thereon, it is easier to specifically target this link as if it has an ID. It is up to you now if you have to modify your css.

Or you could add the $menu_class_add as an ID for the anchor, which, I haven't tried yet.


Joomla 1.0 :: Conditional mosMainBody()

After some research, I have found a way to "properly" call mosMainBody() in Joomla! 1.0.

In this code:

<?php if(!eregi( "no items", $GLOBALS['_MOS_OPTION']['buffer'] )) {mosMainBody();}?>


I am checking if "no items" occurs in the $GLOBALS['_MOS_OPTION']['buffer'] variable where the main body resides. If you check the function declaration for mosMainBody in $joomlainstallation/includes/frontend.php file, you can see that this function echoes the variable above. I could hack this one (yet again) to test before display. But I need a fast way of doing things. This may not be the cleanest way to do it, but hey, it works for me.

!!! I modified the code to reflect other languages as well.... This is the new code:

<?php if(!eregi( _EMPTY_BLOG, $GLOBALS['_MOS_OPTION']['buffer'] ) AND !mb_eregi( _EMPTY_BLOG, $GLOBALS['_MOS_OPTION']['buffer'] ) ) {mosMainBody();}?>

2.4.08

Got new email addresses!

Just got 2 new email addresses.

renz_salmingobreakaway at atheistabreakaway dot netbreakaway - email address says it all. Don't have to expound about it, well not yet at least, except that you have to take out some parts to be able to send email to that address. If you really are a person, then recognizing the pattern would not be that too difficult for you (winking smiley here).

renzsalmingo2008takeaway at gmailtakeaway dot comtakeaway - now why would I want a second gmail account? the first one I created was too formal, too "me" -ish. I guess this one would be not. I still open the old ones that I have though.

Anyway, have to continue working now. It's already wayyyy past your bedtime. Go get some sleep.

Gallery Joomla Component....

I am now creating yet another gallery component for joomla.

Unlike most galleries, this one will have built in scoring system where you can schedule when the voting will begin and then keep track of the votes. I did not use Joomla!'s internal poll system since it has some limitations that I cannot breach (as of now).

I hope to be done by Friday this week so I can upload a copy here.