We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 32046
    • 75 Posts
    I’m new to MODx and looking at creating websites which require basic shopping cart functionality and merchant account processing. I’ve done this a couple of times previously using straight php/html and also in frameworks like CodeIgniter and Kohana.

    DONT wants:
    - don’t want to use a hosted cart system.
    - don’t want a complex non-MODx cart system integrated into MODx

    Wants:
    - SIMPLE system, consisting of a cart contents page, name, delivery address etc page, and obviously product pages with an ADD button.
    - up to 2000 products
    - email results to owner, and perhaps add orders to an orders database for record keeping purposes.

    Questions:
    1. Is it feasible for 2000 products (using TVs for detail) to allow the site owner to simply add each product as a new document/resource (using containers to divvy them into managable catagories), or should each product simply be a database entry and use a custom form for adding/editing products? How many documents/resources can MODx (Evo) handle?
    2. Does every user to a MODx site automatically have a session created, or would this need to be done seperately? I need to track users obviously and add cart contents to a database referenced by session.
    3. Am I doing this the hard way, is there a better option?


      • 28042 ☆ A M B ☆
      • 24,524 Posts
      Yes to the first part; in fact there are a few "shopping cart" add-ons available already. I’m liking the looks of this one http://wiki.modxcms.com/index.php/GCart (later version available here as a zip file at the bottom of the post http://modxcms.com/forums/index.php/topic,20905.msg129163.html#msg129163 )

      Evo is known to handle up to 5,000 documents without any problems; after that it takes some tweaking of the caching subsystem (or more powerful hardware) to avoid slowdowns. Somebody on the forums has described a way of running 50,000 documents with a modification to the caching.

      Every visitor gets a SESSION file; this gets filled up with various fields on login. http://www.sottwell.com/article-sessions.html

      I have found that for critical applications, it’s best to combine a custom cookie with the SESSION, as different server configurations will timeout the session at different intervals.

      You’ve got the right idea; MODx is a lot like Legos; MODx itself provides the base plate, and you just add on ... er... add-ons, either something already available or your own custom add-ons. This may be of use http://www.sottwell.com/modx-from-the-inside.html

        Studying MODX in the desert - http://sottwell.com
        Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
        Join the Slack Community - http://modx.org