joomla_estate_agencyI recently had an email asking how I removed the ?task=search from the url of the joomla estate agency component.

I originally removed the ?task=search query string as it prevents people from emailing the url of a property to a friend. When the url is visited by another user it will show a session has ended message and direct you to a search page, and the friend will have no idea what you were trying to send them.

Here is the reply that I sent them.

Open up the file:

modules/mod_jea_search/tmpl/default.php

search for the line:

[code]<input type="hidden" name="task" value="search" />[/code]

and change it to this

[code]<!--<input type="hidden" name="task" value="search" />-->[/code]

That should sort out the module. The component search I think is in:

components/com_jea/controllers/properties.php

look for

[code]if( ( JRequest::getVar( 'task' ) != 'search' ) &&  ( isset( $_SESSION['jea_search'] ) ) ) {
unset( $_SESSION['jea_search'] );
}[/code]

and comment out like this:

[code]/*    if( ( JRequest::getVar( 'task' ) != 'search' ) &&  ( isset( $_SESSION['jea_search'] ) ) ) {
unset( $_SESSION['jea_search'] );
}
*/[/code]

If it doesn't work just uncomment everything to put it back to how it was.

These files change with each version so it depends which one you're using as to how the code will look.

 

 

Category: Joomla

Newsletter Signup

Latest Posts

Google+ Timeline Feed for your Website Google+ Timeline Feed for your Website 2012-05-11 - I was asked earlier today to create a Google+ widget for a website to replace a twitt... More detail
Run Facebook Messenger on Windows Vista Run Facebook Messenger on Windows Vista 2012-04-19 - Facebook has just released it's new messenger for windows but it only runs on Windo... More detail
Translate K2store Product Attributes with Joomfish Translate K2store Product Attributes with Joomfish 2011-11-03 - If you have a K2store and your site is in multiple languages, you might have found th... More detail
French Translations for K2store French Translations for K2store 2011-11-02 - I have been working recently with the K2 component/plugin K2store. As a simple sho... More detail
How I Upgraded to Joomla 1.7 How I Upgraded to Joomla 1.7 2011-09-25 - Inspired by Robert Vining over at www.joomstew.com and the fact that I am building mo... More detail

Twitter Stuff