Homestar Runner Wiki Forum

A companion to the Homestar Runner Wiki
It is currently Sun Nov 21, 2021 8:32 am

All times are UTC




Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 16 posts ] 
Author Message
 Post subject: How the PFARGTL do I do a "flicker"?
PostPosted: Wed May 23, 2007 3:15 am 
Offline
User avatar

Joined: Wed Feb 21, 2007 1:28 am
Posts: 65
Location: Cactus Area
Y'know, a little script that makes the images change everytime you watch the page? how do I do it? :ehsteve:

_________________
Image
Brawl Code: 2406-4842-7494


Top
 Profile  
 
 Post subject:
PostPosted: Wed May 23, 2007 11:46 am 
Offline
User avatar

Joined: Mon May 10, 2004 10:28 pm
Posts: 4675
Uh.

The PTHAFAREGLE threw me off for a few minutes there.

Here:

ed 'lim' smilde wrote:
Here's how I made mine

1. First, you need a place to host it that supports php. If you don't have one, sign up at t35.net; it's free.
2. Next, create a folder named "avatar.png" or something. This is NOT a file, just a folder that happens to look like it's a picture file.
3. Inside that folder, create a file named "index.php". Put the following text source code in that file:
Code:
<?php

   $folder = '.';


    $extList = array();
   $extList['gif'] = 'image/gif';
   $extList['jpg'] = 'image/jpeg';
   $extList['jpeg'] = 'image/jpeg';
   $extList['png'] = 'image/png';
   $extList['PNG'] = 'image/PNG';
   

// You don't need to edit anything after this point.


// --------------------- END CONFIGURATION -----------------------

$img = null;

if (substr($folder,-1) != '/') {
   $folder = $folder.'/';
}

if (isset($_GET['img'])) {
   $imageInfo = pathinfo($_GET['img']);
   if (
       isset( $extList[ strtolower( $imageInfo['extension'] ) ] ) &&
        file_exists( $folder.$imageInfo['basename'] )
    ) {
      $img = $folder.$imageInfo['basename'];
   }
} else {
   $fileList = array();
   $handle = opendir($folder);
   while ( false !== ( $file = readdir($handle) ) ) {
      $file_info = pathinfo($file);
      if (
          isset( $extList[ strtolower( $file_info['extension'] ) ] )
      ) {
         $fileList[] = $file;
      }
   }
   closedir($handle);

   if (count($fileList) > 0) {
      $imageNumber = time() % count($fileList);
      $img = $folder.$fileList[$imageNumber];
   }
}

if ($img!=null) {
   $imageInfo = pathinfo($img);
   $contentType = 'Content-type: '.$extList[ $imageInfo['extension'] ];
   header ($contentType);
   readfile($img);
} else {
   if ( function_exists('imagecreate') ) {
      header ("Content-type: image/png");
      $im = @imagecreate (100, 100)
          or die ("Cannot initialize new GD image stream");
      $background_color = imagecolorallocate ($im, 255, 255, 255);
      $text_color = imagecolorallocate ($im, 0,0,0);
      imagestring ($im, 2, 5, 5,  "IMAGE ERROR", $text_color);
      imagepng ($im);
      imagedestroy($im);
   }
}

?>

If you do this at t35.net, you just hafta open avatar.png directory click "new file", copy in the code, name it "index.php" and save it.
4. In that same folder (avatar.png), put in all the images you want.
5. In profile, set your avatar to http://(yourname).t35.com/avatar.png under "link to off-site image". Yes, avatar.png is a folder but it will read the index.php file and it will randomly select an image from that folder and blah blah blah blah blah it'll work.
6. If you ever want to change the images that get rotated, just change the images in that folder (avatar.png).
If you just can't get it to work, someone can gladly make one for you, but it's always easier to get it yourself so you can modify it later.

_________________
Image
Image


Top
 Profile  
 
 Post subject:
PostPosted: Wed May 23, 2007 5:49 pm 
Offline
User avatar

Joined: Wed Feb 21, 2007 1:28 am
Posts: 65
Location: Cactus Area
thanks! But if I need it for my sig, I change the foldername to [sig[ or whatev? Also, do I change anything from the script? like the
Code:
$extList = array();
   $extList['gif'] = 'image/gif';
   $extList['jpg'] = 'image/jpeg';
   $extList['jpeg'] = 'image/jpeg';
   $extList['png'] = 'image/png';
   $extList['PNG'] = 'image/PNG';

?

EDIT: Check out my sig, IT'S A BROKEN LINK! CRAP...

...this is tougher than I thought

_________________
Image
Brawl Code: 2406-4842-7494


Top
 Profile  
 
 Post subject:
PostPosted: Wed May 23, 2007 8:19 pm 
Offline

Joined: Tue May 08, 2007 12:29 am
Posts: 475
Location: Georgia ­ ­ ­ ­ ­ ­ ­ ­Other: I'm bored.
darkangel wrote:
thanks! But if I need it for my sig, I change the foldername to [sig[ or whatev? Also, do I change anything from the script? like the
Code:
Blah Blah Blah Mumbo Jumbo Yada Yada Sience

?

EDIT: Check out my sig, IT'S A BROKEN LINK! CRAP...

...this is tougher than I thought
How did you get your sig image in the first place?

_________________
eRepublik an awesome once daily online game, kinda like a war simulation.


Top
 Profile  
 
 Post subject:
PostPosted: Wed May 23, 2007 9:01 pm 
Offline
User avatar

Joined: Wed Jan 25, 2006 3:34 am
Posts: 3515
Location: where
Jonathan M wrote:
darkangel wrote:
thanks! But if I need it for my sig, I change the foldername to [sig[ or whatev? Also, do I change anything from the script? like the
Code:
Blah Blah Blah Mumbo Jumbo Yada Yada Sience

?

EDIT: Check out my sig, IT'S A BROKEN LINK! CRAP...

...this is tougher than I thought
How did you get your sig image in the first place?


[img]insert%20url%20here[/img]

_________________
Image


Top
 Profile  
 
 Post subject:
PostPosted: Thu May 24, 2007 2:27 am 
Offline

Joined: Tue May 08, 2007 12:29 am
Posts: 475
Location: Georgia ­ ­ ­ ­ ­ ­ ­ ­Other: I'm bored.
Duecex2 wrote:
Jonathan M wrote:
darkangel wrote:
thanks! But if I need it for my sig, I change the foldername to [sig[ or whatev? Also, do I change anything from the script? like the
Code:
Blah Blah Blah Mumbo Jumbo Yada Yada Sience

?

EDIT: Check out my sig, IT'S A BROKEN LINK! CRAP...

...this is tougher than I thought
How did you get your sig image in the first place?


[img]insert%20url%20here[/img]
OH THX! THAT HEPS ATE LOT!

*sigh*, How did you get the image?

_________________
eRepublik an awesome once daily online game, kinda like a war simulation.


Top
 Profile  
 
 Post subject:
PostPosted: Thu May 24, 2007 2:48 am 
Offline
Pizza Pizza
User avatar

Joined: Tue Jun 22, 2004 4:05 pm
Posts: 10451
Location: probably the penalty box
Jonathan M wrote:
*sigh*, How did you get the image?


You host the image somewhere like imageshack or photobucket.
Go into your profile, and, where it says signature, put this:
[url]image url[/url]

_________________
If you can't fix it with a hammer, you have an electrical problem.


Top
 Profile  
 
 Post subject:
PostPosted: Thu May 24, 2007 2:58 am 
Offline

Joined: Tue May 08, 2007 12:29 am
Posts: 475
Location: Georgia ­ ­ ­ ­ ­ ­ ­ ­Other: I'm bored.
StrongRad wrote:
Jonathan M wrote:
*sigh*, How did you get the image?


You host the image somewhere like imageshack or photobucket.
Go into your profile, and, where it says signature, put this:
[url]image url[/url]
No, How did he get it saying that.

_________________
eRepublik an awesome once daily online game, kinda like a war simulation.


Top
 Profile  
 
 Post subject:
PostPosted: Thu May 24, 2007 3:04 am 
Offline
User avatar

Joined: Thu Nov 02, 2006 5:13 am
Posts: 1755
Location: People's Republic of Socialist Romanistan
StrongRad wrote:
Jonathan M wrote:
*sigh*, How did you get the image?


You host the image somewhere like imageshack or photobucket.
Go into your profile, and, where it says signature, put this:
[url]image url[/url]

OR

Open a image in a new window. Use the http thing at the top it gives you. No account necessary.

EDIT: To Mr. M,

He probably made it using photoshop er' sumptin.

_________________
Image


Top
 Profile  
 
 Post subject:
PostPosted: Thu May 24, 2007 3:10 am 
Offline
User avatar

Joined: Tue Jul 18, 2006 3:06 am
Posts: 2049
Location: Standing on Watterson's front lawn
Did he sell eggs? wrote:
Open a image in a new window. Use the http thing at the top it gives you. No account necessary.

That works most of the time, but it wastes other people's bandwidth and sometimes people will block the image after the server notices it's being used off-site. Best to just host it on your own (free) account on imageshack or photobucket.

_________________
ATTN: LOWER BOARD USERS HAVE MOVED TO ANOTHER FORUM. COME JOIN THE FUN!


Top
 Profile  
 
 Post subject:
PostPosted: Thu May 24, 2007 3:14 am 
Offline

Joined: Tue May 08, 2007 12:29 am
Posts: 475
Location: Georgia ­ ­ ­ ­ ­ ­ ­ ­Other: I'm bored.
X-(





...








HOW DID HE GET THOSE WORDS IN THAT IMAGE?

_________________
eRepublik an awesome once daily online game, kinda like a war simulation.


Top
 Profile  
 
 Post subject:
PostPosted: Thu May 24, 2007 3:16 am 
Offline
User avatar

Joined: Thu Nov 02, 2006 5:13 am
Posts: 1755
Location: People's Republic of Socialist Romanistan
Inverse Tiger wrote:
Did he sell eggs? wrote:
Open a image in a new window. Use the http thing at the top it gives you. No account necessary.

That works most of the time, but it wastes other people's bandwidth and sometimes people will block the image after the server notices it's being used off-site. Best to just host it on your own (free) account on imageshack or photobucket.

Don't kill my glory! NOOOO!

Jonathan M wrote:
X-(





...








HOW DID HE GET THOSE WORDS IN THAT IMAGE?

[s]Spanish Castle[/s] Photoshop Magic.

_________________
Image


Last edited by Did he sell eggs? on Thu May 24, 2007 3:18 am, edited 1 time in total.

Top
 Profile  
 
 Post subject:
PostPosted: Thu May 24, 2007 3:17 am 
Offline
User avatar

Joined: Thu Nov 02, 2006 5:13 am
Posts: 1755
Location: People's Republic of Socialist Romanistan
Woops. Dang. Sorry.

_________________
Image


Top
 Profile  
 
 Post subject:
PostPosted: Fri May 25, 2007 9:50 pm 
Offline

Joined: Tue May 08, 2007 12:29 am
Posts: 475
Location: Georgia ­ ­ ­ ­ ­ ­ ­ ­Other: I'm bored.
Did he sell eggs wrote:
Jonathan M wrote:
X-(





...








HOW DID HE GET THOSE WORDS IN THAT IMAGE?

[s]Spanish Castle[/s] Photoshop witch craft.


Ok thanks

_________________
eRepublik an awesome once daily online game, kinda like a war simulation.


Top
 Profile  
 
 Post subject:
PostPosted: Fri May 25, 2007 9:59 pm 
Offline
User avatar

Joined: Wed Feb 21, 2007 1:28 am
Posts: 65
Location: Cactus Area
Jonathan M wrote:
X-(





...








HOW DID HE GET THOSE WORDS IN THAT IMAGE?


Get both rando.swf and rando.xml and edit the xml file...

_________________
Image
Brawl Code: 2406-4842-7494


Top
 Profile  
 
 Post subject:
PostPosted: Fri May 25, 2007 10:02 pm 
Offline

Joined: Tue May 08, 2007 12:29 am
Posts: 475
Location: Georgia ­ ­ ­ ­ ­ ­ ­ ­Other: I'm bored.
darkangel wrote:
Get both rando.swf and rando.xml and edit the xml file...
Yeah I knew you didn't edit it in photo shop or something :)

_________________
eRepublik an awesome once daily online game, kinda like a war simulation.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 16 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 4 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

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group