Results 1 to 6 of 6
  1. #1
    Join Date
    Mar 2007
    Posts
    18
    Plugin Contributions
    0

    Default Include an html page in a product description? (server side includes)

    Does anyone know if it is possible to include an html page within the product description?

    I have tabs installed and rather than doing text for each tab, I would like to use a pre-written html page that is generated by a script that I run locally.

    The script puts everything in nice tables with images, descriptions, etc. then generates an html page for it.

    I just need to "include" that page in my product description so that it will be displayed below the product description tab.

    Thanks!

    Joseph Woodall

  2. #2
    Join Date
    Sep 2006
    Posts
    542
    Plugin Contributions
    0

    Default Re: Include an html page in a product description? (server side includes)

    add a new folder inside your includes folder and name it text_blocks.

    Open a blank html page. (don't use head,body or html on off tags. Add your html formatted content to that page save it as added_descriptions.html and save it inside the text_blocks folder.

    So far you have cart/includes/text_blocks/added_descriptions.html

    Open your product discription and where you would like the html content, add this code.

    <td width="100&#37;" valign="top"><table border="0" width="100%" cellspacing="0" cellpadding="0">
    <tr> <td> <?php include('includes/text_blocks/added_descriptions.html'); ?> </td></tr>
    </table>
    </td>

  3. #3
    Join Date
    Aug 2006
    Posts
    166
    Plugin Contributions
    2

    help question Re: Include an html page in a product description? (server side includes)

    Quote Originally Posted by usernamenone View Post
    add a new folder inside your includes folder and name it text_blocks.

    Open a blank html page. (don't use head,body or html on off tags. Add your html formatted content to that page save it as added_descriptions.html and save it inside the text_blocks folder.

    So far you have cart/includes/text_blocks/added_descriptions.html

    Open your product discription and where you would like the html content, add this code.

    <td width="100%" valign="top"><table border="0" width="100%" cellspacing="0" cellpadding="0">
    <tr> <td> <?php include('includes/text_blocks/added_descriptions.html'); ?> </td></tr>
    </table>
    </td>
    your answer is what I looked for some months and without answer. I did your instructions, but I didn't get any results:
    this is what I did:
    1- includes/-->make directory name: text_blocks
    2- put this html file: form1.html
    ----- bof contents of the file-----
    <form id="form1" name="form1" method="post" action="MAILTO:****.com">
    <label for="textfield">
    <div align="right">car type </div>
    </label>
    <div align="right">
    <label for="label"></label>
    <p>
    <input type="text" name="textfield2" id="label" />
    </p>
    <p>
    <label for="label2">id number </label>
    </p>
    <p>
    <input type="text" name="textfield" id="textfield" />
    </p>
    <p>
    <label for="select">fuel<br />
    </label>
    <select name="select" id="select">
    <option>benzin</option>
    <option>gasoil</option>
    <option>gas</option>
    <option>mixed</option>
    </select>
    </p>
    <p>
    <label for="textarea">comments<br />
    </label>
    <textarea name="textarea" cols="60" rows="6" id="textarea"></textarea>
    </p>
    <p>
    <label for="label2">external color <br />
    </label>
    <input type="text" name="textfield3" id="label2" />
    </p>
    <p>
    <label for="Submit">send</label>
    <input type="submit" name="Submit" value="Submit" id="Submit" />
    <label for="label3"><br />
    <br />
    reset</label>
    <input type="reset" name="Submit2" value="Reset" id="label3" />
    </p>
    </div>
    </form>

    ----eof contents of the file----------
    3- add this to product info in admin page of some products:
    <td width="100%" valign="top"><table border="0" width="100%" cellspacing="0" cellpadding="0">
    <tr> <td> <?php include('ncludes/text_blocks/form1.html'); ?> </td></tr>
    </table>
    </td>


    add product, and in product page in frontshop, nothing from this form.
    I did it also with html and body tags, but no change.
    any idea?

  4. #4
    Join Date
    Sep 2006
    Posts
    542
    Plugin Contributions
    0

    Default Re: Include an html page in a product description? (server side includes)

    A couple of things: Your bof content of file needs to be removed and you don't use any html, head or body tags.

    Try this . open notepad and paste this in

    <table width="100&#37;">
    <tbody>
    <tr>
    <td>
    <form id="form1" name="form1" method="post" action="MAILTO:****.com">
    <label for="textfield"></label>
    <div align="right"><label for="textfield">car type</label></div>
    <label for="textfield"></label>
    <div align="right">
    <label for="label"></label>
    <p>
    <input type="text" name="textfield2" id="label" />
    </p>
    <p>
    <label for="label2">id number </label>
    </p>
    <p>
    <input type="text" name="textfield" id="textfield" />
    </p>
    <p>
    <label for="select">fuel<br />
    </label>
    <select name="select" id="select">
    <option>benzin</option>
    <option>gasoil</option>
    <option>gas</option>
    <option>mixed</option>
    </select>
    </p>
    <p>
    <label for="textarea">comments<br />
    </label>
    <textarea name="textarea" cols="60" rows="6" id="textarea"></textarea>
    </p>
    <p>
    <label for="label2">external color <br />
    </label>
    <input type="text" name="textfield3" id="label2" />
    </p>
    <p>
    <label for="Submit">send</label>
    <input type="submit" name="Submit" value="Submit" id="Submit" />
    <label for="label3"><br />
    <br />
    reset</label>
    <input type="reset" name="Submit2" value="Reset" id="label3" />
    </p>
    </div>
    </form>
    </td>
    </tr>
    </tbody>
    </table>

    Then this has an error in it and should read as:

    <td width="100%" valign="top"><table border="0" width="100%" cellspacing="0" cellpadding="0">
    <tr> <td> <?php include('includes/text_blocks/form1.html'); ?> </td></tr>
    </table>
    </td>

    Next: I am not too sure a form will work but may with the correct path

  5. #5
    Join Date
    Aug 2006
    Posts
    166
    Plugin Contributions
    2

    Default Re: Include an html page in a product description? (server side includes)

    hi thanks for reply. off course I didn't put bof and eof in the html file.
    I tried with your table codes with the correction of the echo script in product page, again withut results.
    for chacking your point, I wrote only one line and saved instead of form1.html, so even with a simple line without form etc, still diesn't work;
    I suppose there is a problem in the <?php include ...., because it doesn't request the form1.html,

  6. #6
    Join Date
    May 2007
    Posts
    10
    Plugin Contributions
    0

    Default Re: Include an html page in a product description? (server side includes)

    Hi,

    Any solution. This is what I want to accomplish also. The above does not work, sorry.

 

 

Similar Threads

  1. You don't have permission to access /admin/includes/index.html on this server.
    By simms in forum Installing on a Linux/Unix Server
    Replies: 2
    Last Post: 6 Aug 2011, 05:31 PM
  2. Add product html form code On Product Description page
    By ivogue in forum Setting Up Categories, Products, Attributes
    Replies: 0
    Last Post: 4 Mar 2009, 07:54 PM
  3. How to include other page to product description
    By marksu in forum Setting Up Categories, Products, Attributes
    Replies: 2
    Last Post: 11 Dec 2008, 12:47 AM
  4. Html Form On Product Description page
    By fxpro in forum Setting Up Categories, Products, Attributes
    Replies: 10
    Last Post: 22 Oct 2008, 04:32 PM
  5. EZ-Pages and server side includes
    By GTrotter in forum General Questions
    Replies: 2
    Last Post: 28 May 2007, 12:41 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
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR