mojoBlog Itemid Over-riding Search Itemid

I’ve been working on a new website for Vermonters for a Clean Environment and came across an odd bug within the search bot for mojoBlog. Essentially, I wanted to add an Itemid to the search results from the default Joomla search module so that the results would not default to the home page’s Itemid. The new home page will have a large image on the top and some other “news” modules and the search results would get buried below the fold perhaps.

I’ve also added mojoBlog to the new site and discovered that if I used the “Set Itemid” feature in the Search module, the main menu tab for mojoBlog also became active along with whatever other Itemid I had selected.

setitemid.png

To fix this bug, I went into the mojo.searchbot.php file within /mambots/search and edited one line. Look for function botSearchwordpress. On the following line is a global declaration of variables and at the end of that line is one for Itemid. Remove the reference to Itemid — it’s simply not needed. Your new line should look like this:

global $mosConfig_sef, $mosConfig_absolute_path, $mosConfig_absolute_path, $my, $database, $mosConfig_offset;

That fixes the override of the specified Search Itemid.

NONE, NADA, ZIP, ZILCH

Why don't you pony up and be the first to add your comment?

Add your own comment...

You must be registered to leave a comment.

January 2009
Mo Tu We Th Fr Sa Su
« Dec    
 1234
567891011
12131415161718
19202122232425
262728293031  

Blogroll

Search

LinkedIn

View Drew Story's LinkedIn profileView Profile

Giving Back

We donate a portion of all of our sales to environmental causes.  Learn more about how we give back and use our work for a better world.

Our Clients

View Client List

Testimonials

“I worked with Drew on many projects. With our web solutions being custom designed to fit our client's needs, it required a project manager that was able to adapt and understand all facets of the internet and technology. Drew had these qualities and was able to communicate them to the client.”

- Peter Chao

CPI Solutions / eDistrict

 

Login






Lost Password?
No account yet? Register

Translate

Current Projects

- Improvements to Joomla Component - Advocacy 2.0
- New Joomla site for VCE.org
- A website for author Lee Green
- A website for MDH Skincare
- Updates to RestorativeJusticeNow.org

Site Summary

The Design Mission are web developers specializing in Open Source software, particularly Joomla, osCommerce, phpCollab and Gallery2. We can also create custom solutions upon request.

Other areas of expertise include search engine optimization, newsletter marketing, graphical user interface (GUI) design and information architecture.

The Design Mission's web design and development process will make the Internet work for you.