Jump to content
Sign in to follow this  
diva_uno

Randomize Anywhere question

Recommended Posts

I am trying to use the randomize contribution. The question I have is where do you insert the code? The README file says to make changes at the top of the catalog.php file. Now is this the catalog.php that is located at http://mysite.com/catalog/admin/includes/boxes/ or could this possibly refer to the default.php file? And does at the top mean very top? Or at the top between this or that? The instructions don't give a before or after.

Here is a copy of the directions:

 

1) Make the changes at the top of the catalog.php file as follows:

 

$db_server = ""; //database server

Enter the location of your MySQL DB (usually Localhost)

 

$db_user = ""; //database user

Enter your username

 

$db_pass = ""; //database password

Enter your password

 

$db_name = ""; //database name

Enter your database name.

 

$domain_name = ""; //don't use leading or trailing slashes or http:

Enter your domain name e.g. www.microsoft.com

 

$catalog_folder_name = ""; //no slashes

Enter the name of the subfolder that your catalog is in.

e.g. shop

 

(Make sure that if your catalog is nested inside folders

from the root that you place them in there. e.g. your catalog is

at http://www.yourdomain.com/heres/the/shop/default.php, you would enter

heres/the/shop without the leading or trailing slash)

 

$site_title = ""; //site name

Enter your site's title (what you put between the <title></title> tags

 

$image_width = "100"; //how wide your images should be

Set your image widths

 

$image_height = "100"; // how high your images should be

Set your image heights

 

$num_products = "18"; //max number of products per page

Set the number of products to display per page

 

$prod_col = "3"; //number of columns per page

How many columns would you like in the table?

 

$table_width = "95"; // table width in percent don't use %

Enter the width of your table in percentage (but don't use %)

 

$table_align = "center"; //table alignment

Enter your desired table alignment

 

$table_cspace = "0"; //table cellspacing

Enter your desired table cellspacing

 

$table_cpadd = "0"; //table cellpadding

Enter your desired table cellpadding

 

$product_price_show = "1"; //show prices? (1 is on, 0 is off)

Enter 1 to show prices, enter 0 to omit prices

 

$product_image_show = "1"; //show images? (1 is on, 0 is off)

Enter 1 to show images, enter 0 to omit images

 

$product_info_link_show = "1"; //show link to product_info.php? (1 is on, 0 is off)

Enter 1 to show a link to product page in osc, enter 0 to omit

 

$product_buy_link_show = "1"; //show link to shopping cart? (1 is on, 0 is off)

Enter 1 to show a link to add product to osc shopping cart, enter 0 to omit

 

$product_name_show = "1";// show product name? (1 is on, 0 is off)

Enter 1 to show the product name, enter 0 to omit

 

 

2) Upload this wherever you want, so long as it can connect to the database.

 

The last thing said is to upload this wherever you want. But if you are editing a file from a certain folder shouldn't you upload it where it is suppose to go? Or does this refer to an unmentioned randomize.php file that was included in the zip?

:?

Share this post


Link to post
Share on other sites

This is my opinion on it.

 

Don't change catalog.php. Make the entries in the randomize.php file and then call it to show the products. I am playing it with it now also trying to get it to load the images.


Ron

If we knew it all we wouldn't be here would we?

Share this post


Link to post
Share on other sites

How could i add the different language to the randomize.php

To show the products in all languages of the shop.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×