Results 1 to 6 of 6

No pricing or buy buttons

This is a discussion on No pricing or buy buttons within the osCmax v1.7 Discussion forums, part of the osCmax v1.7 Forums category; Hi, I am trying to modify osc to use it as a catalog only. The customer does not want anyone ...

      
  1. #1
    New Member
    Join Date
    Aug 2003
    Posts
    18
    Rep Power
    0


    Default No pricing or buy buttons

    Hi,

    I am trying to modify osc to use it as a catalog only. The customer does not want anyone to purchase from the website but only be able to print out a catalog.

    I have been trying to modify the product_listing_col.php file. I am able to get rid of the buy me now button and the price but now instead of the product name, price and buy me now button I have 3 linkable product names. I can't seem to figure out how to get around this.

    Here is what the original photo looks like:



    Here it is with the changes I made to the file.


    I know next to nothing about php so that is part of my problem I am sure.

    Here is what I have done to the original code. Basically I just took out alot of code.

    Code:
    <?php
    /*
      $Id: product_listing.php,v 1.44 2003/06/09 22:49:43 hpdl Exp $
    */
    
      $listing_split = new splitPageResults($listing_sql, MAX_DISPLAY_SEARCH_RESULTS, 'p.products_id');
    
      if ( ($listing_split->number_of_rows > 0) && ( (PREV_NEXT_BAR_LOCATION == '1') || (PREV_NEXT_BAR_LOCATION == '3') ) ) {
    ?>
    <table border="0" width="100%" cellspacing="0" cellpadding="2">
      <tr>
        <td class="smallText"><?php echo $listing_split->display_count(TEXT_DISPLAY_NUMBER_OF_PRODUCTS); ?></td>
        <td class="smallText" align="right"><?php echo TEXT_RESULT_PAGE . ' ' . $listing_split->display_links(MAX_DISPLAY_PAGE_LINKS, tep_get_all_get_params(array('page', 'info', 'x', 'y'))); ?></td>
      </tr>
    </table>
    <?php
      }
    
      $list_box_contents = array();
    
      if ($listing_split->number_of_rows > 0) {
        $listing_query = tep_db_query($listing_split->sql_query);
    
        $row = 0;
        $column = 0;
        while ($listing = tep_db_fetch_array($listing_query)) {
    
          $product_contents = array();
    
          for ($col=0, $n=sizeof($column_list); $col<$n; $col++) {
            $lc_align = '';
    
            switch ($column_list[$col]) {
              case 'PRODUCT_LIST_NAME':
                $lc_align = '';
                $lc_text = ' <a href="' . tep_href_link(FILENAME_PRODUCT_INFO, ($cPath ? 'cPath=' . $cPath . '&' : '') . 'products_id=' . $listing['products_id']) . '">' . $listing['products_name'] . '</a> ';
                break;
    
              case 'PRODUCT_LIST_IMAGE':
                $lc_align = 'center';
                $lc_text = ' <a href="' . tep_href_link(FILENAME_PRODUCT_INFO, ($cPath ? 'cPath=' . $cPath . '&' : '') . 'products_id=' . $listing['products_id']) . '">' . tep_image(DIR_WS_IMAGES . $listing['products_image'], $listing['products_name'], SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT) . '</a> ';
    
    
            }
            $product_contents[] = $lc_text;
    
          }
          $lc_text = implode('<br>', $product_contents);
          $list_box_contents[$row][$column] = array('align' => 'center',
                                                    'params' => 'class="productListing-data"',
                                                    'text'  => $lc_text);
          $column ++;
          if ($column >= 3) {
            $row ++;
            $column = 0;
          }
        }
    
        new productListingBox($list_box_contents);
      } else {
        $list_box_contents = array();
    
        $list_box_contents[0] = array('params' => 'class="productListing-odd"');
        $list_box_contents[0][] = array('params' => 'class="productListing-data"',
                                       'text' => TEXT_NO_PRODUCTS);
    
        new productListingBox($list_box_contents);
      }
    
      if ( ($listing_split->number_of_rows > 0) && ((PREV_NEXT_BAR_LOCATION == '2') || (PREV_NEXT_BAR_LOCATION == '3')) ) {
    ?>
    <table border="0" width="100%" cellspacing="0" cellpadding="2">
      <tr>
        <td class="smallText"><?php echo $listing_split->display_count(TEXT_DISPLAY_NUMBER_OF_PRODUCTS); ?></td>
        <td class="smallText" align="right"><?php echo TEXT_RESULT_PAGE . ' ' . $listing_split->display_links(MAX_DISPLAY_PAGE_LINKS, tep_get_all_get_params(array('page', 'info', 'x', 'y'))); ?></td>
      </tr>
    </table>
    <?php
      }
    ?>

    Any help would be greatly appreciated.

    Thanks

    Rick

  2. #2
    osCMax Developer

    michael_s's Avatar
    Join Date
    Jul 2002
    Location
    Phoenix, AZ
    Posts
    20,757
    Rep Power
    573


    Default

    How about just turning them off in the admin... There is an option for this, ya know.

    Configuration Product Listing

    You could also install the 'Printable Catalog' mod.
    Michael Sasek
    osCMax Developer


    osCmax Installation Service
    - Have our professionals install osCmax on your server - same day service!
    osCmax 2.5 User Manual - the must have beginners guide to osCmax v2.5

    Stay Up To Date with everything osCMax:
    Free osCmax Newsletters - Security notices, New Releases, osCMax News
    osCmax on Twitter - Up to the minute info as it happens. Know it first.

    osCmax Documentation

  3. #3
    New Member
    Join Date
    Aug 2003
    Posts
    18
    Rep Power
    0


    Default

    OK, Maybe I am somewhat dense. I have the price turned off in the configuration and it works on all pages EXCEPT the index page. It still shows as I have indicated above.

    I have upgraded to 1.5 with no problems. The Printable Catalog works great but doesn't solve my problem.

    Am I missing something?

    Thanks

    P.S. I did a fresh install of 1.5 max and still have the price showing as I indicated above. Any help would be appreciated.

  4. #4
    osCMax Developer

    michael_s's Avatar
    Join Date
    Jul 2002
    Location
    Phoenix, AZ
    Posts
    20,757
    Rep Power
    573


    Default

    That is because the products are controlled by the boxes that display them on the index page. So, you will have to manually edit the actual boxes to change the display. Also, MS2-MAX uses product_listing_col.php for the product listings.

    To edit the specials, you need to edit default_specials.php, and to edit the new items box, the file new_products.php, both in the includes/modules directory...

    In new_products.php, look for and remove this code:
    Code:
     . $currencies->display_price($new_products['products_price'], tep_get_tax_rate($new_products['products_tax_class_id']))
    I have not looked in default_specials, but I am sure it is similar...
    Michael Sasek
    osCMax Developer


    osCmax Installation Service
    - Have our professionals install osCmax on your server - same day service!
    osCmax 2.5 User Manual - the must have beginners guide to osCmax v2.5

    Stay Up To Date with everything osCMax:
    Free osCmax Newsletters - Security notices, New Releases, osCMax News
    osCmax on Twitter - Up to the minute info as it happens. Know it first.

    osCmax Documentation

  5. #5
    New Member
    Join Date
    Aug 2003
    Posts
    18
    Rep Power
    0


    Default

    That was the answer. I was just looking in the wrong files. Thanks for the help.

    Thanks also for your work in providing this product to us. Your efforts are greatly appreciated.

    Rick

  6. #6
    Member
    Join Date
    Oct 2003
    Location
    The Antelope Valley in SoCal
    Posts
    47
    Rep Power
    0


    Default

    I tried the same thing (switching off "display prices") in Admin, as all my products were 0.00 to begin with. DIdn't work!

    To Kill the prices displaying (all except the shopping cart), you can also modify catalog/includes/classes/currencies.php around line 77

    FIND:

    function display_price($products_price, $products_tax, $quantity = 1) {
    return $this->format(tep_add_tax($products_price, $products_tax) * $quantity);

    CHANGE TO:

    function display_price($products_price, $products_tax, $quantity = 1) {
    return '';

Similar Threads

  1. "Per Customer Pricing" AND "Volume Pricing&qu
    By Bah in forum osCmax v2 Customization/Mods
    Replies: 0
    Last Post: 12-03-2005, 04:01 PM
  2. Firework Buttons Template
    By ganast in forum osCmax v2 Customization/Mods
    Replies: 0
    Last Post: 08-13-2005, 12:43 PM
  3. missing buttons
    By nmrunner in forum osCMax v1.7 Installation
    Replies: 2
    Last Post: 04-11-2005, 11:55 AM
  4. Category Selection Buttons
    By auntie22 in forum osCmax v1.7 Discussion
    Replies: 2
    Last Post: 03-30-2004, 10:14 AM
  5. Any one have a button template for the buttons used in MAX?
    By Anonymous in forum osCmax v1.7 Discussion
    Replies: 4
    Last Post: 02-02-2004, 09:51 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •