Forum Moderators: phranque
the URL currently looks like:
www.example.com/downoald.php?url=https://bucket.s3.amazonaws.com/folder/file.jpg
we would like to rewrite the above to:
www.example.com/download/file.jpg
www.example.com/download/file.jpg
OR
www.example.com/download/another-file.jpg
Could anyone offer some clarifications over the last few posts?
Thank you again
OR
www.example.com/downoald.php?url=https://bucket.s3.amazonaws.com/another-folder/another-file.jpg
and I would like people to see:
www.example.com/download/file.jpg
OR
www.example.com/download/another-file.jpg
(based on the requested file)
The long version is where the content really lives. The short version is what you want people to see and use.
Or is it the other way around?
In your example, is the "file" element the part of the filename name that changes? If you're rewriting, there has to be something for the rewrite to get hold of so it knows where to look. Otherwise you're in php-script territory.
But if there is no way to get the folder then we would surely need to display a URL of this kind:
www.example.com/download/folder/file.jpg
OR
www.example.com/download/another-folder/another-file.jpg