Table of Contents

Upgrade from v4.4.2 or below to v4.5.0 or above


Setting the new functionality


The first thing you need to do is to check and save the new options "watermark text for images" and "picture dimensions for category images". These options are available under Components→ Ads Factory →Settings → General Settings → Image Settings.




Manually change templates


If you upgrade from Ads Factory v4.4.2 or below to version v4.5.0 or above and choose NOT to overwrite templates, then you will have to do the following precise modifications for compatibility reasons.

replace:

{if $category_filter}


with:

{if !empty($category_filter)}


replace:

{include file="js/t_javascript_maps.tpl" googleMapX=`$user->googleMaps_x` googleMapY=`$user→googleMaps_y`}


with:

{include file="js/t_javascript_maps.tpl" googleMapX="`$user->googleMaps_x`" googleMapY="`$user->googleMaps_y`"}


replace:

{include file="js/t_javascript_maps.tpl" googleMapX=`$user->googleMaps_x` googleMapY=`$user->googleMaps_y`}


with:

{include file="js/t_javascript_maps.tpl" googleMapX="`$user->googleMaps_x`" googleMapY="`$user->googleMaps_y`"}


replace:

<a href="{$lists.cancel_form}" class="btn">{'COM_ADS_CANCEL'|t}</a>


with:

<input name="cancel" value="{'COM_ADS_CANCEL'|t}" class="btn" type="button" onclick="history.back();"/>


replace:

{if $terms}
    var must_accept_term= true;
{else}
    var must_accept_term= false;
{/if}
var ad_currency='{$ad->currency}';


with:

{if !empty($terms)}
    var must_accept_term= true;
{else}
    var must_accept_term= false;
{/if}
{if !empty($ad->currency)}
   var ad_currency='{$ad->currency}'; 
{else}
   var ad_currency='';
{/if}


replace:

{if $payment_items_header}


with:

{if !empty($payment_items_header)}


replace:

{include file="js/t_javascript_maps.tpl" googleMapX=`$googleMapX` googleMapY=`$googleMapY`}


with:

{include file="js/t_javascript_maps.tpl" googleMapX="`$googleMapX`" googleMapY="`$googleMapY`"}


replace:

<a href="{$ad->get('links.show_map')}" class="modal">{'COM_ADS_LOCATION_ON_MAP'|t}</a>


with:

<a href="{$ad->get('links.show_map')}" class="modal" rel="{literal}{handler: 'iframe', size: {x: 800, y: 600}}{/literal}">{'COM_ADS_LOCATION_ON_MAP'|t}</a>


delete line 11:

{starttab name="content-pane" id="tab3"}


delete line 13:

{endtab}


replace:

{include file="js/t_javascript_maps.tpl" googleMapX=`$googleMapX` googleMapY=`$googleMapY`}


with:

{include file="js/t_javascript_maps.tpl" googleMapX="`$googleMapX`" googleMapY="`$googleMapY`"}


replace:

{if ($googleMapX && $googleMapY)}


with:

{if !empty($googleMapX) && !empty($googleMapY)}


delete line 12:

{assign var=nr_items value=$items|@count}


components/com_adsfactory/templates-dist/default/t_showsearchresults_grid.tpl


to

components/com_adsfactory/templates/default/t_showsearchresults_grid.tpl


insert at line 2:

{if $categories[category]->image}
    <img class="cat_image" src="./media/com_adsfactory/images/resize_{$categories[category]->image}"/>
{/if}