Jump to content

  • You cannot start a new topic
  • You cannot reply to this topic

Searchanise Manual Upgrade Guide Rate Topic   * * * * * 1 votes

 
  • kmolchanov
  • CS-Cart team
  • Join Date: 06-May 11
  • 1313 posts

Posted 21 June 2012 - 10:34 AM #1

Good day,


The latest Searchanise version is included in CS-Cart 2.2.5, so Searchanise is upgraded automatically when you upgrade your CS-Cart installation.

However, it is possible to upgrade Searchanise in CS-Cart 2.2.4 to the latest version individually, without having to upgrade the whole CS-Cart installation.

In order to manually upgrade Searchanise add-on in CS-Cart 2.2.4 to the latest version you should go through the following steps:
  • Uninstall Searchanise via the admin panel (Administration -> Add-ons)
  • Remove the folder 'addons/searchanise' from your store installation root directory
  • Download the installation archive and extract the folder 'searchanise' into the folder 'addons' in you store installation root directory
  • Repeat steps 2 and 3 for the folders '/var/skins_repository/base/customer/addons/searchanise' and '/var/skins_repository/base/admin/addons/searchanise'
  • Open the file 'core/fn.catalog.php' in a text editor and make the following modifications:

    Replace the lines:

    default_params = array (
    	'get_icon' => false,
    	'get_detailed' => false,
    	'get_options' => true,
    	'get_discounts' => true,
    	'get_features' => false,
    	'get_extra' => false,
    	'get_for_one_product' => (!is_array(reset($products)))? true : false,
    	);
    with:

    $default_params = array (
    	'get_icon' => false,
    	'get_detailed' => false,
    	'get_options' => true,
    	'get_discounts' => true,
    	'get_features' => false,
    	'get_extra' => false,
    	'get_taxed_prices' => true,
    	'get_for_one_product' => (!is_array(reset($products)))? true : false,
    	);
    Replace the lines:

    if (AREA != 'A' && Registry::get('settings.Appearance.show_prices_taxed_clean') == 'Y' && $auth['tax_exempt'] != 'Y') {
    	fn_get_taxed_and_clean_prices($product, $auth);
    	}
    with:

    if ($params['get_taxed_prices'] == true && AREA != 'A' && Registry::get('settings.Appearance.show_prices_taxed_clean') == 'Y' && $auth['tax_exempt'] != 'Y') {
    	fn_get_taxed_and_clean_prices($product, $auth);
    	}
    Replace the lines:

    if (!empty($params['filter_id'])) {
    	$condition .= db_quote(" AND ?:product_filters.filter_id = ?i", $params['filter_id']);
    	}
    with:

    if (!empty($params['filter_id'])) {
    	$condition .= db_quote(" AND ?:product_filters.filter_id IN (?n)", (array)$params['filter_id']);
    	}
  • Open the file 'class.templater.php' and replace the following line:

    if (strpos($params['smarty_include_tpl_file'], 'addons/') === 0) {

    with:

    if (empty($params['smarty_include_vars']['skip_addon_check']) && strpos($params['smarty_include_tpl_file'], 'addons/') === 0) {
  • Open the file '/controllers/admin/addons.php' in a text editor and make the following modifications:

    Add:

    $section_opts[$section_name]['hidden'] = isset($section['hidden']);

    after the lines:

    $section_name = isset($section['name']) ? (string)$section['name'] : 'general';
    	$section_opts[$section_name]['separate'] = isset($section['separate']);
    Add:

    $fields[$section_name][$id]['skip_addon_check'] = (boolean)$item->skip_addon_check;

    after the line:

    $fields[$section_name][$id]['template'] = (string)$item->template;
  • Open the file '/skins/basic/admin/views/addons/update.tpl' in a text editor and make the following modifications:

    Replace the following line:

    <li class="cm-js" id="{$_addon}_{$section}"><a>{$lang.$section}</a></li>
    with:

    <li class="cm-js{if $section_opts.$section.hidden} hidden{/if}" id="{$_addon}_{$section}"><a>{$lang.$section}</a></li>
    Replace the following line:

    <div>{include file="addons/`$smarty.request.addon`/settings/`$data.template`"}</div>
    with:

    <div>{include file="addons/`$smarty.request.addon`/settings/`$data.template`" skip_addon_check=$data.skip_addon_check}</div>
  • To go the admin panel and install Searchanise (Administration -> Add-ons)
  • Enter the add-on settings by clicking on the add-on title and click Connect to Searchanise. Wait until the synchronization process is complete (this may take a while)
Switch to the customer area and check if the service works correctly. Enter several symbols in the search field to check the search suggestion functionality.

Troubleshooting

In case the search suggestion widget does not work correctly check whether the search input field has the correct id: "snize-input". If it does not have this id, edit the skin template and assign it manually. This may will be needed in case of a custom skin being used.

Konstantin Molchanov,
CS-Cart Architect Team
Suggest and vote for new features | Report a bug


 
  • Dreak
  • Junior Member
  • Authorized Reseller
  • Join Date: 06-Sep 10
  • 2 posts

Posted 21 June 2012 - 12:13 PM #2

Hy,

i've tried this update today and at the 10'th step it does not load completly, i've waited about 1 hour for about 300 products.
Firebug says: "private_key is not defined"

Any ideas?
Dragos Papatoiu
Web Programmer

 
  • Dreak
  • Junior Member
  • Authorized Reseller
  • Join Date: 06-Sep 10
  • 2 posts

Posted 21 June 2012 - 01:06 PM #3

sorry for the post above, after about 3 instals and unintals and after i'ved deleted the cache it worked... thanks
Dragos Papatoiu
Web Programmer

 
  • AmitP
  • Senior Member
  • Members
  • Join Date: 08-Feb 10
  • 510 posts

Posted 11 July 2012 - 02:57 PM #4

ignore.com
VPS 2.0GHz + 1GB RAM