Forums / Templates, Stylesheets, Page Layout / Newbie needs help simplifying ZenCart - TMI!

Newbie needs help simplifying ZenCart - TMI!

Locked

Started by brain21 on 22 Sep 2006, 6:10 PM · Views: 8,307

Results 1 to 20 of 21
This thread is locked. New replies are disabled.
22 Sep 2006, 6:10 PM
#1
brain21 avatar

brain21

New Zenner

Join Date:
Sep 2006
Posts:
42
Plugin Contributions:
0

Newbie needs help simplifying ZenCart - TMI!

I am working on designing an e-commerce site. I have lots of experience with webdesign both professional and personal. I have zero experience with ZenCart.

I have a book and have been going through it. I have read some of the stickies here.

Here is what I would like to accomplish:

I don't want ZenCart to control the images on the site, there will be no "new products" "Featured products" etc. About the only thing like that that we will use is Gift Vouchers, but that will be later on.

I have the entire site designed and laid out (it's not yet 100% completed though).

You can see it here:

https://www.connequestrian.com - the site is up for viewing, but none of the ZenCart stuff is yet in place.

Take a look at the Ladies Tab.

I will totally control the layout via html & css, I don't need ZenCart to do that for me.

What I need ZenCart for is this:

A customer will pick say a jacket. They will input a size & quantity and click "add to cart"

I want ZenCart to control the cart and checkout process. I also want zencart to sotre their information (like amazon does) for repeat customers. The info stored will be name, address, etc. There will be NO storing of CC info on the site whatsoever. The customer will have to re-enter their card # for each purpose.

I also want ZenCart to integrate with Authorize.net & CDGCommerce for the authorization of the CC transactions, etc. Zen cart will, once the CC has been approved, send emails to our distribution warehouse, and a few other key people.

At this point I am going through all of the configuration stuff and spending hours turning off columns, changing many values (like picture size, etc.) to 0.

Is this the right way to do it? It seems like I am spending most of my time to turn this stuff off. I want ZenCart to control the cart & CC transactions, but not the actual site layout. It seems to me that I must be doing this the LONG way. Myabe that's the only way to do it?

Right now I have a mirror of the website setup on my own personal server at home, and have ZenCart, MyPHPAdmin, etc. all installed on my server at home. My plan was to go through the whole configuration there, and get things close to where I want them. Then take the zencart php code for submitting form data (size quantity, color, etc.) from the product pages to the actual cart itself, and cutting and pasting that into the predefined HTML (the site, with a few exceptions, is not going to be a widely dynamic one, and product lines are very small and will only change about twice a year, at least initially). So the product pages will have a small snippet of ZenCart code to "send"/submit the size, quantity, product ID number (hidden form data) to the actual ZenCart shopping cart for order processing.

What's the best way to set this up? Am I doing this the long way, or am I proceeding slowly along in the best manner?

Curently on the real site the zencart files are in the website's root directory (zencart is not yet active). In my instance, would it be better for organization purposes to place the zencart stuff into a /store directory? I figure that way all of the main website stuff will be in the root, and when a customer places an item in their car, or views either their cart, or their account information they will be directed to a /;store subdir. My thinking is if ZenCart is controlling the whole site layout, etc. putting it in the root dir is a good idea, but when it's just being used for shopping cart, orderprocessing, and account information/retention it might be easier to organize by putting all of that in a /store directory.

Thanks for any help!!!!

Brain21

22 Sep 2006, 7:14 PM
#2
tinas avatar

tinas

Totally Zenned

Join Date:
Jan 2005
Location:
Lake Havasu, AZ
Posts:
1,090
Plugin Contributions:
0

Re: Newbie needs help simplifying ZenCart - TMI!

Hi Brian and Welcome to Zen

For the short answer - you are doing it the best way.

I did the same thing for a client who only wanted to use the checkout portion of zen and this is exactly the way we went about it.

We did however give the Zen cart some styling - the header and such - so that it flowed seamlessly thru the site.

Another thing that helps rather than changing image settings in the admin is to whip thru the css setting images to {display: none;} where you won't be using them.

Hope that helps a little.

When the world gets in my face I say Have A Nice Day.

22 Sep 2006, 8:06 PM
#3
brain21 avatar

brain21

New Zenner

Join Date:
Sep 2006
Posts:
42
Plugin Contributions:
0

Re: Newbie needs help simplifying ZenCart - TMI!

Is there any way to define size, quantity, and color, and a hidden product ID number, and send that to the cart? Without going through the whole tedious process of selecting all of the size attirbutes, color attributes, dropdowns, etc. in the ZenCart stuff?

Like an html form where I would have something like:

<form name="Jacket" action="send_this_stuff_to_zencartcheckout.php" method="get"> <select name="size"> <option value="6792">small</option> <option value="6793">medium</option> <option value="6794" selected="selected">Large</option> </select> <br> <select name="Color"> <option value="6792">red</option> <option value="6793">green</option> <option value="6794" selected="selected">blue</option> </select> <input type="submit" value="Add to cart"> </form>

This would be the only "code" on the standard HTML page.

Then ZenCart would get the form data when the user adds to cart. ZenCart will know that a Jacket is $20 (and the weight for shipping) and it is medium and red. This would be displayed in the checkout, etc.?

Also, the product has different ID#s depending on the size/color/item combination. Anyway to get zencart to handle that s I don't have to write some php or perl code?

Thanks,

Brain21

22 Sep 2006, 8:11 PM
#4
kobra avatar

kobra

Black Belt

Join Date:
Aug 2005
Location:
Arizona
Posts:
31,500
Plugin Contributions:
4

Re: Newbie needs help simplifying ZenCart - TMI!

Hello Brian,

Not to be argumentative, bit to present an oposing view.

Looking at your currently designed page, while, as Tina stated, this can be done, I would suggest that you port this look over to a single column layout right within ZenCart and save yourself and others the troubles associated with having to maintain not only the Zen Cart script but also the html code.

This look can be acheived within the Zen Cart framework quite easily. JMO

Zen-Venom Get Bitten

23 Sep 2006, 4:36 AM
#5
tinas avatar

tinas

Totally Zenned

Join Date:
Jan 2005
Location:
Lake Havasu, AZ
Posts:
1,090
Plugin Contributions:
0

Re: Newbie needs help simplifying ZenCart - TMI!

:no: I didn't say it was the BEST thing to do nor the best way to do it- I simply said it could be done :wink2:
The only reason I did it was because the site owner specifically requested that it be done that way.

When the world gets in my face I say Have A Nice Day.

23 Sep 2006, 4:40 AM
#6
kobra avatar

kobra

Black Belt

Join Date:
Aug 2005
Location:
Arizona
Posts:
31,500
Plugin Contributions:
4

Re: Newbie needs help simplifying ZenCart - TMI!

Tina & Poster,

No argument here...just an optional view.

Zen-Venom Get Bitten

25 Sep 2006, 2:37 AM
#7
bettysue avatar

bettysue

Inactive

Join Date:
May 2004
Posts:
747
Plugin Contributions:
0

Re: Newbie needs help simplifying ZenCart - TMI!

You may be surprised at how you can make Zencart not look like Zencart.

This site was done using v1.27d and is also clothing which is why I thought of it for something like your store:

http://annabrooks.com/index.php?main_page=index

Link is not to give an opinion or promote anything, just an example.

betty

25 Sep 2006, 2:53 AM
#8
barco57 avatar

barco57

Totally Zenned

Join Date:
Apr 2006
Location:
West Salem, IL
Posts:
2,846
Plugin Contributions:
0

Re: Newbie needs help simplifying ZenCart - TMI!

I find this an intriguing thread to bad it got kinda quiet. I am interested in how the sessions are handled as you moved back and forth shopping.

Mike
AEIIA - Zen Cart Certified & PCI Compliant Hosting
The Zen Cart Forum...Better than a monitor covered with post-it notes!

25 Sep 2006, 3:12 AM
#9
brain21 avatar

brain21

New Zenner

Join Date:
Sep 2006
Posts:
42
Plugin Contributions:
0

Re: Newbie needs help simplifying ZenCart - TMI!

I understand that it can be done using the template/override system, and that is basically the way that I am going about it now. But it gets REALLY cumbersome having to create 4 .php files just to create 1 page.

For exaqmple, if in the traditional way I wanted to create test.html, now I have to create:

/includes/modules/pages/test/header_php.php
/includes/templates/test_template/teamplates/tpl_test_default.php
/includes/extra_datafiles/test.php
/includes/languages/english/test.php

It's a bit like going from NY to LA via Europe & Asia

Oh, and that doesn't count styles sheets, and if the page uses any Javascript.... all this for 1 page...

It does make upkeep on these files a huge, annoying task. Why can't I just create a single html page?

Since I don't NEED ZenCart for the regular old html pages, then why do I have to use it? I need it for the cart, shipping, and payment modules. THATS IT. Why can't I create in the Database the various products & Product ID #s (via zen cart), and then create a plain old HTML form that properly SUBMITS the data (via post) to the shopping cart module?????

It seems rather "Rube Goldberg-ian". It seems like a system of php pages referring to other pages, referring to other pages, referring to others, etc. all to create 1, single page. No wonder so many folks have problems coming to terms with it.

OK, you can do this, but why isn't it simple?

Brain21

25 Sep 2006, 3:42 AM
#10
barco57 avatar

barco57

Totally Zenned

Join Date:
Apr 2006
Location:
West Salem, IL
Posts:
2,846
Plugin Contributions:
0

Re: Newbie needs help simplifying ZenCart - TMI!

:D hmmm with all that I think I'll just stick with adjusting the default to look anyway I want and I'll drag the client along. Seems kinda like stuffing the workings of an old buick into a new porsche just because I like the fact I can work on the buick engine but I like the fancy guages on the dash of the porsche. Thats not to say I won't find it interesting to see how this comes out....

Mike
AEIIA - Zen Cart Certified & PCI Compliant Hosting
The Zen Cart Forum...Better than a monitor covered with post-it notes!

25 Sep 2006, 4:56 AM
#11
Kim avatar

Kim

Obaa-san

Join Date:
Jun 2003
Location:
West Coast, North America
Posts:
26,737
Plugin Contributions:
0

Re: Newbie needs help simplifying ZenCart - TMI!

You can't use plain ol' HTML pages because Zen Cart is dynamic. That means it counts the stock and adjusts it on the fly after things have been added to the cart, it means it knows if you need to add an attribute before you can add to the cart, it means a dozen other little things that make the code SMART. Much of that information exchange is accomplished with the sessions and plain ol'HTML doesn't do sessions. No sessions, no true interaction.

If you just weant add to cart buttons to take an order, there are other programs.

Please do not PM for support issues: a private solution doesn't benefit the community.

Be careful with unsolicited advice via email or PM - Make sure the person you are talking to is a reliable source.

25 Sep 2006, 5:53 AM
#12
brain21 avatar

brain21

New Zenner

Join Date:
Sep 2006
Posts:
42
Plugin Contributions:
0

Re: Newbie needs help simplifying ZenCart - TMI!

Kim:

You can't use plain ol' HTML pages because Zen Cart is dynamic. That means it counts the stock and adjusts it on the fly after things have been added to the cart, it means it knows if you need to add an attribute before you can add to the cart,.

But if I want to use ZenCart (it is, after all, zen CART) for the shopping cart, I already get that. I mean, if I use it for a shopping cart, it still keeps track of the stock. It knows about attributes before I add to the cart not because IT is smart, but because I tell it to. ZenCart doesn't know that a shirt comes in blue or red, until I tell it so. I already stated that I would add the items to the DB vie the zenCart admin interface. That takes care of the attributes. Now all I want to do is submit to the cart itself the item attributes.

It should not be that difficult to pass a simple vlue to the cart via HTML forms, at least in theory. Though ZenCart seems to convolute everything, so who knows.

Maybe there are other programs, but at least for now I am stuck using this.

Here is a simple example of what is frustrating me...

I want to load up a simple index file. Nothing fancy. Lets say something that says

"Welcome to the site, click here to enter"

Now this entails editing in some form (either directly or through the overrides system) index.php

So what do I edit? Well to really understand it, I have to understand how the index.php file works. So what does it do?

index.php LOADS application_top.php, which in turn LOADS configure.core.php, which in turn LOADS class.base.php, and about THREE DOZEN other .php files.

index.php also loads application_top.php in order to load configure.php just to define directories and locations, which seems a bit silly. You have to define to location of the directories, and then to refer to an image or whatever in there later, you have to call the variable set, so what's the point? I can call WS_INCLUDES_IMAGES or I can call /images/

index.php also LOADS application_top.php which in turn LOADS a counter.

Index.php also LOADS header_php.php

And this goes on and on.

All for one page.

Basically its loading up EVERYTHING just in case... and to pass it on to other pages (which are perfectly capable of calling the information as they need it).

This is roughly akin to going out on an August day to the park, and since you didn't check the weather before you left, you brought shorts, tshirt, sandals, socks, sneaker, long sleeve shirt, long pants, a wind breaker, a warmer jacket, a goose down winter jacket, a rain coat, dress shoes, snow boots, rubber galoshes, sunglasses, SPF lotion, an umbrella, a scarf and ear muffs, a baseball hat, a wool cap, gloves, etc.

Or, going to the deli and buying 1 of every meat in order to make a ham sandwich, you know, just in case :-)

Anyway, it's very frustrating and I wish that they would make it easier to use only certain portions of the product overall. It is FAR easier to maintain 1 file per page than SEVERAL per single web page, each page calling yet another.

Brain21

25 Sep 2006, 6:38 AM
#14
barco57 avatar

barco57

Totally Zenned

Join Date:
Apr 2006
Location:
West Salem, IL
Posts:
2,846
Plugin Contributions:
0

Re: Newbie needs help simplifying ZenCart - TMI!

huh, I don't recall having to mess with multiple core code files to change one page....

I have lots of experience with webdesign both professional and personal.

Whats missing is experience with how dynamic / modular web apps are put together. Any of the shopping carts out there that do what you want are going to be put together in pretty much the same way as zen cart. Take a look at any php apps and you will find the same, file after file, calling each other. It look convoluted but it is the way programming modular apps goes. Its easier on the programmers to work on modules that perform certain functions and plug them in. As I was alluding to in my earlier post with the poor analogy, if you want the function of a porsche you need to learn how to drive one. I looked at the page your working on and its nice, nested tables and all, but like the old buick your used to it and it feels comfortable. Time to let go and stop trying to bend the cart to your will. It will be alot less stress to learn how to skin the cart so that it looks the way you want. This forum is full of people who are willing to answer those questions til the cows come home. The route you want to go is most likely to break so much stuff in the cart nobody here will have the time to figure it out for you. ok i've rambled on too much.....

Mike
AEIIA - Zen Cart Certified & PCI Compliant Hosting
The Zen Cart Forum...Better than a monitor covered with post-it notes!

25 Sep 2006, 7:01 AM
#15
barco57 avatar

barco57

Totally Zenned

Join Date:
Apr 2006
Location:
West Salem, IL
Posts:
2,846
Plugin Contributions:
0

Re: Newbie needs help simplifying ZenCart - TMI!

If you want to persist and trudge through this link might give you some help: http://www.htmlgoodies.com/beyond/javascript/article.php/3471331
It is a html cart that uses cookies and javascript to manage product info being passed from page to page. You might be able to pull code out of it to insert into your pages and then the only thing to figure out is how to hand off the info to zen cart when the customer is ready to check out. That would get around the sessions problem as you would only create the session at checkout.....unless the customer decided to go back......and shop some more.....damn customers never follow procedures......I don't know just a thought.

Mike
AEIIA - Zen Cart Certified & PCI Compliant Hosting
The Zen Cart Forum...Better than a monitor covered with post-it notes!

25 Sep 2006, 7:09 AM
#16
brain21 avatar

brain21

New Zenner

Join Date:
Sep 2006
Posts:
42
Plugin Contributions:
0

Re: Newbie needs help simplifying ZenCart - TMI!

You're right, I've never used a cart before. This much is new to me. I have done CGI, mostly in perl, done php, css is nothing new either. But the cart is (new to me). I certainly understand the concept of modularity, but there is a margin of diminishing returns here as well. Like in programming, pointers to pointers are fine, but when you then have so many pointers to pointers that you start following through a maze to fix 1 piece of code, It is no longer efficient.

Maybe it's just my frustration, but when you create a varibale that points to something, and that variable is less efficient than just directly pointing to something, then what's the point? If it is equally useable as compared to whatever it is pointing to, then you have wasted time coding a useless translation (like defining a variable "CDrive" and assigning it a value of "C:" - why referr to CDRive all the time when you can just as easily referr to it as C:?) It's different if the variable is constantly changing, but not always. Soon enough you have pointers pointing everywhere, even if that allows greater functionality in the long run, things get convoluted.

What the software makes creating a simple page an undertaking, it has some problems. After all, a Porsche would be significatly more dificult to drive if the stick shift were in the trunk.

Brain21

25 Sep 2006, 7:13 AM
#17
brain21 avatar

brain21

New Zenner

Join Date:
Sep 2006
Posts:
42
Plugin Contributions:
0

Re: Newbie needs help simplifying ZenCart - TMI!

misty:

http://www.zen-cart.com/forum/showthread.php?t=42105
Thread above discusses easy templates for zencart, may help

I'll lok at this tomorrow, as it is way too late now, but this does look like it could be just what I need (after skimming over it).

Thanks,

Brain21

25 Sep 2006, 7:26 AM
#18
kobra avatar

kobra

Black Belt

Join Date:
Aug 2005
Location:
Arizona
Posts:
31,500
Plugin Contributions:
4

Re: Newbie needs help simplifying ZenCart - TMI!

Another "poor analogy": You are making way too much of this...

Say your html site consists of 100 products, each html file needs to have the header, the left, center, right content described and so forth: 100 times.
Ok a shopper buys product "A", you need a page that indicates this is in his cart, a page that allows checkout with product "A" information so the shopper can see that they are buying the correct item, a page that processes payment, and a sucess page. Now you need these times 100.
OPPS!! the shopper wants item "A" and item "B", now you need these pages created for this combination...and it only gets more complicated from there.

Server side scripting to the rescue:
All this is, under the hood, is an html page that is cut into pieces; header, left, right & center and depending on the specific page, the pieces that are required to display the page with the correct information. All this is dynamically assembled, based upon the combinations the shopper creates.

If you are gonna say that you will use the cart for these pages and you want them to resemble your look & feel, then you have to create the template anyway. So if this is done why attempt to use a static html page as a portal? Just use the cart as it is designed to be used.

As far as linking to Zencart from the html page, you do not need to edit or touch the index.php file. For the main cart page insert something like this into your html page:```

<p>Go to <a href="http://www.your_url.com/shop/">My Store</a></p> ``` and for accessing a product specific page:``` <p>See this <a href="http://www.your_url.com/shop/index.php?main_page=product_info&cPath=33&products_id=47">Products Details</a></p> ``` Where the above url info is what ZenCart will display as the focus in the browser address bar when loaded

But as you seem to think that html would be simpler, by all means forge ahead and do as you will. Not many here will understand much of anything that you are attempting as it will be your design and outside of the normal functions of the cart. And we haven't even touched secure DB access, validation, SSL and many other required things for your shoppers

Zen-Venom Get Bitten

25 Sep 2006, 7:32 AM
#19
barco57 avatar

barco57

Totally Zenned

Join Date:
Apr 2006
Location:
West Salem, IL
Posts:
2,846
Plugin Contributions:
0

Re: Newbie needs help simplifying ZenCart - TMI!

I made another analogy.... I need to stop doing that....I don't get them right anyway.:lol:

Mike
AEIIA - Zen Cart Certified & PCI Compliant Hosting
The Zen Cart Forum...Better than a monitor covered with post-it notes!

25 Sep 2006, 4:20 PM
#20
tshooters avatar

tshooters

Totally Zenned

Join Date:
Dec 2005
Posts:
1,037
Plugin Contributions:
2

Re: Newbie needs help simplifying ZenCart - TMI!

Ahhh, me....reminds me of the time my son (the math wiz) was tutoring
his twin sister (the artsy/musical one) in geometry. She had to know the why of
all those formulas. After much frustration on his part in trying to answer her "Why?" questions, he finally told her to "Just do it!" She doesn't realize it, but she's using
math everyday when she teaches music.

Was that another analogy? :smile: