Results 1 to 6 of 6

Hybrid View

  1. #1
    Join Date
    Aug 2006
    Posts
    27
    Plugin Contributions
    0

    Default Multiple distinct Departments (stores) using one install?

    Hi everyone. This is my first post here, although I've been sneaking around in the shadows for the past few weeks. I'm glad I found ZenCart as it making my new business much easier. :) I'm an experienced web developer and have found the code to be very clean and useful for me.

    I have a question although I'm not sure how to word it. Hmmm... I need multiple store departments using a single install of Zencart. What I would like to have is each department acting as if it were it's own store, with it's own templates, styles, define pages, sideboxes, products and categories.... the stores would share admins, customers, and everything else.... it would be real nice to set this up with subdomains: i.e. store1.mydomain.com, store2.mydomain.com, and store3.mydomain.com, each sending the customer to the respective set of product categories. Of course it would be better based on my hosting/SSL if I could just pass the department via URL.

    Basically the departments would be the top-level categories in the admin. But I don't want the store to use top level categories in the categories sidebox or in the header. Instead, depending on whatever department is selected, the second level categories are *considered* the actual categories (i.e. they show up in the cat header and sidebox). I currently have plans to create a new sidebox that displays the departments (just links to the top level categories) seperate from the deeper categories.

    Hmmm.. another way to word it? I do not want top-level categories.. instead I want several stores, each starting at the second level categories.

    To put this into perspective, my business is hobbies. I (currently) have 3 distinct departments, each targetting specific customer types (thus the look and approaches will be different for each departments) - radio control, arts and crafts, and games.

    Ok, that's probably confusing more than explaining what I want... :)


    I've been reading up some threads and found some very useful info (for those interested in doing similar things):

    Top Level Categories
    http://www.zen-cart.com/forum/showthread.php?t=40711

    Multiple Stores
    http://www.zen-cart.com/forum/showthread.php?t=36709

    Category Setup
    http://www.zen-cart.com/forum/showthread.php?t=41682

    More Top Level Categories
    http://www.zen-cart.com/forum/showthread.php?t=30618

    Different Stores One Checkout
    http://www.zen-cart.com/forum/showthread.php?t=23016

    Limited Category Access
    http://www.zen-cart.com/forum/showthread.php?t=8024

    So are those the recommended ways to do what I want? Or are there other ways? Any suggestions on how to proceed?



    ------------

    After that comes integration into shipping info modules and a project I'm looking forward to, integration with GoogleCheckout Level2. I'd rather code that one myself since I know I'll have some strange requirements... fun fun... GOOD DAY! end_ramble

    Thanks!
    - Bob

  2. #2
    Join Date
    Jan 2004
    Posts
    66,450
    Plugin Contributions
    81

    Default Re: Multiple distinct Departments (stores) using one install?

    Bob,

    Welcome to Zen Cart.

    I'll pick up rambling where you left off

    Would the following strategy work equally well?

    - One Store
    - subdomains configured to redirect the shopper to the appropriate top-level cat
    - when a product is part of a particular top-level category, the appropriate template is displayed, instead of the default site-wide template

    This could be accomplished by a PHP header-redirect in an index.php in each subdomain folder, and a bit of fancy coding with product types and data-detection in order to determine which template to display at a given time.

    Naturally, your special sideboxes would be used in order to mask the top-level components if you so desired.
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  3. #3
    Join Date
    Aug 2006
    Posts
    27
    Plugin Contributions
    0

    Default Re: Multiple distinct Departments (stores) using one install?

    Quote Originally Posted by DrByte
    Bob,

    Would the following strategy work equally well?

    - One Store
    - subdomains configured to redirect the shopper to the appropriate top-level cat
    - when a product is part of a particular top-level category, the appropriate template is displayed, instead of the default site-wide template

    This could be accomplished by a PHP header-redirect in an index.php in each subdomain folder, and a bit of fancy coding with product types and data-detection in order to determine which template to display at a given time.

    Naturally, your special sideboxes would be used in order to mask the top-level components if you so desired.
    Interesting. Thanks for the info! I have not spent much time using the product types feature as I never planned on having more than one type. I'll start to look into that this evening and see what things stir up in my mind. The redirect would be simple enough too.

    I think I'm going to seperate this entire mini-project into two parts. First getting the zen cart to display different top-level categories based on department. Then once I get that working I'll focus more on the template layout splitting.

    Any other thoughts on these two parts?

  4. #4
    Join Date
    Aug 2006
    Posts
    27
    Plugin Contributions
    0

    Default Re: Multiple distinct Departments (stores) using one install?

    Quote Originally Posted by damonp View Post
    As each of my sites has a different category and product layout, I created a top level category for each site, then modified the the category and product SQL to only look under the current site's top level category.
    I found the above quote in another thread. And here are my thoughts.

    ****
    This is exactly what I planned on doing with my site. I want one installation with one database. I'm wondering though, how much work this includes.

    I have 4 departments to my store. Each department will have it's own template, products, and categories. They will all share the same customer data. Each department will only show featured/all products from the correct department. I want all of these products and categories to be managed from within a single install of the admin tool.

    It was suggested to me earlier that I just make 4 top-level categories (and the appropriate products inside them), however I found the visual results to be ugly. I do not want the top-level categories to show up on the page (in the header or in the sidebox) nor do I want the listings/displays to include products from other top-level categories.

    So, if a customer goes to the ARTS department, only the second level categories are displayed (as if they were top-level) and only those ARTS products would be displayed in the many pages. When the customer wants to go to the SCIENCE department, they choose that option and are sent to the index.php page that now shows a different set of (second level) categories. All cart data and whatnot is shared since it is the same site.

    I will make a custom section (sidebox or header) that sends the customer to the different departments. This could work in several ways. First, I could pass the value via URL to set a global var. I could also store settings in the DB. Either way, the customer is always assigned to a department which should affect the categories and products that get displayed.


    Other sections I feel I need to visit (and modify sql, etc):
    - breadcrumbs - (might not want to show department level)
    - search (and advanced search) feature - (might just combine all departments)
    - featured/all product listings and sideboxes - (limit to current department)
    - site map - (might just combine all departments)


    I have also been looking at the http://www.zen-cart.com/forum/showth...ultiple+stores thread which I suspect it does something similar to what I want to do. The problem with this is that it isn't released as of yet.

  5. #5
    Join Date
    Aug 2006
    Posts
    27
    Plugin Contributions
    0

    Default Re: Multiple distinct Departments (stores) using one install?

    Bump and shout out!

    I'm getting closer to launching my first zencart (end of Feb targetted)... soon after that, I want to begin adding the additional departments using the above techiniques...

    I'm hoping we get a response from Absolute soon on his addon.

    Cheers,
    Bob

  6. #6
    Join Date
    Aug 2006
    Posts
    27
    Plugin Contributions
    0

    Default Re: Multiple distinct Departments (stores) using one install?

    Thanks to some friendly forum goers, I've been able to tackle this problem. I did all the code myself, but used ideas from you all to help me along.


    Here is a post from another thread that may or may not be useful for anyone searching threads about similar topics:

    ***************************
    I was able to use the Developer's toolkit to find most of the locations where TABLE_CATEGORIES was used. I modified these to include a check for the current department. I've also modified several queries that pull all products regardless of category (thus the category table was not found with the toolkit). And finally I created a sidebox that lists the departments (which is how I am using this concept) and allows the user to change to whichever view they want. (uses application_top.php, URL params, and SESSION vars to handle this).

    All in all, it was much easier than I first thought it would be. I've also developed a few secondary pages that allow me to administer the departments via the frontend as well as assign/modify categories to the departments.

    Now that the bulk of the work is done, I want to go back and winMerge compare the files with the originals because I know there were several places where I modified the originals instead of the overrides (ugg!). I'm also starting to pickup on some of the Zencart API... honestly, I'd rather write stuff myself, but it's nice to know that stuff... is there any detailed documentation on the Zencart API????

    Once the system is ready from a data standpoint, I want to modify it to use a different stylesheet depending on the department selected. So if someone is in the Toys department, they will see bright colors and matching header images, but while in Electronics department the colors will be more metalic and the imagery more techo... at least that's the plan.

 

 

Similar Threads

  1. how to install multiple stores?
    By antics83 in forum General Questions
    Replies: 1
    Last Post: 27 Jan 2011, 02:47 PM
  2. Multiple Stores in one installation sharing one database
    By bajanboost in forum General Questions
    Replies: 16
    Last Post: 9 Jul 2008, 04:58 PM
  3. One PayPal - Multiple Stores
    By milkyway in forum Built-in Shipping and Payment Modules
    Replies: 4
    Last Post: 21 Sep 2006, 01:56 AM
  4. Replies: 3
    Last Post: 29 May 2006, 04:18 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