Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

almost done but...


shutiri

Recommended Posts

Posted

Hi.

 

I'm almost done with everything (this is a really GREAT shopping cart, thanks to all the people involved), but I have some little last issues:

- when I click on the send to a friend icon, it takes me to shopping_cart.php (instead of tell_a_friend.php, I suppose).

- How do I change the languages ? (I'm sorry if I missed it, but I didn't see it on the admin tool).

- How do I take away the "New Products" box on the index.php ?

- When I click the "top" link, it takes me to the folders view of my site. How do I set it to stay in /catalog/index.php ?

- How do I password protect the admin ? (dangerous :ph34r: )

- I saw it is possible to create more than 1 catalog, but I dont find it either. Do I have to do several intallations or add new folders (like the /catalog one) ?

- Last one (I hope): I would like to unify several catalogs on several sites from several clients under a unique site, a big shop that would search for products on all these sites and sell the products directly. Is this possible or am I asking too much ;) ?

 

Thank you.

Shutiri.

Posted

Hi,

 

- when I click on the send to a friend icon, it takes me to shopping_cart.php (instead of tell_a_friend.php, I suppose).

 

Part of the code for this is .....

 

<td align="center" class="boxText"><form name="tell_a_friend" action="http://example.com/tell_a_friend.php" method="get"><input type="text" name="to_email_address" size="10"> 

 

and as you can see, it invokes 'tell_a_friend.php', but if you aren't logged in, it will go to the login page and get you to login in. Try a "View | Source" and see if the code does a 'get' on the correct file.

 

Peter

Posted

the languages are in admin left hand menu under localization and languages

 

I have given the removal of products box and some more

 

it is the new products box catalog/index.php

 

catalog/index.php

 

Try looking for this around line 121

 

<td><?php include(DIR_WS_MODULES . FILENAME_NEW_PRODUCTS); ?></td>

change to this

<td><?php //include(DIR_WS_MODULES . FILENAME_NEW_PRODUCTS); ?></td>

 

This around line 280 (for product list)

 

<td><?php include(DIR_WS_MODULES . FILENAME_PRODUCT_LISTING); ?></td>

change to this

<td><?php //include(DIR_WS_MODULES . FILENAME_PRODUCT_LISTING); ?></td>

 

This around line 313

 

<td><?php include(DIR_WS_MODULES . FILENAME_NEW_PRODUCTS); ?></td>

change to this

<td><?php //include(DIR_WS_MODULES . FILENAME_NEW_PRODUCTS); ?></td>

 

This around line 316 ( for upcoming products)

 

<?php
   include(DIR_WS_MODULES . FILENAME_UPCOMING_PRODUCTS);
?>

change to this

<?php
  // include(DIR_WS_MODULES . FILENAME_UPCOMING_PRODUCTS);
?>

 

TOP link:

 

catalog/includes/application_top.php

 

locate this code

$breadcrumb->add(HEADER_TITLE_TOP, HTTP_SERVER);

and change to this

$breadcrumb->add(HEADER_TITLE_CATALOG, tep_href_link(FILENAME_DEFAULT));

the same as the line below it

 

PASSWORD protect admin:

 

you can use an .htaccess file this protection should be available to you through the control panel provided by your host.

 

you can install a contribution for admin access with levels

 

 

MULTI STORES

 

look for the contribution for multiple store in the contributions area a link to which can be found below in my signature

No longer giving free advice. Please place deposit in meter slot provided.  Individual: [=] SME: [==] Corporation: [===]
If deposit does not fit one of the slots provided then you are asking too much! :P

Is your Osc dated try Phoenix  raising oscommerce from the ashes.

Posted

Thank you for your answers.

 

Peterr, in which file should I look for that code ?

 

241, I did what you told me to remove the new products, but it didn't work. I'm using STS to customize the design, maybe this is the reason. What else should I do ?

 

about the top link, how can I choose the URL to go from that link ?

 

How do I setup more than 1 catalog in the same site ?

 

Shutiri

Posted

Hi,

 

Peterr, in which file should I look for that code ?

 

/catalog/index.php - around line 327

 

<?php require(DIR_WS_INCLUDES . 'column_right.php'); ?>

 

which does a 'require' on /catalog/includes/column_right.php

 

/catalog/includes/column_right.php - around line 36

 

    if (basename($PHP_SELF) != FILENAME_TELL_A_FRIEND) include(DIR_WS_BOXES . 'tell_a_friend.php');

 

/catalog/includes/boxes/tell_a_friend.php

 

<?php
/*
 $Id: tell_a_friend.php,v 1.16 2003/06/10 18:26:33 hpdl Exp $

 osCommerce, Open Source E-Commerce Solutions
 http://www.oscommerce.com

 Copyright (c) 2003 osCommerce

 Released under the GNU General Public License
*/
?>
<!-- tell_a_friend //-->
         <tr>
           <td>
<?php
 $info_box_contents = array();
 $info_box_contents[] = array('text' => BOX_HEADING_TELL_A_FRIEND);

 new infoBoxHeading($info_box_contents, false, false);

 $info_box_contents = array();
 $info_box_contents[] = array('form' => tep_draw_form('tell_a_friend', tep_href_link(FILENAME_TELL_A_FRIEND, '', 'NONSSL', false), 'get'),
                              'align' => 'center',
                              'text' => tep_draw_input_field('to_email_address', '', 'size="10"') . ' ' . tep_image_submit('button_tell_a_friend.gif', BOX_HEADING_TELL_A_FRIEND) . tep_draw_hidden_field('products_id', $HTTP_GET_VARS['products_id']) . tep_hide_session_id() . '<br>' . BOX_TELL_A_FRIEND_TEXT);

 new infoBox($info_box_contents);
?>
           </td>
         </tr>
<!-- tell_a_friend_eof //-->

 

How do I setup more than 1 catalog in the same site ?

 

Well, I wish I had known about Multi-Stores Multiple shops support , before I started to place 3 domains on the one site (see the discussion here ), about how I did it. Hindsight is always a wonderful thing, and although the 3 domains, with seperate content all work ok on one site with osCommerce, it is not without some problems (the way I did it, I mean). It is on my "to do' list, to install/test the "Multi-Stores" contribution though. :D

 

Peter

Posted

Yes, I checked it and I have exactly the same code, but when I click on the icon to send it to a friend it takes me to shopping_cart.php. I did everything with the STS contribution, so the column_right and column_left are both on column_right.

 

Here is the code of that file, maybe you could find the problem, please:

 

<?php
/*
 $Id: column_left.php,v 1.1 2003/09/08 19:26:22 jhtalk Exp jhtalk $

 osCommerce, Open Source E-Commerce Solutions
 http://www.oscommerce.com

 Copyright (c) 2003 osCommerce

 Released under the GNU General Public License
*/
 // STS: ADD
 $sts_block_name = 'header2columnleft';
 require(STS_RESTART_CAPTURE);
 // STS: EOADD

 if ((USE_CACHE == 'true') && empty($SID)) {
   echo tep_cache_categories_box();
 } else {
   include(DIR_WS_BOXES . 'categories.php');
 }

 // STS: ADD
 $sts_block_name = 'categorybox';
 require(STS_RESTART_CAPTURE);
 // STS: EOADD

 if ((USE_CACHE == 'true') && empty($SID)) {
   echo tep_cache_manufacturers_box();
 } else {
   include(DIR_WS_BOXES . 'manufacturers.php');
 }

 // STS: ADD
 $sts_block_name = 'manufacturerbox';
 require(STS_RESTART_CAPTURE);
 // STS: EOADD

 require(DIR_WS_BOXES . 'whats_new.php');

 // STS: ADD
 $sts_block_name = 'whatsnewbox';
 require(STS_RESTART_CAPTURE);
 // STS: EOADD

 require(DIR_WS_BOXES . 'search.php');

 // STS: ADD
 $sts_block_name = 'searchbox';
 require(STS_RESTART_CAPTURE);
 // STS: EOADD

 require(DIR_WS_BOXES . 'information.php');

 // STS: ADD
 $sts_block_name = 'informationbox';
 require(STS_RESTART_CAPTURE);
 // STS: EOADD

 require(DIR_WS_BOXES . 'shopping_cart.php');

 // STS: ADD
 $sts_block_name = 'cartbox';
 require(STS_RESTART_CAPTURE);
 // STS: EOADD

 if (isset($HTTP_GET_VARS['products_id'])) include(DIR_WS_BOXES . 'manufacturer_info.php');

 // STS: ADD
 $sts_block_name = 'maninfobox';
 require(STS_RESTART_CAPTURE);
 // STS: EOADD

 if (tep_session_is_registered('customer_id')) include(DIR_WS_BOXES . 'order_history.php');

 // STS: ADD
 $sts_block_name = 'orderhistorybox';
 require(STS_RESTART_CAPTURE);
 // STS: EOADD

 if (isset($HTTP_GET_VARS['products_id'])) {
   if (tep_session_is_registered('customer_id')) {
     $check_query = tep_db_query("select count(*) as count from " . TABLE_CUSTOMERS_INFO . " where customers_info_id = '" . (int)$customer_id . "' and global_product_notifications = '1'");
     $check = tep_db_fetch_array($check_query);
     if ($check['count'] > 0) {
       include(DIR_WS_BOXES . 'best_sellers.php');
     } else {
       include(DIR_WS_BOXES . 'product_notifications.php');
     }
   } else {
     include(DIR_WS_BOXES . 'product_notifications.php');
   }
 } else {
   include(DIR_WS_BOXES . 'best_sellers.php');
 }

 // STS: ADD
 $sts_block_name = 'bestsellersbox';
 require(STS_RESTART_CAPTURE);
 // STS: EOADD

 if (isset($HTTP_GET_VARS['products_id'])) {
   if (basename($PHP_SELF) != FILENAME_TELL_A_FRIEND) include(DIR_WS_BOXES . 'tell_a_friend.php');
 } else {
   include(DIR_WS_BOXES . 'specials.php');
 }

 // STS: ADD
 $sts_block_name = 'specialfriendbox';
 require(STS_RESTART_CAPTURE);
 // STS: EOADD

 if (substr(basename($PHP_SELF), 0, 8) != 'checkout') {
   include(DIR_WS_BOXES . 'languages.php');

   // STS: ADD
   $sts_block_name = 'languagebox';
   require(STS_RESTART_CAPTURE);
   // STS: EOADD

   include(DIR_WS_BOXES . 'currencies.php');

   // STS: ADD
   $sts_block_name = 'currenciesbox';
   require(STS_RESTART_CAPTURE);
   // STS: EOADD

 }

?>

 

Thank you. I will read the other links you sent me.

 

I still can't remove the new products box :( . help please...

 

shutiri

Posted
How do I take away the "New Products" box on the index.php ?

Using STS you can open includes/sts_template.html and view in WYSIWYG mode using and just delete the $new_products part from the screen.

 

To remove it using code I "think" (don't quote me and backup first) it shoud read something like;

<p><font size="1" face="Arial, Helvetica, sans-serif">$newproducts</font></p>

 

Try commenting that out and see if it works.

 

HTH

 

Peter

Posted

I 'm using Dreamweaver, but all I see is $content in the template. I can't just remove it.

 

Where should I put the code you wrote ?

 

Thank you.

shutiri.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...