Welcome to the MetaMod and Chameleon Support Forums.

Before posting, please check out the FAQs.



Need extra help with your Joomla site? Consider paid Joomla support by the developer of Chameleon and MetaMod.


I'm dumber than anybody - getting the thing to go.

I'm dumber than anybody - getting the thing to go.

In the last few weeks, I've really started to appreciate how dumb I am. I've been more-or-less drafted into understanding Joomla as a job requirement; ordinarily, I'm just a guy who writes articles, not code.

Metamod Pro seems to be Exactly what I need to bring a Joomla site up to scratch, by allowing me to use the right and left module spaces for supporting content specific to each page. For example, I have a review of "Avatar" or something, and want a cast list in a right module position for the film on just that "Avatar" page.

Now - getting it to go is another story.

1) I create a custom HTML module containing content-specific text:

<p style="text-align: center;"><strong><img src="/joomla/images/stories/moorer.png" border="0" /></strong></p>
<p><strong>Release Date: </strong>2/09/2010</p>
<p>1. Abalone Sky<br /> 2. Goodbye to the Ground<br /> 3. Just Another Fool<br /> 4. The Broken Girl<br /> 5. Should I Be Concerned<br /> 6. When You Wake Up  Feeling Bad<br /> 7. Easy in the Summertime<br /> 8. Stars and I (Mama's  Song) <br /> 9. Still This Side of Gone<br /> 10. Like the Rain<br /> 11.  Sorrow (Don't Come Around)<br /> 12. It's Gonna Feel Good<br /> 13. Crows</p>

I name that module "Crows," after the album review in the content. The module number is 335.

2) I check the metamodule pro plug-in; there's nothing I can monkey with in there, so I leave it alone.

3) I get into the meta of the review page, and toss in some very specific keywords: "Moorer,Crows,LINK_335"

4) Now it gets ugly. Into a copy of metamodule, also named "Crows." Show Title, Enable, Top-Right placement, Public, No Menu placement. Start today.

5) I screwed up both the long and short versions of your recipe for module inclusion by keyword, so let's just show the short version:

$document =& JFactory::getDocument();
$content = $document->getMetaData('LINK_335');
$result = preg_match_all('#LINK_335');
if ($result > 0) {
  return $matches[1];

Save... check the page, and there's nothin' there. Pro did it's job; it doesn't open the right module as a placeholder. It just didn't do anything visible at all.

To see the non-thing, wander over to www.bobbankard.com, and click the allison moorer picture that runs through the slideshow that runs at the top.

I figure if I can get one page working, I can back-engineer the thing to fit it to all additional page builds. Could you treat me like the moron I am, and explain to me in non-coder's language how I can get this thing running? Thanks!

- Bob

Edited By: perigee
01-Mar-10 18:14:35

Beginner Modder
1 Posts
Administrator has disabled public posting

Re: I'm dumber than anybody - getting the thing to go.

Hi Bob,

the problem seems to be in the PHP rule. This command is definitely not going to do what you want it to do:

$result = preg_match_all('#LINK_335');

The recipe was:


$document =& JFactory::getDocument();

$content = $document->getMetaData('keywords');
$result = preg_match_all('#LINK_([0-9a-z_\-]+)(?:[^0-9a-z_\-]|$)#', $content, $matches);
if ($result > 0) {
  return $matches[1];

Then all you have to do is mention LINK_335 in your metatags, and you'll get module 335 showing up in the MetaMod's module position.


Stephen Brandon
MetaMod / Chameleon developer
If you use MetaMod or Chameleon, please post a rating and a review at the Joomla! Extensions Directory: Chameleon | MetaMod

3330 Posts
User info in posts
Administrator has disabled public posting

Board Info

Board Stats:
Total Topics:
Total Polls:
Total Posts:
Posts this week:
User Info:
Total Users:
Newest User:
Members Online:
Guests Online:

There are no members online

Forum Legend:

 New Sticky