Page 1 of 4 123 ... LastLast
Results 1 to 10 of 33
  1. #1
    Join Date
    Dec 2010
    Posts
    14
    Plugin Contributions
    0

    Default Custom page to have the layout of products catalog

    Hello everyone.

    I have a custom page that I want to look EXACTLY like the
    ?main_page=index&cPath=whatever

    the only difference is cPath won't work for me anymore (unfortunately, thus I have to to write custom php to query products table and find the products I want to include depending on a custom column in products).

    So I need to show the same layout but make sure the data is differently filtered. What to do? I've been struggling with this issue and cannot seem to find one place to say how index&cPath is rendered so I can alter the SQL query and force mine there (or I'll have to do this eitherway in my custom page)

  2. #2
    Join Date
    Aug 2005
    Location
    Arizona
    Posts
    27,755
    Plugin Contributions
    9

    Default Re: Custom page to have the layout of products catalog

    only difference is cPath won't work for me anymore (unfortunately
    Why is this?
    Zen-Venom Get Bitten

  3. #3
    Join Date
    Dec 2010
    Posts
    14
    Plugin Contributions
    0

    Default Re: Custom page to have the layout of products catalog

    in the database, there are 6 categories for products. but each product has a custom column which is more detailed categories and now we want to use that one sometimes. So we're happy with the 6 categories but we wanna give the user more options if he wants to go deep (I know about cPath being able to do ABC_EFG where EFG is a subcategory of ABC [if I understand correctly]) but as the database is already different I cannot do that either.

    Thus I need a method to show the same layout with just different data (I know the SQL I want to write)

  4. #4
    Join Date
    Aug 2005
    Location
    Arizona
    Posts
    27,755
    Plugin Contributions
    9

    Default Re: Custom page to have the layout of products catalog

    Load your page and get the url end

    Such as
    Code:
    /index.php?main_page=my_page
    Then make a folder in /your template/my_page/

    Put a custom copy of tpl_main_page.php in it

    Customize this to your needs
    Zen-Venom Get Bitten

  5. #5
    Join Date
    Dec 2010
    Posts
    14
    Plugin Contributions
    0

    Default Re: Custom page to have the layout of products catalog

    kobra thanks for helping man.
    Since I 've read the wiki on how to create a new page, you're saying the product listing layout is in tpl_main_page.php page and all I have to do is what then? I've looked into the page (can be found also http://phpxref.com/xref/zencart/incl...hp.source.html) and nowhere does it include the layout I want nor the sql query to change. It just goes on to include other tpl_ files and I lose it from there

  6. #6
    Join Date
    Aug 2005
    Location
    Arizona
    Posts
    27,755
    Plugin Contributions
    9

    Default Re: Custom page to have the layout of products catalog

    you're saying the product listing layout is in tpl_main_page.php page
    Actually not - - Default Product layout in tpl_product_info_display.php but I am guessing you are not using it as there is only one and you state you have 6 layouts
    Zen-Venom Get Bitten

  7. #7
    Join Date
    Dec 2010
    Posts
    14
    Plugin Contributions
    0

    Default Re: Custom page to have the layout of products catalog

    koba, thanks again for helping me and sorry to confuse you.
    I don't have 6 layouts. I have 6 cPaths and I cannot add more there.
    I have a lot of products belonging to one of those 6 cpaths. I also have a special column for those products. I want to use that column to feed the same page or another page I don't mind as long as it keeps the same layout and form as the one with cPath.

    This is what I want to do, I hope you can you help me. (I'm a rookie in zencart, but not to programming)

    so what I want is ?main_page=index&cPath=WHATEVER&myCOL=ABC or even better ?main_page=index&myCol=ABC and this should show all those products that have myCOL=ABC (myCol is an extra col I've added in the products table) or at worse ?main_page=mypage?myCol=ABC (but mypage show use the layout of index?myCol and where is that and how to do that)

  8. #8
    Join Date
    Aug 2005
    Location
    Arizona
    Posts
    27,755
    Plugin Contributions
    9

    Default Re: Custom page to have the layout of products catalog

    I don't have 6 layouts. I have 6 cPaths and I cannot add more there.
    I have a lot of products belonging to one of those 6 cpaths.

    I also have a special column for those products.
    From your explanation, I do not understand what it is you are attempting.
    Zen-Venom Get Bitten

  9. #9
    Join Date
    Jan 2004
    Location
    N of San Antonio TX
    Posts
    9,684
    Plugin Contributions
    11

    Default Re: Custom page to have the layout of products catalog

    This is one of those where we REALLY need some of the information from the posting tips!

    Can't imagine a limit on cpath
    A little help with colors.
    myZenCartHost.com - Zen Cart Certified, PCI Compatible Hosting by JEANDRET
    Free SSL & Domain with semi-annual and longer hosting. Updating 1.5.2 and Up.

  10. #10
    Join Date
    Dec 2010
    Posts
    14
    Plugin Contributions
    0

    Default Re: Custom page to have the layout of products catalog

    ok I'll try to rephrase:
    products table:
    Code:
    pid cpath specialCol
    1    1234   155
    2    1234   156
    3    1235   155
    4    1234   188
    I want to show a page asking products where specialCol is 155 and this page ideally should have the looks like the one shown if I do cPath=1234

 

 
Page 1 of 4 123 ... LastLast

Similar Threads

  1. Changing the Products Page Layout
    By dereklord in forum Templates, Stylesheets, Page Layout
    Replies: 3
    Last Post: 2 Oct 2011, 07:59 PM
  2. Can you have a catalog and a cart on the same site?
    By adelante in forum General Questions
    Replies: 2
    Last Post: 18 Feb 2009, 11:37 PM
  3. How to layout Multiple item on each catalog page
    By Paulgordon in forum Templates, Stylesheets, Page Layout
    Replies: 1
    Last Post: 6 Jan 2009, 09:49 PM
  4. Want to have All Products view inherit same "column" layout of Category Listings page
    By dara108 in forum Templates, Stylesheets, Page Layout
    Replies: 6
    Last Post: 31 Dec 2008, 10:17 PM
  5. How can I have random products in the center column of the zencart first page.
    By lifetimewebhost in forum Templates, Stylesheets, Page Layout
    Replies: 2
    Last Post: 12 Nov 2007, 07:49 PM

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