EQ2Interface

EQ2Interface (https://www.eq2interface.com/forums/index.php)
-   Chit-Chat (https://www.eq2interface.com/forums/forumdisplay.php?f=2)
-   -   Cool dynamic sig (my own) (https://www.eq2interface.com/forums/showthread.php?t=1116)

Drumstix42 01-22-2005 12:44 AM

Cool dynamic sig (my own)
 
Check this out :D



I got my php signature code from the eq2 forums and molded it how I liked, slapped in a background image, and woot. My site picture links to my site, and my eq2 picture links to my alts. Whatta think?

Quib 01-22-2005 12:47 AM

Well isn't that snazzy...

Count me as jealous.

Quib

Drumstix42 01-22-2005 12:48 AM

The text is all white (for some reason it's not cooperating with me), but it's acctually making it transparent, so to see it better, switch to the light style on the forums

insomniac 01-22-2005 04:39 AM

i want one!
If i remember correctly that site wasnt english.. so .. linky?
oh and i suck at php so some instuctions would be nice

it looks like dos...

tonyis3l33t 01-22-2005 10:04 AM

wow thats great, now teach us how ya did it heheh
________
AngyStrip4U cam

Drumstix42 01-22-2005 02:32 PM

Quote:

Originally Posted by insomniac
i want one!
If i remember correctly that site wasnt english.. so .. linky?
oh and i suck at php so some instuctions would be nice

it looks like dos...


Pffft, I didn't use a site generator, lol. Only used the code to pull the data from the site, the rest is my doing. :)

If you wanted instructions, you would have to have a host that has PHP and GD support. Unless you got me to host it for you.... hehe.

Basically the code pulls the data and assigns them to different data variables...

$traits_a[x] where x is a number
$guild_a[x]
...and...
$attr_a[x]

Then I just used what PHP knowledge I had of creating dynamic images, placed it where I wanted and voila.

I asked, and attempting to pull data from the Achievements page, I could care less about showing my attributes, but I decided to fill some space ;)

All I have to do is open the file, and change the playerId to change what shows up, but what is on there right now is my main, and click the pic links to my alts page. So all is well.

Drumstix42 01-22-2005 05:03 PM

Updated. I figured out how to get the data from the achievements page too. Woot woot. :cool:

*edit* Oh yeah, it didn't like my BG picture before I think cause it had layers, so I'll stick with simple bg, and replace logo with text.

Itanius 01-22-2005 10:57 PM

Would you mind posting a sample of your php code for that? Puhhleassse? :D

Drumstix42 01-23-2005 12:38 AM

*edit edited and edited once again*

Akku-CS 01-23-2005 03:58 AM

Uhmm, how to tell my server to read the .gif as .php ?
Cant figure it out with try and error.

Drumstix42 01-23-2005 04:24 AM

it works as a php file, just can't use it as a sig on all forums (ones that don't allow PHP extensions)

tonyis3l33t 01-23-2005 05:13 AM

Awesome! This should be in the signature setup page:)
________
Live Sex Webshows

ger 01-23-2005 09:01 AM

Quote:

Originally Posted by tonyis3l33t
since this is about eq2players...:)
anyone know how to get my stats to show up? everything shows "Update" on it:(

Give SOE more money on a monthly basis. Seriously though, if you opted not to subscribe to the extended EQ2Players services, no cool stats for j00.

Itanius 01-23-2005 10:39 AM

Thanks, Drumstix! :)

Quote:

Originally Posted by Drumstix42
I have to change it to .gif, and tell my server to read the file as PHP so I can use it as a sig in all forums.

How do you tell the server to read a .gif as a .php?

Humudce 01-23-2005 12:12 PM

Actually what is happening is the PhP file on his server is dynamically creating the image file everytime it is called upon. What you see when you look at his posts are images created dynamically when you open his message in your browser. It is not really reading the Gif file as PhP but the PHP file is creating the gif file that is displayed.

Itanius 01-23-2005 02:05 PM

I call on my version of the php file and nothing is happening... Yes, I have php support. (www.galdor.net)

Drumstix42 01-23-2005 02:37 PM

Quote:

Originally Posted by Humudce
Actually what is happening is the PhP file on his server is dynamically creating the image file everytime it is called upon. What you see when you look at his posts are images created dynamically when you open his message in your browser. It is not really reading the Gif file as PhP but the PHP file is creating the gif file that is displayed.

No. You can do that, but I'm using a background image. The text is created by PHP

If you right click my sig you will notice it's a GIF file. How would PHP create the GIF if I'm not calling upon any PHP file? ;)

It's doing what I said.

Itanius 01-23-2005 04:11 PM

Oh well. :(

Good work nonetheless, Drum.

Humudce 01-23-2005 04:38 PM

Quote:

Originally Posted by Drumstix42
No. You can do that, but I'm using a background image. The text is created by PHP

If you right click my sig you will notice it's a GIF file. How would PHP create the GIF if I'm not calling upon any PHP file? ;)

It's doing what I said.

You use a gif file background on your site, and have the PHP code place your info ontop of the Gif fiie, creating a new file on the users browser, No? Because when I try and save your signature it appears as only a gif file with all of the information that your PhP code added to the gif file.

Ok I see what you are saying on my signature which is generated in a similar way, it appears as
Code:

http://eq2.onlinewelten.com/siggenv2/signature.php?Id=2484

instead of eq2sig.gif.

Humudce 01-23-2005 04:44 PM

Quote:

Originally Posted by Itanius
I call on my version of the php file and nothing is happening... Yes, I have php support. (www.galdor.net)

Check to see if your host has GD support, it is an addon to PhP and it's an Image Library. That is probably why you can not get it to work.

Drumstix42 01-23-2005 05:05 PM

Quote:

Originally Posted by Humudce
You use a gif file background on your site, and have the PHP code place your info ontop of the Gif fiie, creating a new file on the users browser, No? Because when I try and save your signature it appears as only a gif file with all of the information that your PhP code added to the gif file.

Ok I see what you are saying on my signature which is generated in a similar way, it appears as
Code:

http://eq2.onlinewelten.com/siggenv2/signature.php?Id=2484
instead of eq2sig.gif.

Yep, now you got it :D

Itanius 01-23-2005 07:11 PM

Quote:

Originally Posted by Humudce
Check to see if your host has GD support, it is an addon to PhP and it's an Image Library. That is probably why you can not get it to work.

That's probably what it is. Thanks for the heads up!

Nightlord 01-23-2005 09:51 PM

I have absolutely no idea how to make this work.
Can someone break down how to do it?

Drumstix42 01-24-2005 03:34 PM

The way I do it you'll need these requirements:

- bg image
- host with PHP
- GD library installed with PHP (not all hosts have it

So if you don't have those, you won't be able to do it, at least this way. I'd rather not go through the process of doing it all. I tend to think it something precious, because I was able to get it to work on my own, and would rather leave it at being something of my own. Not something everyone else has :)

Drumstix42 01-25-2005 10:48 PM

Whoops I had $magic and $melee backwards where they were defined ;)

All better :rolleyes:

taco-man 01-25-2005 11:03 PM

Quote:

Originally Posted by Drumstix42
This is the exactly code, but the file is in .php extension

I have to change it to .gif, and tell my server to read the file as PHP so I can use it as a sig in all forums.

http://www.advancedmod.com/sigs/eq2sig.zip

*edit* inside the file, one of the top lines is where the characterId is, which you must set, everything else is on your own, make your own BG image, I just ask.... don't be unoriginal and use the exacty same code and layout I do, lol.

can someone email me the code from that link, the mirror appears to be down right now for some reason. my email is [email protected]

Drumstix42 01-26-2005 04:31 PM

Yeah, I took it down the other day.

Findarato 01-26-2005 07:26 PM

Lol yours is lame, mine is dynamic

check it out

http://eq2.noodle-bowl.com/sig/?smal...playerid=*your player id*

Nightlord 01-27-2005 02:58 AM

Bah. I still don't get how to overlay it over a background image and use it as a sig.
Also, it's pointing to a PHP page on your website... but there's no way to check the code/source. Anyone care to share?

Findarato 01-27-2005 04:51 AM

lol

sharing isnt caring :)

but which part you looking for?

Code:

  require("eq2player.php");
 
  if(isset($_GET[jpg]))
          header("Content-type: image/jpeg");
  else
          header("Content-type: image/png");
  //$diff=time();
 
  if(isset($_GET[small]))
  {
          if(!isset($_GET[x]) && !isset($_GET[y]))
          {
                  $x=500;
                  $y=35;
          }
  }
  //Get's the Months left!
  $months = ($usedtime - ($usedtime % 2592000)) / 2592000;
  $usedtime = $usedtime - ($months * 2592000);
 
  $days = ($usedtime - ($usedtime % 86400)) / 86400;
  $usedtime = $usedtime - ($days * 86400);
  // Get's the hours left!
  $hours = ($usedtime - ($usedtime % 3600)) / 3600;
  $usedtime = $usedtime - ($hours * 3600);
  // Get's the minutes left!
  $minutes = ($usedtime - ($usedtime % 60)) / 60;
  $usedtime = $usedtime - ($minutes * 60);
  // Get's the seconds left!
  $seconds = ($usedtime - ($usedtime % 1)) / 1;

Code:

 
                          if(isset($_GET[h]))
                          $three.="Heat:".$data['Heat Resist']." ";                       
 
                          if(isset($_GET[p]))
                                $three.="Poison:".$data['Poison Resist']." ";
 
                          if(isset($_GET[d]))
                                $three.="Disease:".$data['Disease Resist']." ";
                                 
                          if(isset($_GET[m]))
                                $three.="Divine:".$data['Divine Resist']." ";
 
                          if(isset($_GET[me]))
                          $three.="Mental:".$data['Mental Resist']." ";                                         
 
         
 /////////////////////////////Display//////////////////////////////////////                         
                          imagestring($im, 2, 0, 0,$one, $text_color);
                          imagestring($im, 2, 0, 10,$two, $text_color);
                          imagestring($im, 2, 0, 20,$three, $text_color);
  }
  if(isset($_GET[jpg]))
          imagejpeg($im);
  else
          imagepng($im);
 
  imagedestroy($im);
  ?>

Thats just the display code. not the parse code. That stuff you cant have ^_^

Nightlord 01-27-2005 05:10 AM

Gotcha, nevermind. I'm just coding-illiterate and this is apparently some kind of deep secret. Forget I asked.

Findarato 01-27-2005 11:05 AM

the site parse is what I dont give out, cus its a sweet, and under 1 second to parse 50 of them. Some how its crazy fast.

Drumstix42 01-27-2005 12:50 PM

Sharing isn't caring? That doesn't help anyone at all. Lol.

Also, if you were talking to me, mine is Dynamic.

Lastly, I can care less what just about anyone thinks, I'm sharing the code a few select people, but I'd rather not have everyone running around with the same signature...The code is on the eq2players site anyone... all the code, the parse code. Mine is only different because I change it to how I wanted it, and added extras.

Also, anyone that does have what I posted or gave to you...

make the last part of the defines look like this:

Code:

$Kills=$achievements_a[24];
$Deaths=$achievements_a[29];
$KPD=$achievements_a[36];
$Quests=$achievements_a[41];
$Magic=$achievements_a[53];
$Melee=$achievements_a[60];
$Recipes=$achievements_a[74];

if ($Deaths == 0)
{
$LastKilledBy='n/a';
$LastKilledDate='n/a';
$Zone='n/a';
}
else
{
$LastKilledBy=$traits_a[36]." ".$traits_a[37]." ".$traits_a[38];
$LastKilledDate=$traits_a[30]." ".$traits_a[31]." ".$traits_a[32];
$Zone=$traits_a[40]." ".$traits_a[41]." ".$traits_a[42];
}

(just make sure the if check is under where $Deaths is defined)

The reason for this is because when parsing the page, if there is nothing there for what killed, where, and when, it skips it, messing up the defines. I changed my sig to my newest char which currently has no deaths.

taco-man 01-27-2005 06:05 PM

hey drumsitx, Thankyou for sending me the code. Since you were nice enough to share that with me, i can share something with you that you will probably find usefull for the script :D
Currently the Guild and Server names are limited to being only 1 word long :( so what i did was fix that, i did it perhaps not the best way, but it works, :D all my php coding that i learned is self taught so please forgive me if there is a better way to do this; at least it works.

To have an unlimited number of words for guild and server name just above this line:
Code:

// start creating image
insert:
Code:

$Guild=Stats( $pplayer, "<td width=\"50%\"><span class=\"field_name_small\">Guild</span></td>"
                                        ,"</a></td>", TRUE);
$Guild=(strip_tags($Guild));
$Guild = ereg_replace("[ \t\r\n]+", " ", $Guild);
$Server=Stats( $pplayer, "<td><span class=\"field_name_small\">Server</span></td>"
                                        ,"</a></td>", TRUE);
$Server=(strip_tags($Server));
$Server = ereg_replace("[ \t\r\n]+", " ", $Server);

it should work, it works for me anyway at least. Thanks again and i hope this is helpfull(it should be since your guild is named Rise of the Phoenix) ;)

Humudce 01-27-2005 07:33 PM

The sig generator I am currently using is available at the English Version of this German site.

http://eq2.onlinewelten.com/siggenv2/en/

This page is in English....

Drumstix42 01-27-2005 09:07 PM

Quote:

Originally Posted by taco-man
hey drumsitx, Thankyou for sending me the code. Since you were nice enough to share that with me, i can share something with you that you will probably find usefull for the script :D
Currently the Guild and Server names are limited to being only 1 word long :( so what i did was fix that, i did it perhaps not the best way, but it works, :D all my php coding that i learned is self taught so please forgive me if there is a better way to do this; at least it works.

To have an unlimited number of words for guild and server name just above this line:
Code:

// start creating image
insert:
Code:

$Guild=Stats( $pplayer, "<td width=\"50%\"><span class=\"field_name_small\">Guild</span></td>"
                                        ,"</a></td>", TRUE);
$Guild=(strip_tags($Guild));
$Guild = ereg_replace("[ \t\r\n]+", " ", $Guild);
$Server=Stats( $pplayer, "<td><span class=\"field_name_small\">Server</span></td>"
                                        ,"</a></td>", TRUE);
$Server=(strip_tags($Server));
$Server = ereg_replace("[ \t\r\n]+", " ", $Server);

it should work, it works for me anyway at least. Thanks again and i hope this is helpfull(it should be since your guild is named Rise of the Phoenix) ;)


Yes yes, I hadn't gotten into my old EQ1 guild in EQ2 yet until today I know I would have to fix it. If I find a better way I will share. I also have to work with a few other parts and I'll make sure to post here as I figure it all out :)

taco-man 01-27-2005 09:10 PM

its as fixed as i will ever need it because im a cheap bastard and didnt want to pay the extra money :eek: for eq showing my stats, so all the stuff that i can see is set up perfectly now.

Drumstix42 01-27-2005 09:16 PM

*edit* random mubling, I get what taco-man said now, you cannot access achievements if you don't pay the extra 99cents for it :)

taco-man 01-28-2005 11:22 AM

what i meant is there is that extra upgrade you pay EQ2 like a dollar a month for to have ALL your stats show up on that stats page on eq2players like resists and kills, ect. and i am too cheap to pay it...

Drumstix42 01-28-2005 11:45 AM

Yeah, another was getting an error and found out that is why, because didn't have the extra stuff either.

Anyhow... I've just about gotten it all fixed up for my siggie. Probably would have to fix it for a 2 word class name, but then I'd probably have to respace that line because it wouldn't fit :p

I'm satisfied for now.


All times are GMT -5. The time now is 04:52 PM.

vBulletin® - Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
© MMOUI