I am using the following code in my functions.php to update the upload path of images submitted via my form:
/* This function needs the correct form id and server path */
add_filter("gform_upload_path_1", "change_upload_path");
function change_upload_path($path_info){
$path_info["path"] = "/mnt/stor1-wc2-dfw1/467468/658308/www.mydomain.com/web/content/wp-content/gallery/photos-page/";
$path_info["url"] = "http://www.mydomain.com/wp-content/gallery/photos-page/";
return $path_info;
}
This is working perfectly. The problem I am having is when I am viewing any of the entry details
(admin.php?page=gf_entries&view=entry&id=1&lid=49&paged=1)
The link for the uploaded image is incorrect. When I click on the image title which is supposed to link to the uploaded image it links to http://www.mydomain.com/image.jpg
I need the link to be http://www.mydomain.com/wp-content/gallery/photos-page/image.jpg
Does this make sense? I've tried browsing the entry_detail.php file to find the correct href to update but can't seem to locate it. Can anyone advise me on how to accomplish this?