patrmich Posted August 28, 2012 Share Posted August 28, 2012 Hi, I use Prestashop 1.4.7.0. By default Prestashop rewrites the image urls by inserting the product title tag content in the image url. So, when a product has several images, the same product title tag content is inserted in the various urls images. Example : - the product title tag is "mobile-phone" - let us presume that the product has 3 images (and that the product id is 10) The urls of the 3 images will be for instance : http://mydomain.com/...obile-phone.jpg http://mydomain.com/...obile-phone.jpg http://mydomain.com/...obile-phone.jpg I a looking for a way to alter the re-writing rules (in the htaccess file) in order to do the following : - keeping the inserting of the product title in the product default image - and in other images, inserting the content of the image title alt tag (instead of the content of the product title tag) So, to follow the above example, I would like to get the here after images urls : http://mydomain.com/...obile-phone.jpg http://mydomain.com/...phone-green.jpg http://mydomain.com/...ne-keyboard.jpg where mobile-phone-green was the image title tag of the second product image and where mobile-phone-keyboard was the image title tag of the third product image I thank you in advance for any help in this matter. Patrick Link to comment Share on other sites More sharing options...
Bazze Posted August 28, 2012 Share Posted August 28, 2012 (edited) Hi, I use Prestashop 1.4.7.0. By default Prestashop rewrites the image urls by inserting the product title tag content in the image url. So, when a product has several images, the same product title tag content is inserted in the various urls images. Example : - the product title tag is "mobile-phone" - let us presume that the product has 3 images (and that the product id is 10) The urls of the 3 images will be for instance : http://mydomain.com/...obile-phone.jpg http://mydomain.com/...obile-phone.jpg http://mydomain.com/...obile-phone.jpg I a looking for a way to alter the re-writing rules (in the htaccess file) in order to do the following : - keeping the inserting of the product title in the product default image - and in other images, inserting the content of the image title alt tag (instead of the content of the product title tag) So, to follow the above example, I would like to get the here after images urls : http://mydomain.com/...obile-phone.jpg http://mydomain.com/...phone-green.jpg http://mydomain.com/...ne-keyboard.jpg where mobile-phone-green was the image title tag of the second product image and where mobile-phone-keyboard was the image title tag of the third product image I thank you in advance for any help in this matter. Patrick Well, a place to start looking in would be the _regenerateNewImages() function in admin/tabs/AdminImages.php. Edited August 28, 2012 by Bazze (see edit history) Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now