dneibert
Newbie
Offline
Posts: 17
Thank You
-Given: 2
-Receive: 0
|
 |
« on: January 08, 2011, 06:42:31 PM » |
|
Hi, I have tried to get the answer to this in the forums but no one seems to know the answer. I need the following done: For my gallery, I need 3 files for each image: 1) A thumbnaildone. 2) A jpeg previewdone. 3) And then for the download, I want it to link to a larger file. But right now I have to manually go in type in the URL for the download file for every image. I would like it to populate that area automatically when I import images. Please tell me how much it will cost for this modification. Thanks! 
|
|
|
|
|
|
Logged
|
|
|
|
V@no
If you don't tell me what to do, I won't tell you where you should go :)
Administrator
4images Guru
   
Offline
Posts: 17849
Thank You
-Given: 47
-Receive: 498
mmm PHP...
|
 |
« Reply #1 on: January 08, 2011, 07:36:32 PM » |
|
in admin/images.php find: 1
| show_input_row($lang['field_download_url'].$lang['download_url_desc'], "image_download_url", $image_row['image_download_url'], $textinput_size); |
Insert above: 1 2 3 4
| if (empty($image_row['image_download_url']) && !is_remote($image_row['image_media_file']))
{
$image_row['image_download_url'] = "/home/danane5/public_html/stock/data/".$image_row['cat_id']."/".$image_row['image_media_file'];
} |
|
|
|
|
|
« Last Edit: January 11, 2011, 12:38:51 AM by V@no »
|
Logged
|
|
|
|
dneibert
Newbie
Offline
Posts: 17
Thank You
-Given: 2
-Receive: 0
|
 |
« Reply #2 on: January 10, 2011, 07:24:10 AM » |
|
Thank you very much for the help. But it is not working for me. I don't know if this matters, but I manually upload my images via FTP. Thumbnails to thumbnail folder, preview to media folder, and then the larger image to the 1200 folder. Then I used the check new images function. But it is not working. Any thoughts?
|
|
|
|
|
|
Logged
|
|
|
|
V@no
If you don't tell me what to do, I won't tell you where you should go :)
Administrator
4images Guru
   
Offline
Posts: 17849
Thank You
-Given: 47
-Receive: 498
mmm PHP...
|
 |
« Reply #3 on: January 10, 2011, 09:08:30 AM » |
|
"not working" doesn't help..more details needed
|
|
|
|
|
|
Logged
|
|
|
|
dneibert
Newbie
Offline
Posts: 17
Thank You
-Given: 2
-Receive: 0
|
 |
« Reply #4 on: January 10, 2011, 03:02:22 PM » |
|
Sorry! I have inserted the code as you noted. Then I uploaded my three files to their respective locations. Then I used check new images to import them to the gallery. But only the thumbnail and preview pictures are importing. The download link still just downloads the preview image and not my large image. When I go to edit the image to check to see if it inserted the download link, it has not. Any thoughts?
|
|
|
|
|
|
Logged
|
|
|
|
V@no
If you don't tell me what to do, I won't tell you where you should go :)
Administrator
4images Guru
   
Offline
Posts: 17849
Thank You
-Given: 47
-Receive: 498
mmm PHP...
|
 |
« Reply #5 on: January 11, 2011, 12:39:51 AM » |
|
Ops, my bad, that new code meant to be added above, not below (I've updated my post). Also, it only works when you edit an image.
|
|
|
|
|
|
Logged
|
|
|
|
dneibert
Newbie
Offline
Posts: 17
Thank You
-Given: 2
-Receive: 0
|
 |
« Reply #6 on: January 11, 2011, 01:20:12 AM » |
|
Is there any way to make it do what I need to do? I will have a project coming up where I will be adding hundreds of images a day. I don't want to have to edit each image in order to make the link for the bigger download. Any suggestions?
|
|
|
|
|
|
Logged
|
|
|
|
V@no
If you don't tell me what to do, I won't tell you where you should go :)
Administrator
4images Guru
   
Offline
Posts: 17849
Thank You
-Given: 47
-Receive: 498
mmm PHP...
|
 |
« Reply #7 on: January 11, 2011, 03:15:03 AM » |
|
Try this. In admin/checkimages.php find: 1
| $sql = "INSERT INTO ".IMAGES_TABLE." |
Insert above: 1 2 3 4
| if (empty($image_download_url) && !is_remote($image_media_file)) {
$image_download_url = addslashes("/home/danane5/public_html/stock/data/".$cat_id."/".$image_media_file); }
|
|
|
|
|
|
|
Logged
|
|
|
|
dneibert
Newbie
Offline
Posts: 17
Thank You
-Given: 2
-Receive: 0
|
 |
« Reply #8 on: January 11, 2011, 07:21:47 AM » |
|
Thank you so much! It works great!
|
|
|
|
|
|
Logged
|
|
|
|
|