Jump to content


Corporate Sponsors


Latest News: (loading..)

- - - - -

[Contribution] Cross Sell (X-Sell) Admin


543 replies to this topic

#1 dreamscape

  • Community Member
  • 1,546 posts
  • Real Name:departing this world in search of another

Posted 19 February 2003, 15:45

For WI Benjamin's "Cross Sell Module."

This mod is an admin section for the Cross-Sell (X-Sell) module. It was taken from a Cross Sale module and changed to work with Cross-Sell (X-Sell).

The original code of this mod is in no way mine. I have merely updated the admin for "Cross Sale" to work with "Cross-Sell (X-Sell)". I like the catalog side of X-Sell better and wanted an admin for it, so I took the one for "cross sale" and updated it to work with X-Sell.

I know this mod is not the greatest or easiest to use. When time allows, I may find time to update it to be more user friendly.

http://www.oscommerce.com/community/contributions,1005

#2 dreamscape

  • Community Member
  • 1,546 posts
  • Real Name:departing this world in search of another

Posted 19 February 2003, 20:02

just a small note, anyone running a version of PHP older than v4.1.0 will have to do a search to find $_POST and replace with $HTTP_POST_VARS. There are 11 occurances of it in admin/xsell_products.php for those running old PHP versions.

#3 wizardsandwars

  • Community Member
  • 4,476 posts
  • Real Name:Chris Bradley

Posted 19 February 2003, 20:49

Man, Joshua, you are SOOO backwars compatible.

:lol:
-------------------------------------------------------------------------------------------------------------------------
NOTE: As of Oct 2006, I'm not as active in this forum as I used to be, but I still work with osC quite a bit.
If you have a question about any of my posts here, your best bet is to contact me though either Email or PM in my profile, and I'll be happy to help.

#4 wizardsandwars

  • Community Member
  • 4,476 posts
  • Real Name:Chris Bradley

Posted 19 February 2003, 20:50

*backwards
-------------------------------------------------------------------------------------------------------------------------
NOTE: As of Oct 2006, I'm not as active in this forum as I used to be, but I still work with osC quite a bit.
If you have a question about any of my posts here, your best bet is to contact me though either Email or PM in my profile, and I'll be happy to help.

#5 mugitty

  • Community Member
  • 1,201 posts
  • Real Name:Stuart Owens
  • Location:Great Southeastern Washington Desert, USA

Posted 19 February 2003, 21:31

Joshua;

You don't happen to have an URL that shows the X-sell mod in use, do you? I'm using Cross-sell and would be interested in seeing the difference.

Thanks!
... if you want to REALLY see something that doesn't set up right out of the box without some tweaking,
try being a Foster Parent!

#6 dreamscape

  • Community Member
  • 1,546 posts
  • Real Name:departing this world in search of another

Posted 19 February 2003, 21:53

Quote

Joshua;

You don't happen to have an URL that shows the X-sell mod in use, do you? I'm using Cross-sell and would be interested in seeing the difference.

Thanks!

Cross-Sell = X-Sell :)

there was a Cross Sale (not Cross Sell) posted quite some time ago that had an admin, but not as nice of a catalog module. I just took the admin from the Cross Sale and changed it to work with the Cross-Sell (X-Sell).

to be sure, this is the module that the admin was altered for:
http://www.oscommerce.com/community/contri...ions,334/page,3

#7 dreamscape

  • Community Member
  • 1,546 posts
  • Real Name:departing this world in search of another

Posted 19 February 2003, 21:55

Quote

Man, Joshua, you are SOOO backwards compatible.

:lol:

I dunno what u mean here... if u mean the coding for the admin, I didn't write it... I just altered the queries so that it would work with the Cross-Sell module... it came from another cross sale module that was posted in the forums quite some time ago (was never contributed).

#8 gdfwilliams

  • Community Member
  • 408 posts
  • Real Name:Greg
  • Location:Washington, DC, USA

Posted 19 February 2003, 23:29

Some X-Sell observations:

If you want buy_now buttons, be sure to do them like this:
<form name="buy_now_' . $xsell['products_id'] . '" method="post" action="' . tep_href_link(FILENAME_SHOPPING_CART, tep_get_all_get_params(array('action')) . 'action=buy_now', 'NONSSL') . '"><input type="hidden" name="products_id" value="' . $xsell['products_id'] . '">' . tep_image_submit('button_buy_now.gif', 'Buy ' . $xsell['products_name'] . ' Now!') . '</form>

It would be useful if products without X-Sell relationships defaulted to something. Say the top 3 Best Sellers in that product's category?

- Greg

#9 emiliano

  • Community Member
  • 410 posts
  • Real Name:Emiliano
  • Location:patagonia, argentina

Posted 20 February 2003, 01:16

what's x-sell??

cheers
emiliano
patagonia, argentina

#10 apxmaster

  • Community Member
  • 9 posts
  • Real Name:Adam P.

Posted 20 February 2003, 10:26

How to setup special offer prices in x-sell modul ?

#11 Waza04

  • Banned
  • 680 posts
  • Real Name:Warren Ashcroft
  • Gender:Male

Posted 20 February 2003, 12:03

HELP!!

I cant get the admin side to work!!

When I assagin one product to another....
I dosent do it and then when I go and do it again, I get an error that theres a duplicat key.

But in catalog it still dont work either!!


:shock:

#12 dreamscape

  • Community Member
  • 1,546 posts
  • Real Name:departing this world in search of another

Posted 20 February 2003, 16:25

Quote

It would be useful if products without X-Sell relationships defaulted to something. Say the top 3 Best Sellers in that product's category?

- Greg

that would only work out good if there were only 4 to 10 products per category.... and hey some of us have the "bestsellers" show the actual bestsellers :wink:

#13 dreamscape

  • Community Member
  • 1,546 posts
  • Real Name:departing this world in search of another

Posted 20 February 2003, 16:27

Quote

what's x-sell??

cheers
emiliano

X-sell = "cross sell"... its called cross sell the in the contribution list, but inside the contribution, it refers to istelf as X-Sell... basically it adds another box on product_info.php similar to the "also purchased" boxed... but u can pick what goes there... it is an "also reccomended" box basically.

#14 dreamscape

  • Community Member
  • 1,546 posts
  • Real Name:departing this world in search of another

Posted 20 February 2003, 16:29

Quote

HELP!!

I cant get the admin side to work!!

When I assagin one product to another....
I dosent do it and then when I go and do it again, I get an error that theres a duplicat key.

But in catalog it still dont work either!!


:shock:

I haven't tried it on exsisting installs... I got an email the other day froma guy and told him to completely drop the table and re-create it... that seemed to work for him...

run this SQL query and try the admin again:
DROP TABLE IF EXISTS products_xsell;

CREATE TABLE products_xsell ( 

ID int(10) NOT NULL auto_increment,

products_id int(10) unsigned NOT NULL default '1', 

xsell_id int(10) unsigned NOT NULL default '1', 

sort_order int(10) unsigned NOT NULL default '1',

PRIMARY KEY  (ID)

) TYPE=MyISAM;


#15 Waza04

  • Banned
  • 680 posts
  • Real Name:Warren Ashcroft
  • Gender:Male

Posted 20 February 2003, 17:30

Quote

Quote

HELP!!

I cant get the admin side to work!!

When I assagin one product to another....
I dosent do it and then when I go and do it again, I get an error that theres a duplicat key.

But in catalog it still dont work either!!


:shock:

I haven't tried it on exsisting installs... I got an email the other day froma guy and told him to completely drop the table and re-create it... that seemed to work for him...

run this SQL query and try the admin again:
DROP TABLE IF EXISTS products_xsell;

CREATE TABLE products_xsell ( 

ID int(10) NOT NULL auto_increment,

products_id int(10) unsigned NOT NULL default '1', 

xsell_id int(10) unsigned NOT NULL default '1', 

sort_order int(10) unsigned NOT NULL default '1',

PRIMARY KEY  (ID)

) TYPE=MyISAM;

I have done this, and reinstalled everytinh sbout 10 times!!

OMG - What the hell is wrong?

#16 itbejared

  • Community Member
  • 137 posts
  • Real Name:Jared
  • Location:Ogden, Ut

Posted 20 February 2003, 18:35

i am intested in using this if it works correctly. but seems warren is having some problems.

and i want to add it to an already existing cart? can this be done? w/o messing things up. :lol:

thanks

#17 itbejared

  • Community Member
  • 137 posts
  • Real Name:Jared
  • Location:Ogden, Ut

Posted 20 February 2003, 18:37

and i went to your example site and didn't notice a differnce with the items that were using cross-sell.. is there somewhere I could see exactly what this looks like? :D

#18 CC

  • Community Member
  • 1,289 posts
  • Real Name:....
  • Gender:Male
  • Location:Here \o/

Posted 20 February 2003, 21:33

Quote

I have done this, and reinstalled everytinh sbout 10 times!!  

OMG - What the hell is wrong?

Calm down man!

It aint that bad, small bugs can be ironed out.
And this is a very small addition which can be indone if it doesnt work for you, so chill...

I am gonna add this to my test server and see if I get any probs.
Will let you know shortly.

CC.

P.S. I hope you did the first step of every new mod...
BACKUP?

#19 dreamscape

  • Community Member
  • 1,546 posts
  • Real Name:departing this world in search of another

Posted 20 February 2003, 23:17

Quote

and i went to your example site and didn't notice a differnce with the items that were using cross-sell..  is there somewhere I could see exactly what this looks like?   :D

this thread is about an admin for cross-sell (X-sell)... not about the cross sell module itself... questions about that should be directed to the author or started in a new thread... I don't mean to sound, well mean, but all these postings about the cross-sell module are starting to make this thread confusing and hard to read... hell I'm confused now. :D

It is installed on my site, but its not live yet... if u can wait like a week, I will post it, and u can see the cross-sell module.

#20 dreamscape

  • Community Member
  • 1,546 posts
  • Real Name:departing this world in search of another

Posted 20 February 2003, 23:22

Quote

Quote

Quote

HELP!!

I cant get the admin side to work!!

When I assagin one product to another....
I dosent do it and then when I go and do it again, I get an error that theres a duplicat key.

But in catalog it still dont work either!!


:shock:

I haven't tried it on exsisting installs... I got an email the other day froma guy and told him to completely drop the table and re-create it... that seemed to work for him...

run this SQL query and try the admin again:
DROP TABLE IF EXISTS products_xsell;

CREATE TABLE products_xsell ( 

ID int(10) NOT NULL auto_increment,

products_id int(10) unsigned NOT NULL default '1', 

xsell_id int(10) unsigned NOT NULL default '1', 

sort_order int(10) unsigned NOT NULL default '1',

PRIMARY KEY  (ID)

) TYPE=MyISAM;

I have done this, and reinstalled everytinh sbout 10 times!!

OMG - What the hell is wrong?

it should work fine... unless you are running an older PHP version, in which case you will need to search through admin/xsell_products.php for $_POST and replace it with $HTTP_POST_VARS