Results 1 to 10 of 570

Hybrid View

  1. #1
    Join Date
    Apr 2006
    Location
    London, UK
    Posts
    10,569
    Plugin Contributions
    25

    Default Re: How do EZ-Pages work?

    @highlander2

    If I understand correctly, have created information in an EZ-Page that you want to be available on, for example, the product information page for some products.

    If that is the case, then EZ-Pages is not the right solution. That is used for building or re-directing to whole pages. Although you could probably display the page inside an iframe, it would have all the headers, sideboxes and footers duplicated inside the frame and would look gross.

    What you actually need to use is to create a new file in your languages/english/html_includes folder and then use the Define Pages Editor to edit the content. This is the editor that deals with blocks of HTML that can be inserted into pages, as opposed to whole pages.

    You would then need to add something such as the following to your tpl_product_info_display.php template
    PHP Code:
    if (in_array($_GET['products_id'], explode(",",'1,2,3,101,102,103'))) {
        include(
    zen_get_file_directory(DIR_WS_LANGUAGES $_SESSION['language'] . '/html_includes/''YOUR_DEFINE_FILENAME''false');

    in order to include the text for those pages where it is relevant.

    Note - I have not tested this specific code, but use similar approaches to add new content about age suitability, product FAQs and awards won on this site currently under development.
    Kuroi Web Design and Development | Twitter

    (Questions answered in the forum only - so that any forum member can benefit - not by personal message)

  2. #2

    Default Re: How do EZ-Pages work?

    Quote Originally Posted by kuroi View Post
    @highlander2


    What you actually need to use is to create a new file in your languages/english/html_includes folder and then use the Define Pages Editor to edit the content. This is the editor that deals with blocks of HTML that can be inserted into pages, as opposed to whole pages.

    You would then need to add something such as the following to your tpl_product_info_display.php template
    PHP Code:
    if (in_array($_GET['products_id'], explode(",",'1,2,3,101,102,103'))) {
        include(
    zen_get_file_directory(DIR_WS_LANGUAGES $_SESSION['language'] . '/html_includes/''YOUR_DEFINE_FILENAME''false');

    in order to include the text for those pages where it is relevant.

    Note - I have not tested this specific code, but use similar approaches to add new content about age suitability, product FAQs and awards won on this site currently under development.
    Thanks Kuroi ! The product FAQ example you provided above is what I am looking for.
    The information is essentaially optional for interested people to view. Including it all in the product description would make the page very long and I think would turn off some people.

    How do I do the Product FAQ example you listed?

  3. #3
    Join Date
    Apr 2006
    Location
    London, UK
    Posts
    10,569
    Plugin Contributions
    25

    Default Re: How do EZ-Pages work?

    Quote Originally Posted by highlander View Post
    How do I do the Product FAQ example you listed?
    I gave that primarily as an example of the ease with which additional content can be added to the product_info page rather than as a specific answer to your question. But here goes:
    1. add a table to your database to hold the FAQs
    2. create an Admin page to add, edit and delete entries for a particular product ID
    3. add an icon to the categories_product_listing page in Admin to call the previously described Admin page using the product ID in a $_GET variable
    4. Add a javascript routine to open and close the entries by toggling the divs display styles (there's info about how to add javascript in your site's docs folder)
    5. build a module file to extract entries from the database for the current product_info page's products_id
    6. build a template module file to display this in a simple HTML (DIV-based) structure
    7. Style with CSS for maximum effect.

    If you are familiar with these technologies (SQL, HTML, PHP, CSS and javascript) and have a basic understanding of the way in which pages are constructed in the Admin and Catalog, none of this is very difficult. I guess the challenge would be that, unsually, it requires some knowledge of pretty well everything used to build a Zen Cart.
    Kuroi Web Design and Development | Twitter

    (Questions answered in the forum only - so that any forum member can benefit - not by personal message)

 

 

Similar Threads

  1. v154 Links ON ez-pages TO OTHER turned-off ez-pages don't work after upgrade
    By anduril3019 in forum Upgrading to 1.5.x
    Replies: 2
    Last Post: 19 May 2015, 09:12 AM
  2. how do i get javascript to work in the ez pages?
    By warroyo90 in forum General Questions
    Replies: 2
    Last Post: 28 Mar 2012, 05:14 AM
  3. How can I get my CSS navigation tabs to work for groups of similar pages?
    By sifuhall in forum Templates, Stylesheets, Page Layout
    Replies: 0
    Last Post: 27 Nov 2009, 07:57 PM
  4. Replies: 3
    Last Post: 22 Jul 2008, 12:01 AM
  5. Bwahahaha How do I get ez-pages to work?
    By hodgejr in forum General Questions
    Replies: 7
    Last Post: 8 Oct 2007, 09:10 AM

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