Page 1 of 1
'Enable Image Lookup' Code
Posted: Wed Jul 01, 2009 7:45 pm
by draneb
Hello...
Is there anyway we can edit the code so that the Enable Image Lookup feature will look for the product image in
the /Assets/ProductImages folder as well as any sub categories that are under the ProductImages folder?
If that is not possible perhaps something generic like
/Assets/ProductImages/1
/Assets/ProductImages/2
etc...
This way we could keep the ProductImages folder from growing too large and becoming unresponsive in the Admin, which mine has just done
Thank you,
Draneb
Re: 'Enable Image Lookup' Code
Posted: Thu Jul 02, 2009 8:08 am
by mazhar
Edit Catalog/OrphanedItems.aspx.cs file and try to update
Code: Select all
string[] directories = System.IO.Directory.GetDirectories(imagesFolderPath);
with
Code: Select all
string[] directories = System.IO.Directory.GetDirectories(imagesFolderPath, string.Empty, System.IO.SearchOption.AllDirectories);
Re: 'Enable Image Lookup' Code
Posted: Thu Jul 02, 2009 8:33 am
by draneb
Hi Mazhar,
Unfortunately that didn't work
If you have any other ideas I am more than happy to give them a try.
Getting it to look in all sub directories under Assets/ProductImages would be so great.
Thank you.
Re: 'Enable Image Lookup' Code
Posted: Thu Jul 02, 2009 8:50 am
by mazhar
Just looked at the code in details and it seems to me that its been already coded in way to take care of this case. Did you checked by creating some folder ProductImages and then by putting some snaps into that folder.
Re: 'Enable Image Lookup' Code
Posted: Thu Jul 02, 2009 9:17 am
by draneb
Hi,
Yes, I created a folder under ProductImages called gc
and then I have about 20 product images in that folder - thumbnails and regular size - to test
but nothing is showing up on the site and when going into the admin the image path is blank
but if I move the images to /ProductImages they show up.
It seems like they would have coded it to look into sub folders because at a minimum 2 images per product (thumbnail and regular size) the directory can grow quickly if you have a lot of products. I have about 1,200.
Thank you for your help.
Re: 'Enable Image Lookup' Code
Posted: Thu Jul 02, 2009 9:32 am
by mazhar
Re: 'Enable Image Lookup' Code
Posted: Wed Feb 15, 2012 1:56 pm
by triplw
I'm having trouble with images in a subdirectory not showing up. Has this bug been fixed?