Guest Posted March 11, 2006 Posted March 11, 2006 I am trying to change the image name in the products table "products_image" rather than just the image name I want it to have the full path http://myshop.com/images/stock/2056.jpg I have defined the new image dir in the admin config define('DIR_STOCK_IMAGES', DIR_FS_CATALOG . 'images/stock/'); The above code works to upload the image to the new stock dir And I have played with the following code admin/categories.php if (isset($HTTP_POST_VARS['products_image']) && tep_not_null($HTTP_POST_VARS['products_image']) && ($HTTP_POST_VARS ['products_image'] != 'none')) { $sql_data_array['products_image'] = tep_db_prepare_input($HTTP_POST_VARS['products_image']); But I cannot seem to get the filename to include the full path, sometimes I get it to not place a name at all Any ideas please?
AlanR Posted March 11, 2006 Posted March 11, 2006 See http://www.oscommerce.com/community/contributions,3873 There's a small improvement in the support thread, make sure to check it. When I have more time I'll update the contribution Local: Mac OS X 10.5.8 - Apache 2.2/php 5.3.0/MySQL 5.4.10 • Web Servers: Linux Tools: BBEdit, Coda, Versions (Subversion), Sequel Pro (db management)
Guest Posted March 11, 2006 Posted March 11, 2006 Thanks for that but I am not sure that it is what I need, I actually need the full http path http://myshop.com/images/stock/ put in the image name can this not be done ? I managed to change the upload dir code so that it will upload the file to the new dir I know this will mean changing other code for the display of the item but I need it to link two sites together
TheExterminator Posted March 11, 2006 Posted March 11, 2006 See http://www.oscommerce.com/community/contributions,3873 There's a small improvement in the support thread, make sure to check it. When I have more time I'll update the contribution Thanks Alot AlanR, I Have Look After This Modul About 2 Weeks Now. And I Work To. Your Are The Man There Safe Me Here. Thanks.
Recommended Posts
Archived
This topic is now archived and is closed to further replies.