PDA

View Full Version : Hot Picks


Luckyjj842
30-03-07, 21:48
I would like to have Hot Picks display products that are relevant to the overall site design instead of the random display.

Is this possible? and if so how can it be done?

My sites are:

lingerie2lust4 (http://www.lingerie2lust4.com)
New Bra (http://www.newbra.co.uk)

Thanks in advance.

amarath
31-03-07, 02:00
Hi,

In order to output particular category Hot Picks, you must include a parameter within your pages to default to your choice of category.

$oHotPicksParams->iCategoryId= x;

This must be included before each call of the hot picks template within your pages.

I hope this helps,

Thanks

Amo

Luckyjj842
31-03-07, 10:28
Hi,

In order to output particular category Hot Picks, you must include a parameter within your pages to default to your choice of category.

$oHotPicksParams->iCategoryId= x;

This must be included before each call of the hot picks template within your pages.

I hope this helps,

Thanks

Amo


Hi Amo,

Thanks for response. I am running Shop Window as a standalone package with my own headers etc. (In essence - your complete product).

I would like the Home Page/Index.php to display more relevant HOT PICKS. Which page is it that needs amending?

Thanks again
John

amarath
31-03-07, 11:16
Hi John,

Please edit your index.php page by including the parameter mentioned.

Also, to edit the number of Hot Picks displayed across all 4 primary pages used for Client Software, this thread may be useful to you:

http://www.shopwindowforum.com/showthread.php?t=35

I hope this is what your looking for.

Amo

Luckyjj842
01-04-07, 02:41
Hi John,

Please edit your index.php page by including the parameter mentioned.

I hope this is what your looking for.

Amo

Hi Amo,

I am still confused as to where to put additional info as above. Can you advise please. index.php is below

Thanks

John

<?php
/**
*
* ShopWindow Toolset
*
* Copyright (C) 2007 Digital Window Ltd.
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*
*/


require_once('global.inc.php');

include_once('status.php'); // detect any basic setup errors

// Force index to start from a specific category
$_GET['c']= 135;


require_once(HOME_PATH.DIRECTORY_SEPARATOR.'includ es'.DIRECTORY_SEPARATOR.'classes'.DIRECTORY_SEPARA TOR.'class.page_index.php');

require_once(HOME_PATH.DIRECTORY_SEPARATOR.'includ es'.DIRECTORY_SEPARATOR.'classes'.DIRECTORY_SEPARA TOR.'class.smarty_sw.php');


$oPage = new pageIndex();

$oSmarty= new Smarty_SW();


include_once(HOME_PATH.DIRECTORY_SEPARATOR.'includ es'.DIRECTORY_SEPARATOR.'elements'.DIRECTORY_SEPAR ATOR.'search_box.php');

include_once(HOME_PATH.DIRECTORY_SEPARATOR.'includ es'.DIRECTORY_SEPARATOR.'elements'.DIRECTORY_SEPAR ATOR.'hot_picks.php');

include_once(HOME_PATH.DIRECTORY_SEPARATOR.'includ es'.DIRECTORY_SEPARATOR.'elements'.DIRECTORY_SEPAR ATOR.'category_tree.php');


$oSmarty->display('index.tpl');

?>

gunneradt
01-04-07, 13:47
i wondered thast last night also and thought I'd wait for someone to ask the question.

amarath
02-04-07, 18:31
Hi Guys,

Apologies for my error on this, please go here:

http://www.shopwindowforum.com/showthread.php?t=54

Hope this helps,

Amo

arthomas
02-04-07, 20:10
Hi im still confused, its not clear from these posts on this thread how to actually catogrise hot picks could some one please clarify how it works????

# hot picks
$aHotPickParams = array("iLimit"=>15);

$oHotPicksParams->iCategoryId= Sports;

$this->oHotPick = $oClient->call('getHotPickProductList', $aHotPickParams);
}

http://www.sassussex.com/savershandbook/index.php

tried this but it doesnt work!

could someone point out what the problem is and how to correct it.

Thanks alot.

amarath
02-04-07, 20:35
Hi,

Sorry for not being clearer in my original post.

You must pass the category ID as specified within Appendix 2 - Category IDs.

This is available here (http://www.shopwindowforum.com/showthread.php?t=9)

Therefore you would not pass a value of 'sports' but the Sports category ID, which is '246'.

I hope this makes a bit more sense...

Amo

arthomas
02-04-07, 22:19
Thanks, that now makes sence i didnt know the catogories had id numbers... thanks for the pdf link works a treat

amarath
02-04-07, 23:04
Excellent, sorry it took me a while to get there...

Amo

Luckyjj842
03-04-07, 00:33
Please can you enter the information where I am meant to put the Category ID as I am baffled? I want Category ID 135 for my hotpicks. Can you just add line or text as necessary and highlight it so I can understand where it goes?

Thanks again from a confused user!!

<?php
/**
*
* ShopWindow Toolset
*
* Copyright (C) 2007 Digital Window Ltd.
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*
*/


require_once('class.api_client.php');


/**
* Used for modular implementation, class to encapsulate the corresponding API functionality
*
*/
class api_hotPicks extends api_client
{
var $iCategoryId= false; // the category Id to which the products belong
var $aMerchantIds= array(); // the merchant ids to restrict results to
var $sSort= 'popular'; // one of: [random, popular]
var $iLimit= 2; // the maximum number of products




/**
* Gets featured products for a category
*
* @copyright DigitalWindow
* @author Kostas Melas <kostas@digitalwindow.com>
*
* @param int $oParams->iCategoryId
* @param array $oParams->aMerchantIds
* @param string $oParams->sSort
* @param int $oParams->iLimit
* @return array array of products
*/
function getHotPicks($oParams)
{
# sanity check and class var assignments
$this->iCategoryId= is_numeric($oParams->iCategoryId) ? $oParams->iCategoryId : $this->iCategoryId;
$this->aMerchantIds= is_array($oParams->aMerchantIds) ? $oParams->aMerchantIds : $this->aMerchantIds;
$this->sSort= !empty($oParams->sSort) ? $oParams->sSort : $this->sSort;
$this->iLimit= is_numeric($oParams->iLimit) ? $oParams->iLimit : $this->iLimit;


// SOAP params
$aParams= array("iCategoryId"=> $this->iCategoryId,
"aMerchantIds"=> $this->aMerchantIds,
"sSort"=> $this->sSort,
"iLimit"=> $this->iLimit);


// make the SOAP call
$this->call('getHotPickProductList', $aParams);


// array of products
$aProducts= $this->oResponse->getHotPickProductListReturn;


return $aProducts;
}

}


?>

ushop-online
03-04-07, 01:46
It seems to me that Hot Picks should be relevant to the Category so that when in Books the picks are for books etc.

If you hard code the hot picks they stay the same whichever category in.

Surely there must be a way to parse the cat id through to the hot picks parameters on click.

karsin
03-04-07, 11:07
Hi All,

Added $oHotPicksParams->iCategoryId= 259; to all 4 page classes, doesn't seem working too. please advice, where to slot for the code.

Thanks

ks

arthomas
03-04-07, 17:28
I can’t get the hot pics to stick to one category, please could an administrator or somebody who knows how explain for the masses a way to get the hot pics to select relevant products, I suggest placing this as a FAQ or a sticky to save you and other people time as it is a very frequently asked question.

The code I have placed in the page.class.php files:

# hot picks
$aHotPickParams = array("iLimit"=>15);

$oHotPicksParams->iCategoryId= 146;

$this->oHotPick = $oClient->call('getHotPickProductList', $aHotPickParams);
}

}
# end of class

I thought this would work as it is the most logical explination I could think of, before the call it categorises the products??? Maybe it needs to be placed in the hot picks parameters as well but im not to sure.....To save me and many other people hours of trial and error, could you guys help us out?

Thanks.

IntroSites
03-04-07, 18:08
arthomas,

1.In class.page_????.php

2.Make sure the code is inside the build data function

For Hot Picks related to the category viewed insert this

$aHotPickParams = array("iLimit"=>15,"iCategoryId"=>$_GET['c']);
$this->oHotPick = $oClient->call('getHotPickProductList', $aHotPickParams);



For Hot Picks related to your chosen category insert this

$aHotPickParams = array("iLimit"=>15,"iCategoryId"=>146);
$this->oHotPick = $oClient->call('getHotPickProductList', $aHotPickParams);



Hope this helps

digitalwindow
03-04-07, 18:16
Hi All,

The parameter that you need to include in order to define Hot Picks Categories is:

$aHotPickParams = array('iLimit'=>3, 'iCategoryId'=>165);

So, if you were to customise the index page Hot Picks to represent a particular Hot Picks category, your code would look something like this:

================================================== ======

<?php
/**
*
* ShopWindow Toolset
*
* Copyright (C) 2007 Digital Window Ltd.
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*
*/


require_once('class.shopcore.php');
require_once('class.api_client.php');



class pageIndex extends shopcore
{

/**
* Constructor
*
* @access public
* @copyright affiliatewindow
* @author PAI <paul@affiliatewindow.com>
*/
function pageIndex()
{
$this->setPageHtml();
}

/**
* get page data requested
*
* @access public
* @copyright affiliatewindow
* @author PAI <paul@affiliatewindow.com>
*/
function buildData()
{
# check requirements
if ( !is_numeric($this->iCategoryId) ) $this->iCategoryId = 0;


$oClient = new api_client();

# category tree
$aCategoryTreeParams = array("iCategoryId"=>$this->iCategoryId, "aMerchantIds"=>$aMerchantIds, "bIncludeEmptyCats"=>$this->bTreeEmptyCats, "bIncludeCounts"=>false);

$this->oCategoryList = $oClient->call('getCategoryTree', $aCategoryTreeParams);

# hot picks
$aHotPickParams = array('iLimit'=>3, 'iCategoryId'=>165);


$this->oHotPick = $oClient->call('getHotPickProductList', $aHotPickParams);
}

}
# end of class

?>

================================================== =======

In order to output Hot Picks according to the product search category, the following parameter needs to be included instead:

$aHotPickParams = array('iLimit'=>3, 'iCategoryId'=> $_GET['c']);

I hope this helps.

Amo

IntroSites
03-04-07, 18:33
Excellent timing Amo ;)

Looks like my solution :D

arthomas
03-04-07, 19:24
This is what i put in for the page.class_index.php (doesnt work):

# hot picks

$aHotPickParams = array("iLimit"=>15,"iCategoryId"=>146);

$this->oHotPick = $oClient->call('getHotPickProductList', $aHotPickParams);
}

}
# end of class

And this of the search.class_search.php (doesnt work):

# hotpicks
$aHotPickParams = array("iLimit"=>15,"iCategoryId"=>$_GET['c']);
$this->oHotPick = $oClient->call('getHotPickProductList', $aHotPickParams);

I just cant seem to get it to work, this time the hotpicks dont come up just the h2 header and the border.

have a look for yourselves... http://www.sassussex.com/savershandbook/index.php

IntroSites
03-04-07, 20:47
In the Index class try category id 4 as 146 has no hot picks

arthomas
03-04-07, 20:49
I agree I think this would be very useful for customers and a very powerful selling tool as well. I have seen a lot of major selling sites using this technique could this be done ??

Thanks guys P.S. Loving the set up getting to grips with it now.

Right I got hot picks down and working on one category....but it is sooo bad because only one product comes up and its the same product every time!!!!!!!

Compare how many hot picks come up as category id = 246
http://www.sassussex.com/savershandbook/index.php

Compared with the raw amount of products based here....
http://www.sassussex.com/savershandbook/category.php?c=246

Why is it that one product comes up, and it’s the same product each time, when there are 20,000 sporting products alone I sell through my merchants I signed up to ?

arthomas
03-04-07, 20:57
Thats seems a bit bizzarr that sporting goods have no hot picks ?!? such a huge amount of products in each section of the category hummm

someone needs to get that sorted fast, thanks for category id = 4 that did work but it has no relivance to sports which is the main focus of my site.

http://www.sassussex.com

Is there any way i can add hot picks, or i can get the merchants to do so?

will have to just do some of my own... bit of a mission but it may need to be done.

thanks.

IntroSites
03-04-07, 20:58
glad you got it working, im not sure but i think the hot picks will improve as the visitor data is collected

arthomas
03-04-07, 21:03
F*&%ing hope so, bit shoddy at the moment. i just had one pair of sports goggles as my sporting hot picks....not exactally a hot pick in my book but ok... what ever the market wants i suppose.

Thanks for the support guys is really helping.

found on that has more than just one hot pick for sporting goods... 147 - sporting support

amarath
03-04-07, 21:56
Hi Guys,

To clarify, we are in the process of communicating to all merchants to identify and update their Hot Pick selections.

Over the next few weeks, you should hopefully see an improvement in the number of products within the Hot Pick Pools, and product relevance to your category selection.

Thanks

Amo

ushop-online
04-04-07, 01:21
In order to output Hot Picks according to the product search category, the following parameter needs to be included instead:

$aHotPickParams = array('iLimit'=>3, 'iCategoryId'=> $_GET['c']);

I hope this helps.
Amo

Perfect!

Thanks for that :)

Luckyjj842
04-04-07, 01:34
Please can you give us an answer/explanation so that it is easily understood to a basic user.

Normally it would be something like this:

If you want your Hot Picks to display a specific category you will need to edit your:

/includes/elements/hot_picks.php

Find: blah blah blah blah

Replace with: blah blah blah blah

Note: Each Hot Picks category is represented by a number. The complete category list is here:

blah blah blah

-------------------------------------------------------------------------
I know this is stating the obvious but we are not all experts in php and web design. Using the above simple explanation will allow us to open the correct page using edit, find the line in question and replace it with the correct text etc. I think we could all manage to change the numbers to our desired category.

This simple explanation will make it easy for all. Thanks again in advance.

John

ushop-online
04-04-07, 02:02
Hi All,

The parameter that you need to include in order to define Hot Picks Categories is:

$aHotPickParams = array('iLimit'=>3, 'iCategoryId'=>165);

So, if you were to customise the index page Hot Picks to represent a particular Hot Picks category, your code would look something like this:

================================================== ======

<?php
/**
*
* ShopWindow Toolset
*
* Copyright (C) 2007 Digital Window Ltd.
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*
*/


require_once('class.shopcore.php');
require_once('class.api_client.php');



class pageIndex extends shopcore
{

/**
* Constructor
*
* @access public
* @copyright affiliatewindow
* @author PAI <paul@affiliatewindow.com>
*/
function pageIndex()
{
$this->setPageHtml();
}

/**
* get page data requested
*
* @access public
* @copyright affiliatewindow
* @author PAI <paul@affiliatewindow.com>
*/
function buildData()
{
# check requirements
if ( !is_numeric($this->iCategoryId) ) $this->iCategoryId = 0;


$oClient = new api_client();

# category tree
$aCategoryTreeParams = array("iCategoryId"=>$this->iCategoryId, "aMerchantIds"=>$aMerchantIds, "bIncludeEmptyCats"=>$this->bTreeEmptyCats, "bIncludeCounts"=>false);

$this->oCategoryList = $oClient->call('getCategoryTree', $aCategoryTreeParams);

# hot picks
$aHotPickParams = array('iLimit'=>3, 'iCategoryId'=>165);


$this->oHotPick = $oClient->call('getHotPickProductList', $aHotPickParams);
}

}
# end of class

?>

================================================== =======

In order to output Hot Picks according to the product search category, the following parameter needs to be included instead:

$aHotPickParams = array('iLimit'=>3, 'iCategoryId'=> $_GET['c']);

I hope this helps.

Amo

Simply go to includes/classes/ find four files starting with class.page then find # hot picks
$aHotPickParams = array("iLimit"=>3); the number may have been changed from 3 -- replace this with # hot picks
$aHotPickParams = array('iLimit'=>3,'iCategoryId'=>165;

Category ID's http://www.shopwindowforum.com/showthread.php?t=9

OK!

Luckyjj842
04-04-07, 03:02
Thanks Ushop, but even that does not work. You referred to the 4 pages. Only 2 of them had the line in.

I am going to wait until this software is reliable and can be easily managed.

It is easier to set up your own product feed and write your own php than getting this running.

I have spent nearly 1 week and I still am displaying radom rubbish on my home page.

Thanks again

John

ushop-online
04-04-07, 12:11
Thanks Ushop, but even that does not work. You referred to the 4 pages. Only 2 of them had the line in.

I gave you what you wanted and you complain.

I am going to wait until this software is reliable and can be easily managed.

This is a test forum -- we are meant to test -- find problems -- AW then try to correct problems.

It is easier to set up your own product feed and write your own php than getting this running.

Glad you have those skills -- so what is stopping you.

I have spent nearly 1 week and I still am displaying radom rubbish on my home page.

I am sure the merchants wouldn't call their products rubbish but random is what it is supposed to be.

Glitz
04-04-07, 12:46
Since hot picks are such a bone of contention, surely with 600 merchants on board they could be used to expose 'special offers' rotated randomly until a category search is called and then offers specific to that inquiry.

I'm sure the merchants have budget to throw up a juicy loss-leader to gain exposure and encourage click through for further information, after all thats what it's all about, No?

For us affiliates, instead of just another shopping resource among thousands, we become become a 'first stop' reference to what's on offer across the web. Human nature will insure they bookmark us and check-in regularly to see if they are missing anything.

Thoughts?

JY.

Luckyjj842
04-04-07, 13:43
I was not referring to your advice as rubbish, far from it, I even thanked you for your time.

I also dont mean the products are rubbish. Each has its place within a relevant website design.

i.e. If I am promoting lingerie I hardly want my Hot Picks displaying mens trainers.

For instance, a website is called newbra. The title gives a clue to the potential products. When you enter the site the Hot Picks then randomly display anything. (currently not relevant to site design).

I understand Shop Window is in its infancy and that publishers will increase product relevance over the next few weeks.

I am not getting at Affiliate Window either, they are doing an outstanding job and it does offer great affiliate potential.

I am merely explaining that we are not all experts in web design and affiliate marketing. Everyone, including yourself started out on this venture at some point. The learning curve can be often frustrating and at times it drives you mad.

I am just pointing out that if the change/alteration to a page is easy to understand and more importantly understood by all, it would stop the threads continuing for 3 pages or more. This thread I started to gain your advice and the help of Affiliate Window. It was somewhat sidetracked by other users and the answer was never given clearly.

This is why I suggested ACCURACY and a simple format as in my earlier post. This seems to work on other forums and I am sure it would work here. Typing a one line answer with no actual advice as to where or how it can be implimented makes the advice sadly unusable to all but the experts in the affiliate world.

Sadly I am not an expert, I experiment, I make mistakes, I start again, I occasionally even succeed. This could be why I have had lingerie sales averaging £10,000 per month. (Not via Affiliate Window) None of this comes via PPC.

Again I thank you for your help. It was not a dig at you or anyone in particular. I was just highlighting the fact that we are not all experts and could do with sound advice in an easy to understand format.

ushop-online
04-04-07, 13:56
Well I am a driver not a mechanic or manufacturer.

Can't write scripts but can find problems in others hard work even if I can't fix it.

But what I do is read the reply to a query and if not immediately obvious experiment --- personally I think this was fairly obvious after a couple of reads and worked fine after third read when I engaged my brain on just this.

The original reply [not mine] was complete - it showed you what to do and where in the script to do it.

I was involved in setting up and testing the original ShopWindow product and now the new one and can assure you this is way easier to debug than the original.

gunneradt
08-04-07, 14:37
bit confused on this one - maybe someone can help

1. hotpicks code is not in class.page.category or product. Not a major problem but when would hot picks be displayed in these functions anyway if this code was added.

2. I have included the get c code in search class pgae but gfar too many categories don't have any hotpicks. This is daft as this is a really good feature to offer users alternatives if their search isn't found.

cheers

gunneradt
08-04-07, 14:59
in fact so many categories have no hot picks I've reverted back - at least we get unrelated hot picks that way.

amarath
08-04-07, 15:24
Hi Gunner,

We have issued a communication to all of our merchants about how to identify and upload products into Hot Picks.

Over the coming weeks these merchants will be adding products into their Hot Picks.

I think that you will see a big change over the next week, especially with our bigger merchants with large datafeeds.

Amo

gunneradt
08-04-07, 16:48
cheers mate - is there anyway you can tell us when hot picks are properly populated. There's just now way it's worth risking leaving it by category at the moment.

regards

amarath
08-04-07, 16:52
np Gunner :D

Definately agree, will provide you with an update on Hot Picks once we have made some good progress.

Enjoy your afternoon,

Amo

gbaxendale
20-04-07, 23:28
Hello all,

I have been reading through the various threads trying to get undertsand how to get the Hot Picks to show a specific category and after sometime have now managed to work it out.

I thought I would explain how I got it to work for me in case it works for anyone else as it seems awkward...

Go to the folder ../includes/classes

In turn edit the following files:

class.page_search.php
class.page_product.php
class.page_index.php
class.page_category.php


Add the following in full (category 4 shows electrical products) after the section that says function buildData(), some already have the hotpicks section some don't just overwrite the exisiting section or if does not exist just insert it including the brackets:


}
# hot picks
$aHotPickParams = array("iLimit"=>12,"iCategoryId"=>4);
$this->oHotPick = $oClient->call('getHotPickProductList', $aHotPickParams);
}

That did it for me.

Demo: http://www.yourelectricals.co.uk/db

Hope it helps.
Gaz

ushop-online
20-04-07, 23:58
As I said on your other post about this fix -- it doesn't load anything except under search.