Register

If this is your first visit, please click the Sign Up now button to begin the process of creating your account so you can begin posting on our forums! The Sign Up process will only take up about a minute of two of your time.

Results 1 to 9 of 9
Like Tree4Likes
  • 1 Post By mlseim
  • 1 Post By TheGAME1264
  • 1 Post By mlseim
  • 1 Post By RDesignista

Thread: I plan to make a very simple shopping cart. Any tips?

  1. #1
    Senior Member RDesignista's Avatar
    Join Date
    Feb 2012
    Location
    Coconut Tree City
    Posts
    822
    Member #
    30921
    Liked
    123 times

    I plan to make a very simple shopping cart. Any tips?

    Hi.

    I am making a custom, purchase order system in Wordpress. Purchase order just means people add what they want to the cart and then just hit "make order" and the contents of their cart is emailed to the admin -- no monetary transactions are made.

    I didn't want a full-fledged e-commerce tool... because I did not want the clutter associated with it. I also figured that I should familiarize myself with sessions and mysql writing. So, I am finishing up making the forms for my product pages.

    Can you advise me if this process is correct? And can you let me know if this is easy to do?

    * must be logged in
    1. have "add product" on each product page
    2. create sessions (is there a default expire time?)
    3. create a table in the database to record all orders that go through... store as array.
    4. create phpmail function to mail purchase order notes to admin
    5. create something on the admin side to show full list of past orders
    6. create something on user profile page that shows all previous orders

  2.  

  3. #2
    WDF Staff mlseim's Avatar
    Join Date
    Apr 2004
    Location
    Cottage Grove, Minnesota
    Posts
    7,686
    Member #
    5580
    Liked
    716 times
    I had a client who wanted the very same thing.

    What I did was have them use a WordPress with Woocommerce. Everything looked like a normal online store with "add to cart" buttons, etc.

    The difference was the payment gateway. I used the Woocommerce "pay by check" gateway (plugin). That means they fill their cart, submit their order, and the order gets emailed to someone (or put into a database). There is no credit card payment because they are supposed to send a check in the mail.

    tada! it worked great for them.
    RDesignista likes this.


  4. #3
    Senior Member RDesignista's Avatar
    Join Date
    Feb 2012
    Location
    Coconut Tree City
    Posts
    822
    Member #
    30921
    Liked
    123 times
    thanks msleim. my initial thought was woocommerce too. i did not want to use it because i thought it was a bit robust for my needs. but at the moment, i might have to because i'm not sure i'll have time to create the site as well as learn how to create sessions, create a cart, an email script, log orders in the backend, and allow customer to see their order history. i need to get better at php, seriously :\.

  5. #4
    Unpaid WDF Intern TheGAME1264's Avatar
    Join Date
    Dec 2002
    Location
    Not from USA
    Posts
    14,485
    Member #
    425
    Liked
    2783 times
    I don't know if WooCommerce will do what you wish. I've used it exactly once, and ended up solving several problems with a WP site I'm working on (very reluctantly) simply by removing it outright.

    What I will tell you is this...the cart idea you have is very unlikely to work, regardless of what you use. I've built carts that do exactly this...take an order and submit details to the client without generating a payment. The big problem that you face isn't technical, but emotional/knee-jerk, and it's not immediately obvious. You'll get a large percentage of flighty people that will place an order and not think about it since they don't have to pay for it using a credit card or PayPal and then they forget about it because they didn't pay. As soon as the client goes to collect, "well, you didn't charge me at the time, and now I don't want it any more." The client has no way of collecting the money, and the transaction is null and void. It's insane, it's stupid, but it happens.

    Check payment is fine as an option. It's not fine as the​ option.
    RDesignista likes this.
    If I've helped you out in any way, please pay it forward. My wife and I are walking for Autism Speaks. Please donate, and thanks.

    If someone helped you out, be sure to "Like" their post and/or help them in kind. The "Like" link is on the bottom right of each post, beside the "Share" link.

    My stuff (well, some of it): My bowling alley site | Canadian Postal Code Info (beta)

  6. #5
    WDF Staff mlseim's Avatar
    Join Date
    Apr 2004
    Location
    Cottage Grove, Minnesota
    Posts
    7,686
    Member #
    5580
    Liked
    716 times
    I totally agree, but the original post specifically mentions "no monetary transactions are made".

    That's what I based my idea on.
    TheGAME1264 likes this.


  7. #6
    Senior Member RDesignista's Avatar
    Join Date
    Feb 2012
    Location
    Coconut Tree City
    Posts
    822
    Member #
    30921
    Liked
    123 times
    Hey guys, thanks for the input.

    So actually, I ended up just doing it myself with some PHP, a members plugin, and PHP sessions. Avoided having to work with a full-fledged ecommerce plugin. I was thinking of hiring a PHP guy to do this for me, but I'm glad I did it myself cause it's a great exercise to understanding how shopping carts are made.

    For anyone reading this, here's what I did.

    1. There's a great plugin called WP-members that allows you to modify the base wordpress member fields by adding additional ones and also makes it so that you have to approve registrations. I also added PHP sessions that start when a person logs in.

    2. I created a custom post type named "products" and added meta fields (gallery pictures, options).

    3. I molded the product page template so that it shows title, gallery pictures meta fields. And if the user is logged in, I make a form, echo out the title as a readonly input, echo out the options as a dropdown, and make a quantity box. The form submits to a separate php file that adds an array to $_SESSION['items'] using $_POST variables.

    4. On the order page, I echo out the $_SESSION arrays using a foreach loop. Below the order is a "clear" and a "submit" option. Submit sends an email using wp_mail (wordpress function) and then clears the session data and then redirects to a thank you page.

    Voila! I might still hire a PHP developer to make this into a plugin so I could sell it ... cause unfortunately, there just isn't anything out there that does this.

  8. #7
    Unpaid WDF Intern TheGAME1264's Avatar
    Join Date
    Dec 2002
    Location
    Not from USA
    Posts
    14,485
    Member #
    425
    Liked
    2783 times
    Keep in mind if you sell it, the PHP developer will have the code to sell as well. DIY it and sell it.
    If I've helped you out in any way, please pay it forward. My wife and I are walking for Autism Speaks. Please donate, and thanks.

    If someone helped you out, be sure to "Like" their post and/or help them in kind. The "Like" link is on the bottom right of each post, beside the "Share" link.

    My stuff (well, some of it): My bowling alley site | Canadian Postal Code Info (beta)

  9. #8
    Senior Member RDesignista's Avatar
    Join Date
    Feb 2012
    Location
    Coconut Tree City
    Posts
    822
    Member #
    30921
    Liked
    123 times
    Quote Originally Posted by TheGAME1264 View Post
    Keep in mind if you sell it, the PHP developer will have the code to sell as well. DIY it and sell it.
    You bring up an interesting point regarding proprietary rights.

    I would be mindful of the rights in that situation... and made sure I own it. But yes, the developer would have that code.

    Another sticky point is regarding Wordpress and the GPL General Public License. This came up when I started seeing actual Wordpress plugins and themes being resold on 3rd party websites at a discount. I did some reading and it seems because Wordpress is GPL, derivative works may need to be GPL as well, meaning people can modify or resell them. I don't speak confidently about the topic because I need to do a whole lot of reading on this aspect of intellectual property, but that's gonna be a mess to figure out, if I were to do software on a GPL platform.

  10. #9
    Unpaid WDF Intern TheGAME1264's Avatar
    Join Date
    Dec 2002
    Location
    Not from USA
    Posts
    14,485
    Member #
    425
    Liked
    2783 times
    ...which is fine, except that in this case, you're paying a developer for code that (s)he can turn around and resell anyway. If you give him/her $300 and he sells it 15 times for $20 a throw, (s)he just got paid double for one job and took at least $20 out of your pocket in the process i.e. the $20 you could have made selling the plugin to him. Great deal for him/her, horrible deal for you.

    Protect yourself, dude.
    If I've helped you out in any way, please pay it forward. My wife and I are walking for Autism Speaks. Please donate, and thanks.

    If someone helped you out, be sure to "Like" their post and/or help them in kind. The "Like" link is on the bottom right of each post, beside the "Share" link.

    My stuff (well, some of it): My bowling alley site | Canadian Postal Code Info (beta)


Remove Ads

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
All times are GMT -6. The time now is 05:22 PM.
Powered by vBulletin® Version 4.2.3
Copyright © 2019 vBulletin Solutions, Inc. All rights reserved.
vBulletin Skin By: PurevB.com