|
|
|||||||
| About Us | Register | FAQ | Members List | Calendar | Mark Forums Read |
![]() |
|
|
LinkBack | Thread Tools | Display Modes |
|
|
#1 (permalink) |
|
Administrator
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Join Date: Dec 2001
Location: Montreal, Canada
Posts: 7,129
|
PHP script in image discussion
OK well i remember seeing Kane IIRC trying to do this once for a random avatar script that works with vBulletin (they dont allow php as avatars..)
Well this just got my attention. Most of you have probably seen this image many times ![]() it runs a PHP script in the picture. Maybe it could be a way to have a random image script in the picture. I dont know if your following me here... Aniway i made this thread so ideas can be givin on how this could be done (if it can be done) since the author of that image wont reveal his code (of course :P). so if anyone has an idea then please share with others. im probably not the only one who is interested in this
|
|
|
|
|
#2 (permalink) |
|
Ramsus K
![]() ![]() ![]() Join Date: Mar 2003
Location: Oklahoma
Posts: 461
|
Re: PHP script in image discussion
Here's how: They use some of the information you send in your HTTP Get request header when your browser requests the image from their server (which is really a program that is set up to be executed when "http://www.danasoft.com/vipersig.jpg" is requested). It then generates a JPEG image, sends an HTTP header in reply saying they're sending Content-Type image/jpeg and sends over the generated JPEG image.
I don't have any HTTP references on hand, and I don't do any real server-side development regularly, so I can't post any code examples. EDIT: Maybe I'll write something a bit later, eh? |
|
|
|
|
#3 (permalink) |
|
Ramsus K
![]() ![]() ![]() Join Date: Mar 2003
Location: Oklahoma
Posts: 461
|
Create a simple PHP script that gets the HTTP header information from the proper environment variables like this one: http://ramsus.guiltyparties.com/image.php.txt
It could also make use of other information obtainable not just through CGI environment variables provided by the server, but also by piping the output of a program. Create an image like this one: http://ramsus.guiltyparties.com/test.png Then add a .htaccess file to a subdirectory with the contents: Action image/png /image.php I added mine to http://ramsus.guiltyparties.com/image/ so now any request to a .png file from that location will return the output of http://ramsus.guiltyparties.com/image.php (keep in mind that even if there is a .png file already there, it will still return the output of image.php instead, which is why I put it into a subdirectory). See here: http://ramsus.guiltyparties.com/image/whatever.png |
|
|
|
|
#4 (permalink) |
|
Registered User
![]() ![]() ![]() ![]() ![]() Join Date: Sep 2002
Location: St Andrews, Scotland
Posts: 1,575
|
Re: PHP script in image discussion
It is impossible to make a random avatar on emuforums since it makes it's own local copy of your avatar.
__________________
OS: Arch Linux w/ Kernel 2.6.23.8 + GNOME 2.20.1 - CPU: Intel Pentium M 1.5GHz - Memory: 1280MB DDR PC2700 - Browser: Mozilla Firefox 2.0.0.10 |
|
|
|
|
#5 (permalink) | |
|
Administrator
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Join Date: Dec 2001
Location: Montreal, Canada
Posts: 7,129
|
Re: Re: PHP script in image discussion
Quote:
oh and RamsusX. thx for all that info ill look more into it since im no hardcore php coder :P but its eems wuite simple how you explain it thx
|
|
|
|
|
|
#6 (permalink) |
|
Emulation64's Animal >:D
![]() ![]() ![]() ![]() ![]() Join Date: Apr 2001
Location: United States
Posts: 1,215
|
Re: PHP script in image discussion
yeah vB makes a local copy of the avatars when offlinked so .. it won't work. I have a script that works great and could be used with the .jpg or .gif extension rather then .php .. which helps get around some restriction some boards have for dynamic signatures. It does work on the avatar as well, but only forums that do not mirror a copy localy.
__________________
![]() ![]() ![]() ![]() Emulation64.com | EFx2Blogs Forums | EFx2Blogs - Sign Up For Your Own Free EFx2Blog Today! |
|
|
|
|
#7 (permalink) | |
|
Administrator
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Join Date: Dec 2001
Location: Montreal, Canada
Posts: 7,129
|
Re: Re: PHP script in image discussion
Quote:
|
|
|
|
|
|
#8 (permalink) |
|
Emulation64's Animal >:D
![]() ![]() ![]() ![]() ![]() Join Date: Apr 2001
Location: United States
Posts: 1,215
|
Re: PHP script in image discussion
no clue, I could look on EmuTalk.net .. I am an admin there so I could check to see if an option exists.
__________________
![]() ![]() ![]() ![]() Emulation64.com | EFx2Blogs Forums | EFx2Blogs - Sign Up For Your Own Free EFx2Blog Today! |
|
|
|
|
#9 (permalink) | |
|
Administrator
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Join Date: Dec 2001
Location: Montreal, Canada
Posts: 7,129
|
Re: Re: PHP script in image discussion
Quote:
|
|
|
|
|
|
#10 (permalink) | |
|
Ramsus K
![]() ![]() ![]() Join Date: Mar 2003
Location: Oklahoma
Posts: 461
|
Re: Re: Re: PHP script in image discussion
Quote:
|
|
|
|
|
|
#12 (permalink) | |
|
Ramsus K
![]() ![]() ![]() Join Date: Mar 2003
Location: Oklahoma
Posts: 461
|
Re: Re: PHP script in image discussion
Quote:
The server with the Message Board doesn't even touch the image unless it's stored locally on the server. It simply sends HTML with an IMG tag with the URL to the image. Your browser is what downloads the image. The image data is never touched by the server with the message board. |
|
|
|
|
|
#13 (permalink) | |
|
Administrator
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Join Date: Dec 2001
Location: Montreal, Canada
Posts: 7,129
|
Re: Re: Re: PHP script in image discussion
Quote:
|
|
|
|
|
|
#14 (permalink) |
|
Administrator
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Join Date: Apr 2001
Location: Germany
Posts: 2,026
|
Re: PHP script in image discussion
Well, let's jump straight into this thread
The way vBulletin caches stuff *is* for security reasons ... this isn't directly related to the PHP code being any dangerous (which it isn't, as it gets executed on another server) but the possibility to get the session ID of an user through this. However it needs to be added, that vB3 has a pretty complex but good way to work around this - however, as it's still in beta testing stages, this is de-activated for now. Look forward to host dynamic signatures @ NGEmu starting with vB3 RC1.
__________________
![]() Specs: AMD Athlon 64 4000+ • 2048 MB PC400 RAM • Nvidia GeForce 7600 GT PCI-E • WinXP Pro |
|
|
|
|
#16 (permalink) |
|
Registered User
![]() ![]() ![]() ![]() ![]() Join Date: Sep 2002
Location: St Andrews, Scotland
Posts: 1,575
|
Re: PHP script in image discussion
Let me just elaborate on what Bobbi has said. If users disable the use of cookies then vBulletin stores the user id in the URL. So a script could analise the HTTP_REFERER and then learn your session ID.
__________________
OS: Arch Linux w/ Kernel 2.6.23.8 + GNOME 2.20.1 - CPU: Intel Pentium M 1.5GHz - Memory: 1280MB DDR PC2700 - Browser: Mozilla Firefox 2.0.0.10 |
|
|
|
|
#17 (permalink) |
|
Registered User
Join Date: Oct 2004
Location: uk
Posts: 1
|
hey ive got a script its working but not exactly as danasoft
i just wana know wot script rasmusx used to do it. here is my working one if anyone want to know how i did please post or else i wouldn't be asked to. change the x's in http://icefuzion.com/mm/xxxx.jpg into what ever you want. here is an example.
|
|
|
|
|
#18 (permalink) |
|
A1C
![]() ![]() Join Date: Jan 2004
Location: California
Posts: 230
|
Don't bring up dead threads, especially with off-topic posts.
Also, I just went and wrote my own PHP script, but that post is a few years old so it isn't around anymore. It takes only a few minutes to write one and photoshop some images. |
|
|
![]() |
| Thread Tools | |
| Display Modes | |
|
|