Simple PHP problem

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Tipsy
    Confirmed User
    • Jul 2001
    • 6989

    #1

    Simple PHP problem

    I've been hunting around on google with no luck (everyone seems to want to do something more complicated)...


    All I want to do is call a PHP page using img src to pass it some data. That means it will need to return a small 1x1 gif to stop a broken image showing. How do I return a 1x1 gif to the img src call with PHP?
    Ignorance is never bliss.
  • rowan
    Too lazy to set a custom title
    • Mar 2002
    • 17393

    #2
    header("Content-type: image/gif");
    readfile("/path/to/1x1.gif");

    Comment

    • I Am The Walrus
      Confirmed User
      • Aug 2003
      • 1000

      #3
      format c
      <a href="http://www.hahahahahahahaha.com">Pimp Dog Makes Me Horny ;)</a>

      Comment

      • Tipsy
        Confirmed User
        • Jul 2001
        • 6989

        #4
        Originally posted by rowan
        header("Content-type: image/gif");
        readfile("/path/to/1x1.gif");
        Thanks - I'll give that a bash
        Ignorance is never bliss.

        Comment

        • I Am The Walrus
          Confirmed User
          • Aug 2003
          • 1000

          #5
          Originally posted by Tipsy


          Thanks - I'll give that a bash
          I think my solution will work MUCH better though
          <a href="http://www.hahahahahahahaha.com">Pimp Dog Makes Me Horny ;)</a>

          Comment

          • SMG
            Confirmed User
            • Aug 2003
            • 1798

            #6
            Originally posted by I Am The Walrus
            format c
            hmmm ... considering most services are linux, I think rm -rf ~/ is way more effective
            TGP Webmasters: sign up for the top 100 tgp list!
            Submit galleries
            If you add me to icq (title) make sure to mention GFY or I'll think you're a bot and deny you.

            Comment

            Working...