1. This website uses cookies. By continuing to use this website you are giving consent to cookies being used.
    For information on cookies and how you can disable them visit our Cookie Usage page.
    Dismiss Notice

PHP PHP Random

Discussion in 'Web Development' started by vareside, Feb 8, 2009.

  1. vareside

    vareside New Member

    Hi folks,

    I need help. I need a script that displays pre-defined HTML codes in a random order. Could someone help me by creating such a small script for me?
  2. vareside

    vareside New Member

    no Need

    I created one myself. Here we go:
    $text_1 "some text";
    $text_2 "some text2";
    $text_3 "some text3";
    $text_4 "some text4";

    $total_texts rand(1,4);
    See example at WISE QUOTE on http://vareside.com/
  3. candycrate

    candycrate New Member

    // Random HTML codes

    // Generate a seed for REAL random numbers

    // Pick a random code
    echo $Random_Values[mt_rand(0,(count($Random_Values)-1))];