+ Reply to Thread
Page 2 of 3 FirstFirst 123 LastLast
Results 11 to 20 of 25

Thread: Dynamic images with PHP

  1. #11
    marshian's Avatar
    marshian is offline x10 Elder marshian is an unknown quantity at this point
    Join Date
    Jan 2008
    Location
    Belgium
    Posts
    526

    Re: Dynamic images with PHP

    Quote Originally Posted by hamsn View Post
    good tutorial
    and also the location tracker
    its also good if you post the ip tracker code too
    in tutorials
    anyways the main programming tutorial was excellent!
    The LocationScript-thing is actually just a joke ;-)
    Real programmers don't document their code - if it was hard to write, it should be hard to understand.

  2. #12
    LHVWB's Avatar
    LHVWB is offline Lord Of The Keys LHVWB is an unknown quantity at this point
    Join Date
    Jan 2008
    Location
    Australia
    Posts
    1,308

    Re: Dynamic images with PHP

    You could use a script similar to the one in the link below to actually have the image track the viewers country, you could even put a little flag in there as well. ;)

    http://www.dynamicdrive.com/forums/s...7&postcount=18
    Last edited by LHVWB; 05-28-2008 at 01:06 AM.

  3. #13
    marshian's Avatar
    marshian is offline x10 Elder marshian is an unknown quantity at this point
    Join Date
    Jan 2008
    Location
    Belgium
    Posts
    526

    Re: Dynamic images with PHP

    Quote Originally Posted by verbsite View Post
    You could use a script similar to the one in the link below to actually have the image track the viewers country, you could even put a little flag in there as well. ;)

    http://www.dynamicdrive.com/forums/s...7&postcount=18
    It's a nice idea, but NOT THAT SCRIPT plox :o
    It uses a 'small' list...
    http://www.ci-pro.com/misc/phptest/loc/ip.csv
    That thing is around 6 meg! It stores a huge list of ip's and their countries...
    Maybe if I find something less... huge...
    Edit:
    I'm going to change something about my image code, this is an example of what the tutorial outputs:
    Last edited by marshian; 05-28-2008 at 11:39 AM. Reason: Automerged Doublepost
    Real programmers don't document their code - if it was hard to write, it should be hard to understand.

  4. #14
    scorch94 is offline x10 Sophmore scorch94 is an unknown quantity at this point
    Join Date
    Sep 2007
    Posts
    228

    Re: Dynamic images with PHP

    Hmmm... looks like you've edited your font
    Is it that hard to do? :s

    I'm good with PHP, but I've never actually worked with images in PHP. So this one came up like a really good image introduction and made me start learning it

  5. #15
    marshian's Avatar
    marshian is offline x10 Elder marshian is an unknown quantity at this point
    Join Date
    Jan 2008
    Location
    Belgium
    Posts
    526

    Re: Dynamic images with PHP

    It's not hard at all, I've got the file "data-latin.ttf" in the same directory, so I can use this command:
    PHP Code:
    imagettftext($image100168270"data-latin.ttf"$text[0]); 
    which does almost the same as imagestring(), but it uses a truetype font instead of the normal one.
    Real programmers don't document their code - if it was hard to write, it should be hard to understand.

  6. #16
    mattura's Avatar
    mattura is offline x10 Elder mattura is an unknown quantity at this point
    Join Date
    Oct 2007
    Posts
    563

    Re: Dynamic images with PHP

    If it didn't work for you - try the following as a last line (make sure you send the header first though):
    PHP Code:
    return imagepng($image); 
    Last edited by mattura; 05-28-2008 at 06:49 PM.
    ----
    Life is a game. The conception is terrible but the graphics are amazing!
    matt.elementfx.com

  7. #17
    marshian's Avatar
    marshian is offline x10 Elder marshian is an unknown quantity at this point
    Join Date
    Jan 2008
    Location
    Belgium
    Posts
    526

    Re: Dynamic images with PHP

    Quote Originally Posted by mattura View Post
    If it didn't work for you - try the following as a last line (make sure you send the header first though):
    PHP Code:
    return imagepng($image); 
    OMG I can't beleive i'm that stupid! o_O
    I forgot that part! =.=
    IT HAS TO BE
    PHP Code:
    return imagepng($image); 
    instead of
    PHP Code:
    return $image
    Edit: I can't change the contents of the first post any more, but it has to be that!
    Last edited by marshian; 05-29-2008 at 12:03 PM.
    Real programmers don't document their code - if it was hard to write, it should be hard to understand.

  8. #18
    bigjoe4 is offline x10 Elder bigjoe4 is an unknown quantity at this point
    Join Date
    Jan 2008
    Posts
    907

    Re: Dynamic images with PHP

    Is it possible to use this kind of script to add a copyright notice which automatically updates the year in the footer image of my site? http://www.circuitz4u.com/
    Last edited by bigjoe4; 05-29-2008 at 01:34 PM.
    Please visit my site: Circuit designer

  9. #19
    marshian's Avatar
    marshian is offline x10 Elder marshian is an unknown quantity at this point
    Join Date
    Jan 2008
    Location
    Belgium
    Posts
    526

    Re: Dynamic images with PHP

    Quote Originally Posted by bigjoe4 View Post
    Is it possible to use this kind of script to add a copyright notice which automatically updates the year in the footer image of my site? http://www.circuitz4u.com/
    Of course it's possible to use the php image capabilities to edit that image for you, but I'ld recommend using an external font to do it, instead of imagestring(), as it wouldn't look too professional.
    If you need help, you know where to find me =p
    Real programmers don't document their code - if it was hard to write, it should be hard to understand.

  10. #20
    bigjoe4 is offline x10 Elder bigjoe4 is an unknown quantity at this point
    Join Date
    Jan 2008
    Posts
    907

    Re: Dynamic images with PHP

    You can pursuade a mod to edit the contents of the first post
    Please visit my site: Circuit designer

+ Reply to Thread
Page 2 of 3 FirstFirst 123 LastLast

Similar Threads

  1. SUHOSIN - Use of eval is forbidden
    By MaestroFX1 in forum Free Hosting
    Replies: 19
    Last Post: 03-07-2008, 03:42 AM
  2. Important PHP Information
    By Bryon in forum News and Announcements
    Replies: 0
    Last Post: 11-21-2007, 03:08 PM
  3. Images in PHP Coding?
    By TheJeffsta in forum Scripts & 3rd Party Apps
    Replies: 4
    Last Post: 05-19-2006, 08:09 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
x10hosting free hosting for the masses
dedicated servers