View Full Version : PHP problem
Lex
March 21st, 2003, 14:54
Like you know my avatar can change hairecuts by refreshing :P but i found it somewhere on the internet and i want to put it on my own webspace so i'm sure i won't lose it if the site goes down, i downloaded all the pictures :) and wrote a simple php script, it works if i follow the link (http://lexavatar.clawz.com/random_pic.php?avatar.gif) but if i change it to my avatar it shows me a red cross :( .
Can anybody help me?
The original link is http://www.ookonline.com/images/random/ook....php?avatar.gif (http://www.ookonline.com/images/random/ook.php?avatar.gif)
Here is my code:
<?php
$dir_path = "http://lexavatar.clawz.com";
$file_path = "/avatars/";
$ext = ".gif";
$rand = rand(1,64);
print "<img src=".$dir_path.$file_path.$prefix.$rand.$ext .">";
?>
Here is the link to my webspace : http://lexavatar.clawz.com
Slougi
March 21st, 2003, 14:56
That does not work on vbulletin, since it fetches and saves the avatar locally, always :(
Lex
March 21st, 2003, 15:00
Originally posted by Slougi
That does not work on vbulletin, since it fetches and saves the avatar locally, always :(
:cry: :cry: :cry: :cry: :cry:
Lex
March 21st, 2003, 15:53
I am using my old avatar again ;( :D
The Khan Artist
March 28th, 2003, 21:01
To do that, you would have to have your script actually return the file, intead of an img tag. It's quite possible, but I've never personally done it. Basically, you want to spit out some headers (that's the hard part - finding all the necessary headers to print), then then open the file and output it.
Slougi
March 28th, 2003, 21:52
Originally posted by The Khan Artist
To do that, you would have to have your script actually return the file, intead of an img tag. It's quite possible, but I've never personally done it. Basically, you want to spit out some headers (that's the hard part - finding all the necessary headers to print), then then open the file and output it.
No that won't work. As I said before, avatars are always stored locally, and because of that are static.
The Khan Artist
March 29th, 2003, 06:29
Originally posted by Slougi
No that won't work. As I said before, avatars are always stored locally, and because of that are static.
Oh, yeah. Sorry, I totally forgot that part. :P
Anyways, it would still be great for a sig.
Lex
March 29th, 2003, 13:49
Originally posted by The Khan Artist
Oh, yeah. Sorry, I totally forgot that part. :P
Anyways, it would still be great for a sig.
it worked with the one on ookonline.com, on the temp. emutalk ;)but i want it on my own host
:happy: can somebody help me anyway (to use it on other sites)
Doomulation
March 29th, 2003, 20:56
:w00t:
There's lots of sites out there that has free shoting! One example is angelcities.com.
Lex
March 29th, 2003, 21:41
Originally posted by Doomulation
:w00t:
There's lots of sites out there that has free shoting! One example is angelcities.com.
i didn't ask for a host:doh:
Doomulation
March 29th, 2003, 22:35
Doh!
My mistake! :doh:
Slougi
March 30th, 2003, 00:32
What was that about reading posts...?
Lex
March 30th, 2003, 15:46
Originally posted by The Khan Artist
Anyways, it would still be great for a sig.
:shifty: :w00t: Good idea!!!
Lex
March 30th, 2003, 15:49
Originally posted by The Khan Artist
To do that, you would have to have your script actually return the file, intead of an img tag. It's quite possible, but I've never personally done it. Basically, you want to spit out some headers (that's the hard part - finding all the necessary headers to print), then then open the file and output it.
how do i do that?
Doomulation
March 30th, 2003, 19:48
Originally posted by Slougi
What was that about reading posts...?
but i want it on my own host
:happy: can somebody help me anyway (to use it on other sites)
Seemed like he needed a host for it, that you could help to find one or something :doh:
Lex
March 31st, 2003, 14:24
Originally posted by Doomulation
Seemed like he needed a host for it, that you could help to find one or something :doh:
If you read my first post you can see i already have one :doh: , i need help woth the php script in the first post :)
Doomulation
April 1st, 2003, 13:51
Of course, of course, but it *DID* sound like it :(
Anyway, no matter. What is done is done.
Powered by vBulletin® Version 4.1.11 Copyright © 2012 vBulletin Solutions, Inc. All rights reserved.