barkster Posted January 21, 2008 Share Posted January 21, 2008 I'm have an uploader program in java that I use to upload some images and it is encoding the names but I cannot view them on the site. For instance the file is on the server as hallcorner01%5b1%5d.jpg but cannot browse to it, says not found but copied from my ftp server hallcorner01%5b1%5d.jpg is there. Why isn't apache seeing this? Link to comment https://forums.phpfreaks.com/topic/87107-images-with-special-characters-not-showing/ Share on other sites More sharing options...
effigy Posted January 21, 2008 Share Posted January 21, 2008 The % is used for escape sequences in URLs. You'll see your file if you replace each "%" with "%25" in the address bar. Also, see urlencode. Link to comment https://forums.phpfreaks.com/topic/87107-images-with-special-characters-not-showing/#findComment-445530 Share on other sites More sharing options...
barkster Posted January 21, 2008 Author Share Posted January 21, 2008 But what I'm saying is the filename is hallcorner01%5b1%5d.jpg on the server, not hallcorner01[1].jpg Link to comment https://forums.phpfreaks.com/topic/87107-images-with-special-characters-not-showing/#findComment-445585 Share on other sites More sharing options...
effigy Posted January 21, 2008 Share Posted January 21, 2008 So you don't want Java to encode the names? I don't know what the entire process is, or what's expected of it. Link to comment https://forums.phpfreaks.com/topic/87107-images-with-special-characters-not-showing/#findComment-445586 Share on other sites More sharing options...
barkster Posted January 21, 2008 Author Share Posted January 21, 2008 I do need to fix that but what I did for now was just urldecode the name in my upload script. I guess I see what is happening the browser is expecting the [1] and the filename is encoded so it can't see it. I wasn't thinking about encoding at first cause the two names matched but the browser was decoding expecting the [1]. Thanks Link to comment https://forums.phpfreaks.com/topic/87107-images-with-special-characters-not-showing/#findComment-445595 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.