Forums / Customization from the Admin / Increase length of Product Image URL field?

Increase length of Product Image URL field?

Views: 1,434

Results 1 to 10 of 10
24 Jul 2013, 6:48 PM
#1
knm_computers avatar

knm_computers

New Zenner

Join Date:
Apr 2011
Location:
UK
Posts:
54
Plugin Contributions:
0

Increase length of Product Image URL field?

hi all how can i Increase length of Product Image URL field in Zen Cart ?

i know how to do product name field via phpmyadmin but i can not fine the product image url field so i can add a longer url when importing products

24 Jul 2013, 6:58 PM
#2
drbyte avatar

drbyte

Sensei

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

Re: Increase length of Product Image URL field?

KNM Computers:

so i can add a longer url when importing products
... um ... Zen Cart v1.x.x doesn't use an image URL. It expects image files to be on your server.

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

24 Jul 2013, 9:44 PM
#3
knm_computers avatar

knm_computers

New Zenner

Join Date:
Apr 2011
Location:
UK
Posts:
54
Plugin Contributions:
0

Re: Increase length of Product Image URL field?

DrByte:

... um ... Zen Cart v1.x.x doesn't use an image URL. It expects image files to be on your server.

right so i found the way to make the url address longer but i still cant pick up the image, like you said it expects you to have the image on the server........... but when i get the image url from my site it says this....... 'http://www.knmcomputers.co.uk/images/http://www.suppliers-web-address.co.uk/shop/images/randomimages/laptopscreen4.png

now if i can somehow get (http://www.knmcomputers.co.uk/images/) (this is my site) out the url when it trys looking for the image should it not pick up an image?

25 Jul 2013, 2:46 AM
#4
drbyte avatar

drbyte

Sensei

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

Re: Increase length of Product Image URL field?

How did you get URLs into your products_image field in your database in the first place?

Simply take it out of all of your database records, and then it should work normally again.

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

25 Jul 2013, 6:44 AM
#5
knm_computers avatar

knm_computers

New Zenner

Join Date:
Apr 2011
Location:
UK
Posts:
54
Plugin Contributions:
0

Re: Increase length of Product Image URL field?

hi i imported products via easy populate in the csv file under product image url i put in 'http://www.suppliers-web-address.co.uk/shop/images/randomimages/laptopscreen4.png then imported products,

i want it to read
'http://www.suppliers-web-address.co.uk/shop/images/randomimages/laptopscreen4.png
not
'http://www.knmcomputers.co.uk/images/http://www.suppliers-web-address.co.uk/shop/images/randomimages/laptopscreen4.png

25 Jul 2013, 2:43 PM
#6
drbyte avatar

drbyte

Sensei

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

Re: Increase length of Product Image URL field?

Then change it to be randomimages/laptopscreen4.png instead of your URL

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

25 Jul 2013, 2:50 PM
#7
knm_computers avatar

knm_computers

New Zenner

Join Date:
Apr 2011
Location:
UK
Posts:
54
Plugin Contributions:
0

Re: Increase length of Product Image URL field?

how do i do that? it keeps comming up with 'http://www.knmcomputers.co.uk/images/http://www.suppliers-web-address.co.uk/shop/images/randomimages/laptopscreen4.png

25 Jul 2013, 3:04 PM
#8
drbyte avatar

drbyte

Sensei

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

Re: Increase length of Product Image URL field?

I meant: change the products_image value in your database by removing the URL.
Zen Cart will take the products_image value and append it to '/images/' and use that as the relative URL for your images.

So:
a) products_image value of "randomimages/fred.jpg"
b) upload the physical image file to /yoursite/public_html/images/randomimages/fred.jpg (assuming your ZC is in public_html)
c) then Zen Cart will produce a URL of 'http://your_site.com/images/randomimages/fred.jpg'

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

25 Jul 2013, 3:24 PM
#9
knm_computers avatar

knm_computers

New Zenner

Join Date:
Apr 2011
Location:
UK
Posts:
54
Plugin Contributions:
0

Re: Increase length of Product Image URL field?

DrByte:

I meant: change the products_image value in your database by removing the URL.
Zen Cart will take the products_image value and append it to '/images/' and use that as the relative URL for your images.

So:
a) products_image value of "randomimages/fred.jpg"
b) upload the physical image file to /yoursite/public_html/images/randomimages/fred.jpg (assuming your ZC is in public_html)
c) then Zen Cart will produce a URL of 'http://your_site.com/images/randomimages/fred.jpg'

on so if im importing products via easy populate and use the image url they give me, will i not have to change all the url's to http://your_site.com/images/randomimages/?

as there is over 23 thousand products and was hoping i could point it to a url and load a remote image?

25 Jul 2013, 3:39 PM
#10
drbyte avatar

drbyte

Sensei

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

Re: Increase length of Product Image URL field?

Out-of-the-box Zen Cart doesn't use external product images via some external URL.
If you want to do that, you'll need to change the code or find a plugin that accommodates your desired functionality.

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.