Point a URL that loads an image to an html page?

  • Matthew
  • Proficient
  • Proficient
  • User avatar
  • Joined: Jul 07, 2005
  • Posts: 266
  • Loc: Canada
  • Status: Offline

Post May 29th, 2009, 6:46 am

I have an image that was hotlinked like crazy:
http://xona.com/postattachments/avast_b ... lexa_2.png

Right now it loads a 404 page (as I pulled the image), but how can I make http://xona.com/postattachments/avast_b ... lexa_2.png load something else, as I know tons of hits are coming to it?

I could do this with .htaccess I believe. Is that the only way?
Matthew Doucette, Xona Games
Award winning indie game studio.
  • Anonymous
  • Bot
  • No Avatar
  • Joined: 25 Feb 2008
  • Posts: ?
  • Loc: Ozzuland
  • Status: Online

Post May 29th, 2009, 6:46 am

  • UPSGuy
  • Lurker ಠ_ಠ
  • Web Master
  • User avatar
  • Joined: Jul 25, 2005
  • Posts: 2735
  • Loc: Nashville, TN
  • Status: Offline

Post May 29th, 2009, 7:40 am

Looks like there may be a few ways to achieve what you're wanting, dependent on your setup. Apache appears to have some rule functionality. You could also try it out via script, or you could go with htaccess, as you mentioned. If you have a preference, maybe we can help you chase down the best-case solution.

This approach seemed particularly interesting to me.
I'd love to change the world, but they won't give me the source code.
  • Bogey
  • Bogey
  • Genius
  • User avatar
  • Joined: Jul 14, 2005
  • Posts: 8211
  • Loc: USA
  • Status: Offline

Post May 29th, 2009, 9:59 pm

That approach was interesting... I think I may do that ...
"Bring forth therefore fruits meet for repentance:" Matthew 3:8

Post Information

  • Total Posts in this topic: 3 posts
  • Users browsing this forum: No registered users and 75 guests
  • You cannot post new topics in this forum
  • You cannot reply to topics in this forum
  • You cannot edit your posts in this forum
  • You cannot delete your posts in this forum
  • You cannot post attachments in this forum
 
 

© 2011 Unmelted, LLC. Ozzu® is a registered trademark of Unmelted, LLC.