osCmax v2.5 User Manual
Results 1 to 2 of 2

Can I "include('details.htm')" in a product discri

This is a discussion on Can I "include('details.htm')" in a product discri within the osCmax v1.7 Discussion forums, part of the osCmax v1.7 Forums category; I have 60 products that are basicly the same and would like to include canned text with each one. Rather ...

      
  1. #1
    New Member
    Join Date
    Mar 2004
    Posts
    6
    Rep Power
    0


    Default Can I "include('details.htm')" in a product discri

    I have 60 products that are basicly the same and would like to include canned text with each one. Rather than repasting the lengthy text each time in order to get it to display on the page, I would like to simply drop in a php include line, in my product discription, to automatly insert a htm file into the discription.


    Is this possible and can somebody give me the syntax?

    I know I could simply creat the page as a web page link, but I really wanted it diplayed with the discription.

    I tried this..
    <?php

    include('/catalog/DecalMenu.htm');

    ?>
    I even tried this....

    <!--WEBBOT BOT="Include" U-Include="cataolg/DecalMenu.htm" TAG="BODY" startspan -->
    Suggestions would be great.
    [/quote]

  2. #2
    New Member
    Join Date
    May 2004
    Location
    Philadelphia, USA
    Posts
    10
    Rep Power
    0


    Default

    If I understand your question correctly, I suppose you could put the product description in "catalog/product_info.php" - either put your text in the HTML or put a php include to a file there as outlined below.

    Around line 137 look for:
    Code:
    <p><?php echo stripslashes($product_info['products_description']); ?></p>
    and put this directly above it:
    Code:
    <p><?php include('/catalog/DecalMenu.htm'); ?></p>
    Another way (if you're comfortable with SQL commands) may be to simply put it in as the default text in the "products_description" column in the "products_description" table in the database. That way, when you create a new instance of this product it will have the product description text in there already.

    As far as adding the description to over 60 products already in the database, you could do a SQL command like this to update every product description in one shot:

    In the "products_description" table run this SQL command:
    (NOTE: This will write over existing product descriptions)

    Code:
    UPDATE products_description SET products_description = 'Your Product Description Here';

Similar Threads

  1. product attributes - "option type" dropdown missin
    By test_fsait in forum osCMax v2 Features Discussion
    Replies: 12
    Last Post: 02-13-2007, 05:05 PM
  2. Remove "QTPRO" for "Option Type Feature"
    By adam71o in forum osCmax v2 Customization/Mods
    Replies: 3
    Last Post: 01-10-2007, 09:32 AM
  3. "Price" and "Add to Cart" button inside
    By midwestwebsites in forum osCmax v2 Customization/Mods
    Replies: 3
    Last Post: 11-14-2005, 04:13 AM
  4. "Product Expected" date incorrect by EZPopulate
    By bjrafferty in forum osCmax v1.7 Discussion
    Replies: 0
    Last Post: 09-14-2004, 02:10 PM
  5. Change "Product Listing" header in CPATH to image.
    By ritalcnyc in forum osCommerce 2.2 Modification Help
    Replies: 1
    Last Post: 11-22-2003, 01:38 PM

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
  •