Grow your CSS skills. Land your dream job.

Randomly Generated Number/Text

  • # October 23, 2011 at 7:59 am

    I have a dilema! A client wants to be able to give a random code to customers and then provide a download for that code.

    How on earth could I go about doing this?

    Thanks

    Ben Scattergood

    # October 24, 2011 at 12:27 pm

    Hmmm, generating a number is one thing, tying that to a product is a completely different ball game. Have you thought about implementing any third party services? I know there are a few ecommerce solutions that provide software download support.

    # October 24, 2011 at 2:54 pm

    I had but I’d rather keep it to a minimum if possible. Do you know of any that might have this sort of service?

    Thanks for the reply!

    # October 27, 2011 at 6:15 pm

    You could write a randomly generated number to the database when creating the item. My first language to go to with this is PHP and a MYSQL database.

    # October 28, 2011 at 7:46 am

    I’m totally clueless about this stuff, but couldn’t you just encrypt the product SKU (so the random code is always the same length) using umm something like the date as the key… that way it’s a different number each day.

    But like I said, I have no idea how to do it.

    # October 28, 2011 at 11:17 am

    That’s actually a top notch idea! That would work perfectly! Thank you both for the contribution!

    If you’re interested in live gig recordings have a quick look, see if you’re going to any of the gigs that will be covered.
    Mygig

    ALSO, if you have a band, and you want to have your gigs recorded, get in touch on the site. They’ll get back to you!

    Cheers again!

Viewing 6 posts - 1 through 6 (of 6 total)

You must be logged in to reply to this topic.

*May or may not contain any actual "CSS" or "Tricks".