Confirmation

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Shelly

    #1

    Confirmation

    Can someone point me to some existing code that has the user click on a
    link in an email that brings him to a page that presents some
    letters/numbers for him to type in in order to validate an account?

    BTW, what purpose do those letters serve?

    Shelly

  • Michael

    #2
    Re: Confirmation

    Answer to what the letters do: It is to stop bots, spam bots, macros,
    anything automated really from making account to spam or whatever.

    I doubt there is an existing script as it is only useful if you are
    validating something and most code uses a different sytle of system for
    certain things. But use php GD and i would probably md5 the value and
    put it in a $_GET value.

    Comment

    • Shelly

      #3
      Re: Confirmation

      Good thought about the bots. Thanks.

      As for the rest, what do you mean by GD?

      I suppose it would go something like this:

      Send an email to them bringing them to the validation page.

      Put in a random sequence of letters and numbers.

      When they type it, compare the two.

      Why do I need to md5 it and where would it go?

      Shelly

      Comment

      • john.d.mann@gmail.com

        #4
        Re: Confirmation

        The reason for using those letters for confirmation is so that only a
        human can submit the form. If you use plain text, an automated program
        could read the string and input it on its own. So, to avoid this, you
        turn the randomized string of letters/numbers into an image using GD
        (with GD, you can overlay text into an image. You create an image on
        the fly to your desired dimensions and load that image on the screen.
        You need to keep a copy of the string you used to create the image for
        comparison. You can either keep it in a database, or in a $_GET value,
        which is where the MD5 comes in - to help encrypt it. I'd suggest the
        database route, personally, but that involves a more in-depth program,
        so be up for it if you do that (tie it together with the session id for
        example). When the user types in the random string form the image,
        then compare it to the stored value (from database or your $_GET value).

        Comment

        • john.d.mann@gmail.com

          #5
          Re: Confirmation

          You would use the function

          imagettftext()

          to get your text onto the image, as an example. You can find the
          details on how to use it (syntax, examples) by going to the PHP manual:



          Comment

          • john.d.mann@gmail.com

            #6
            Re: Confirmation

            Ah, I always wondered what "captcha" was - now I know, even though I
            always did - I just never knew what it was called.

            Comment

            • Iván Sánchez Ortega

              #7
              Re: Confirmation

              -----BEGIN PGP SIGNED MESSAGE-----
              Hash: SHA1

              Shelly wrote:
              [color=blue]
              > Good thought about the bots. Thanks.[/color]

              Have a look at http://www.captcha.net/ , they got a lot of resources about
              CAPTCHAs, how's ans why's.
              [color=blue]
              > As for the rest, what do you mean by GD?[/color]

              GD stands for the Boutelle's Graphical Library. The library used by PHP in
              its image manipulation functions. http://php.net/image

              - --
              - ----------------------------------
              Iván Sánchez Ortega -i-punto-sanchez--arroba-mirame-punto-net

              El hombre nunca es demasiado viejo para aprender.

              -----BEGIN PGP SIGNATURE-----
              Version: GnuPG v1.4.2 (GNU/Linux)

              iD8DBQFDsHGP3jc Q2mg3Pc8RAngYAJ wICA1eM+cIo/RsoAE3W6BbiVg9N wCcCl8g
              pkSgRRk7kckbAFn ++mLg19E=
              =8bQo
              -----END PGP SIGNATURE-----

              Comment

              Working...