glow Posted November 21, 2014 Share Posted November 21, 2014 (edited) I have this Shopping cart that allows for the creation of products with product sizes and so if a customer purchases a shirt which regular price is $10 but he/she chooses a large size which is marked @ $12 then of course the shopping cart then charges $12 - then the customer receives a purchase notification email defining the purchase of the $12 size large shirt, and thats all fine except that currently the notification email defines the shirt with $0.00 price in a row and in another row it defines the shirt size with the $12.00 price. So it basically defines the product twice, and i don't want it to do that. I want the product price and size to all be included in the same row. Attached is the .php file that needs the modification. I had a developer tell me that it could not be done. Can someone please have a look at this file and tell me if its true that what I want cannot be done! - all i want to do is merge those two rows together. I've attached the php that is responsible for writing the tables containing the purchased items. orderSaveAjax.php Edited November 21, 2014 by glow Quote Link to comment Share on other sites More sharing options...
glow Posted November 21, 2014 Author Share Posted November 21, 2014 And here is a screenshot showing the the item and price rows. i took this screen shot from a sample order notification email. Quote Link to comment Share on other sites More sharing options...
hansford Posted November 22, 2014 Share Posted November 22, 2014 You can add another column to each row for size or you can display the product and size in one column. Either way, you'll have to use some logic to check if the product has a size. You can't have one row with such and such columns and another row with something different though - there needs to be consistency when you're pulling this data from the database. You can put in IF statements to determine if that product has a size that's not NULL or some other value and then display it if it does or display something like "N/A" if it doesn't. You might be asking the developer to do something that is impossible like only adding a column to certain rows, but not others. Quote Link to comment Share on other sites More sharing options...
glow Posted November 22, 2014 Author Share Posted November 22, 2014 Thank you for your post, i thought the same, can I pay you to modify that file as you have explained? Quote Link to comment Share on other sites More sharing options...
hansford Posted November 22, 2014 Share Posted November 22, 2014 Unfortunately, I already have a job that keeps me busy. However, there are many hungry freelancers out there who will take on small projects like you have. They will bid and compete against one another. Not always wise to choose the cheapest bid, but look at their reputation and their experience to make your decision. https://www.freelancer.com/ Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.