4images Forum & Community

4images Issues / Ausgaben => Discussion & Troubleshooting => Topic started by: Streetwise on March 24, 2003, 07:42:08 PM

Title: Download URL question
Post by: Streetwise on March 24, 2003, 07:42:08 PM
I am trying to upload a .jpg image and include a link to download the high res .eps version. In the Download URL box, I put the http link to the server it's on:

http://snapserver_1/WWW/Home/html/pages/solid_background/7412.htm

When I try to upload, an error is thrown, and the Download URL area is highlighted in red indicating that there's a problem.

Both 4Images and the Download URL link are on an internal network. I don't see what the problem is.

Any ideas?

Thanks

Dave Anderson
Title: Download URL question
Post by: V@no on March 24, 2003, 07:49:47 PM
that's because 4images compare url with sertain patern, and if doesnt match, then it give u an error.
u can avoid checking it, but replacing
Code: [Select]
 $remote_media_file = format_url(un_htmlspecialchars(trim($HTTP_POST_VARS['remote_media_file'])));
  $remote_thumb_file = format_url(un_htmlspecialchars(trim($HTTP_POST_VARS['remote_thumb_file'])));

in member.php
with
Code: [Select]
 $remote_media_file = un_htmlspecialchars(trim($HTTP_POST_VARS['remote_media_file']));
  $remote_thumb_file = un_htmlspecialchars(trim($HTTP_POST_VARS['remote_thumb_file']));
Title: Download URL question
Post by: Streetwise on March 24, 2003, 08:08:31 PM
Sorry. I just tried what you said, and it still throws an error with the Download URL highlighed in red... I've tried uploading both as Admin, and as a registered user with admin privledges. It still doesn't like that URL. What else can I try?

Thanks

Dave
Title: Re: Download URL question
Post by: Chris on March 24, 2003, 09:14:10 PM
Quote from: Streetwise
http://snapserver_1/WWW/Home/html/pages/solid_background/7412.htm

What is the web site root directory?  You can check your web server documentation of determine the value of $_SERVER['DOCUMENT_ROOT'] or $DOCUMENT_ROOT PHP variables.

Judging by the look of your URL, I doubt it's valid.  It seems to me that a more likely URL would look like one of these:

http://snapserver_1/solid_background/7412.htm
http://snapserver_1/pages/solid_background/7412.htm
http://snapserver_1/html/pages/solid_background/7412.htm

What is the URL of your 4images installation?
Title: Re: Download URL question
Post by: Streetwise on March 24, 2003, 09:32:15 PM
Quote from: Chris

What is the web site root directory?  You can check your web server documentation of determine the value of $_SERVER['DOCUMENT_ROOT'] or $DOCUMENT_ROOT PHP variables.


Actually, the index.html file resides just inside http://snapserver_1. Therefore, the link is valid as I can navigate to the file with my web brower and the network URL I described. (In other words, I can paste the URL into by browser and hit that page/image).

Quote from: Chris

What is the URL of your 4images installation?


It is on another box separate from the snapserver_1 box (but on the same network). It is "D:\WWW\imageshare\imagevault\index.php"

Hope this helps narrow it down!

Thanks Chris!

Dave
Title: Download URL question
Post by: V@no on March 24, 2003, 10:28:14 PM
ah, ok. let's try this then:
again in member.php find:
Code: [Select]
 if ((empty($HTTP_POST_FILES['media_file']['tmp_name']) || $HTTP_POST_FILES['media_file']['tmp_name'] == "none") && ($remote_media_file == "" || !check_remote_media($remote_media_file))) {
replace with:
Code: [Select]
 if ((empty($HTTP_POST_FILES['media_file']['tmp_name']) || $HTTP_POST_FILES['media_file']['tmp_name'] == "none") && ($remote_media_file == "")) {
Title: Download URL question
Post by: Streetwise on March 25, 2003, 01:31:17 PM
Hmmm.

I've tried making *both* changes that were suggested to the member.php file with no luck, and I've gone back to the original member.php file and made only the most recent change that you suggested. Still No Dice. Does it make a difference that my login status is an Admin?

Here's my most recent string that you suggested:
 
 if ((empty($HTTP_POST_FILES['media_file']['tmp_name']) || $HTTP_POST_FILES['media_file']['tmp_name'] == "none") && ($remote_media_file == "")) {

Still when I include the path to the server in the Download URL, that section comes back in red signifying a problem with the path (just to clarify).

The path to an actual image that I want to download the link to:
http://snapserver_1/RESOURCES/Image%20Library/HighRes_CMYK/Units/A/AV3111.eps

I decided to try to debug by uploading the eps image to a server on the WWW. When I do that and put the path to the image in the Download URL, it then seems to work fine.

<edited>
The conclusion is that the Download URL section needs to have the presence of both "www" and ".com" in the section in order for it to work.<edited>

Any more ideas?

Thanks for your help!

Dave Anderson