dynamic sig question

Need help installing PHP, configuring a script, or configuring a server? Then come on in and post your questions! We'll try to help the best we can!

Moderator: General Moderators

Post Reply
dustout
Forum Newbie
Posts: 7
Joined: Mon May 28, 2007 10:36 pm

dynamic sig question

Post by dustout »

Code: Select all

http://siggy.draynor.net/goal/strength/99/knife%20man.gif
the areas of the url named goal, strength, 99, and knife%20man can all be altered to output a different image. I am pretty sure that each part of the url is somehow loaded into a variable and used to determine what the image will output. Then it generates an image at the spot where the image was requested.


At the moment i have created some basic dynamic sigs (sample), but i have no idea how to approach the above problem. I would assume it has something to do with altering the .htaccess file, which currently contains the below code. However i am unsure what modifications are needed.

Code: Select all

<FilesMatch "^.*.png">
    SetHandler application/x-httpd-php
</FilesMatch>
User avatar
s.dot
Tranquility In Moderation
Posts: 5001
Joined: Sun Feb 06, 2005 7:18 pm
Location: Indiana

Post by s.dot »

You're right, .htaccess file.

http://siggy.draynor.net/goal/strength/ ... %20man.gif

Code: Select all

RewriteEngine On
RewriteRule ^(.+)/(.+)/([\d]{1,3}/(.+).gif$ page.php?foo=$1&bar=$2&boo=$3&far=$4
I'd write a better regext, but I don't know what values you would be expecting.
dustout
Forum Newbie
Posts: 7
Joined: Mon May 28, 2007 10:36 pm

Post by dustout »

i'm looking at that stuff and i can kinda see what it is saying...definatly not as tidy as i'm used to seeing from php, but definatly understandable.

here is about what i am expecting
1) user requests below url
http://itagger.frih.net/timesig/10/EST/may_20_2007.png

2) then the program cuts apart the url and loads certain parts into variables
$event time = 10
$event timezone = EST
$event date = may_20_2007
with those variables it would calculate the time remaining between the current day/time and the event day/time
User avatar
s.dot
Tranquility In Moderation
Posts: 5001
Joined: Sun Feb 06, 2005 7:18 pm
Location: Indiana

Post by s.dot »

You would be looking at something like this:

http://itagger.frih.net/timesig/10/EST/may_20_2007.png

Code: Select all

RewriteEngine On
RewriteRule ^timesig/([\d]{1,2})/(EST|MST|PST|CST)/(.+).png$ /script.php?event_time=$1&timezone=$2&date=$3
Then, script.php would handle the $_GET variables, and output a dynamic image.
dustout
Forum Newbie
Posts: 7
Joined: Mon May 28, 2007 10:36 pm

Post by dustout »

alright, i'll doodle around with that...thanks for your help scottayy 8)
dustout
Forum Newbie
Posts: 7
Joined: Mon May 28, 2007 10:36 pm

Post by dustout »

it took awile, but i got it to work

http://itagger.frih.net/urledittime/Eve ... 0/2007.png
Image
Post Reply