override.zip - Marius's patch implemented as a Class Override
Last week, I shared a system plugin called Override with examples of how to override Joomla! 1.6 Core Classes. I needed to identify options for overriding core code in Joomla! 1.6 for the Molajo distribution for those rare cases when Extensions don't quite get you there. I shared it hoping it might be useful to others.
Some may be following the discussion in the Bug Squad regarding the bug related to the Frontend Component metadata.xml file. Marius Van Rijnsoever reported that some 1.5 MVC Component Menu Items were not working in 1.6. During debugging, he uncovered a TODO note indicating that the metadata.xml file must still be reconnected following 1.6 revisions to the Menu System.
As is appropriate, Marius created a patch and posted issue on the tracker: [#24562] com_menu not looking for component xml file. Beat and Radek Suski have also reported this issue. As it turns out, even Hannes's Menu Item patch from June addressed this problem but was set aside by Andrew as not an appropriate solution.
Andrew agreed to review Marius's patch provided he had time this coming weekend at which time the patch will hopefully be applied to core. Unfortunately, Andrew also indicated his time availability is very low, so patience will be required.
To me, this is a good reason to look at Overrides. Overrides are seldom permanent. But, in cases like this, an override can be very helpful to buy everyone a little time. Developers can move forward migrating extensions. The project can review patches, as they are able.
I applied Marius's patch to an up-to-date Joomla! 1.6 (revision: 20433). Then, I placed that modified Menu Item class into the Override Plugin folder. To perform the override, I added the one line of code to my Override System Plugin in order to make certain the application uses Marius's fix instead of the core class:
function onAfterInitialise()As an aside, I think it's important to remember that there is nothing wrong with innovating solutions that don't necessarily color perfectly inside of the lines. A different way of thinking can create important innovation. Sometimes, that innovation winds up in core.
{
JLoader::register('MenusModelItem', dirname(__FILE__).'/item.php');
}
Comment by Robert Vining on January 25, 2011 at 7:41am You're so much more politically correct than I ever will be Amy... and that's why I love you! I was just about to engage in that debate on the bugsquad list when I saw a tweet about this post. Thanks for keeping me sane this morning!
Comment by Marius van Rijnsoever on January 26, 2011 at 8:09am Marius -
Yes, it's been disheartening. It's no secret that there is a lot of dysfunction. I have tried to help, but failed. I'm done. I hope they sort it out.
I like the comradary and collaboration building in our community of developers. You have been a hero to me for some time so it is an honor helping you in this small way. That's what community is all about. -sharing and supporting one another.
Keep up the professional approach. In the end, you will never regret holding true to your integrity.In doing so, you are a role model for others, too.
Thanks for your work, Marius.
Comment by Marius van Rijnsoever on January 26, 2011 at 11:05pm Hi Amy,
You are just an amazing inspiration to the whole community. Thanks to your inspiration many years ago, we decided to take GPL compatible approach rather than a quick and dirty hack. And now you have done the same for us just yesterday, with an approach that allows us to innovate without hacking the joomla core. Without you, we would not have been in the place we are now. I have an incredible amount of respect for the tireless work you do in making the whole Joomla community more enjoyable.
I have decided to take a chill-pill and refocus my efforts to where they are most useful. There is no point in getting my bloodpressure up when I can not have a positive effect or my efforts are not welcomed. It is sad to read that you "are done with it". But every ending has a new beginning and Molajo has an exciting future. Please let me know if there is anything I can do to help-out with the molajo project, I am at your service.
Marius
Definitely will want your involvement!
When I say "done with it" - I mean my approach of trying to help negotiate conversations or understandings with the project. I am no where close to be done with Joomla!. Just done with Joomla! drama. lol! It's time for everyone to grow up.
You are very kind and you just gave me a huge boost of energy to get after this day.
Once we get Molajo into an alpha state, our goal is to figure out how we plan to engage the developer community. It's been so hard to get involved -- we want Molajo to be "ours" -- in a wild dream sense - it could be a collaborative environment for community devs to manage our shared extensions -- to build consensus on what we want to propose for core -- to figure out how to strengthen our market - and so on. We want it open for participation based on what people do - not who they are or their titles or previous involvements or how well known they are. I know you can help us find how to do that.
Huge community. So much talent and passion. Tapping into that and figuring out how to improve how we communicate with one another and collaborate and advance our software. That's the goal of Molajo.
Comment
© 2012 Created by Amy Stephen.
You need to be a member of All Together, As A Whole to add comments!
Join All Together, As A Whole