Zen Cart Logo
Forums / Setting Up Categories, Products, Attributes / add new field to products_table

add new field to products_table

Locked

Views: 3,238

Results 1 to 15 of 15
This thread is locked. New replies are disabled.
28 Aug 2006, 6:24 PM
#1
webhie avatar

webhie

New Zenner

Join Date:
Jun 2006
Posts:
14
Plugin Contributions:
0

add new field to products_table

I want to add new fields to products_table.

this includes adding new column in admin page

and where should i add the insert query

1 Sep 2006, 4:46 PM
#2
notrub225 avatar

notrub225

New Zenner

Join Date:
Aug 2006
Location:
Chicago
Posts:
24
Plugin Contributions:
0

Re: add new field to products_table

that question has a really long answer.

1 Sep 2006, 5:51 PM
#3
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: add new field to products_table

The easiest way to figure out where you have to make a change is to pick a field similar to what you are trying to add ...

Say you wanted something like products_model

You would then do a search in the Tools ... Developer's Tool Kit ... and in the bottom input box type:
products_model

Pick Catalog/Admin from the dropdown and click search ...

Now this will include more places than you may need, but it will show you all files that use this field name ...

NOTE: a field like products_model may later be referred to as model or $model or $products_model etc.

It really depends on what all you are trying to do and where you need to display/add/edit this field ...

2 Sep 2006, 11:52 AM
#4
webhie avatar

webhie

New Zenner

Join Date:
Jun 2006
Posts:
14
Plugin Contributions:
0

Re: add new field to products_table

Ajeh:

The easiest way to figure out where you have to make a change is to pick a field similar to what you are trying to add ...

Say you wanted something like products_model

You would then do a search in the Tools ... Developer's Tool Kit ... and in the bottom input box type:
products_model

Pick Catalog/Admin from the dropdown and click search ...

Now this will include more places than you may need, but it will show you all files that use this field name ...

NOTE: a field like products_model may later be referred to as model or $model or $products_model etc.

It really depends on what all you are trying to do and where you need to display/add/edit this field ...

Thank you Ajeh,notrub,

I would like to add an extra image for my products, I identified where the form has image input and replicated changed its name at all pages as image2 and included an extra field to database.

If i select the directory to store the extra image.it goes to the database but the filename is not transferred to the database nor the file gets uploaded..

Can you help

2 Sep 2006, 1:42 PM
#5
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: add new field to products_table

Zen Cart already has built in unlimited additional images ...

Do a search on:

calico cat
images/medium
additional images

You should find a 10001 threads on how to utilize them ... :smile:

4 Sep 2006, 2:51 PM
#6
webhie avatar

webhie

New Zenner

Join Date:
Jun 2006
Posts:
14
Plugin Contributions:
0

Re: add new field to products_table

Hi linda,

Can we do that from zen admin without going for ftp,

4 Sep 2006, 2:53 PM
#7
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: add new field to products_table

Medium, Large and Additional Images are added via FTP ...

4 Sep 2006, 3:12 PM
#8
webhie avatar

webhie

New Zenner

Join Date:
Jun 2006
Posts:
14
Plugin Contributions:
0

Re: add new field to products_table

Can pl you tell me which area of code responsible for first image upload and entry indirectory

4 Sep 2006, 3:47 PM
#9
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: add new field to products_table

That is more or less a combination of the /admin/modules files ...

4 Sep 2006, 3:58 PM
#10
webhie avatar

webhie

New Zenner

Join Date:
Jun 2006
Posts:
14
Plugin Contributions:
0

Re: add new field to products_table

Thank u linda,

I found that collect_info is responsible for outer form which i changed and i need to know what should be changed to upload the image name to database and where it should be modified for an upload

4 Sep 2006, 4:08 PM
#11
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: add new field to products_table

You have several peices ...

collect_info.php
new_product_preview.php
preview_info.php
update_product.php

Then be sure that you keep in mind the Product Types ...

5 Sep 2006, 1:23 PM
#12
webhie avatar

webhie

New Zenner

Join Date:
Jun 2006
Posts:
14
Plugin Contributions:
0

Re: add new field to products_table

Thank you linda,

I altered those contents but still its not taking the name of the file into the database i dunno why can you help
5 Sep 2006, 1:25 PM
#13
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: add new field to products_table

What exactly are you trying to do here?

5 Sep 2006, 1:25 PM
#14
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: add new field to products_table

You could try using the Image Handler contribution which expands image support and allows you greater control over images directly from the admin area, without using FTP.
You can control small/medium/large for main and additional images.

5 Sep 2006, 1:29 PM
#15
webhie avatar

webhie

New Zenner

Join Date:
Jun 2006
Posts:
14
Plugin Contributions:
0

Re: add new field to products_table

I would like to add a different image that should show up only on the popup, So i like to add extra image while uploading product details and want that image to show when popup comes