Professional Web Applications Themes

[PHP] Very interesting..... - PHP Development

[snip] I tried your code on this machine and I got this... 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0..... [/snip] What is your numeric precesion set to in the php.ini?...

  1. #1

    Default RE: [PHP] Very interesting.....

    [snip]
    I tried your code on this machine and I got this...

    0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.....
    [/snip]

    What is your numeric precesion set to in the php.ini?
    Jay Blanchard Guest

  2. #2

    Default RE: [PHP] Very interesting.....

    [snip]
    There isn't one in php.ini. Could this be the problem?
    [/snip]

    Look for these lines in your php.ini

    ; The number of significant digits displayed in floating point numbers.
    precision = 14

    What is precision equal to?
    Jay Blanchard Guest

  3. #3

    Default Re: [PHP] Very interesting.....

    There isn't one in php.ini. Could this be the problem?

    "Jay Blanchard" <jay.blanchardniicommunications.com> wrote in message
    news:C8F323573C030A448F3E5A2B6FE2070B01AFA7AAneme sis...
    [snip]
    I tried your code on this machine and I got this...

    0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.....
    [/snip]

    What is your numeric precesion set to in the php.ini?
    Scott Fletcher Guest

  4. #4

    Default Re: [PHP] Very interesting.....

    Will do that once I get a newer PHP version. No time for it right now. :-)

    The workaround to rand() I did was to use it twice and add up the result.
    For ex.

    --snip--
    $randomNumberLeft = rand(0,99999);
    $randomNumberRight = rand(0,99999);
    $randomNumber = $randomNumberLeft.$randomNumberRight;

    echo $randomNumber.
    --snip--

    "Jay Blanchard" <jay.blanchardniicommunications.com> wrote in message
    news:C8F323573C030A448F3E5A2B6FE2070B02A1D3nemesi s...
    [snip]
    It is not there, so I added it and restarted Apache. Still got the same
    result.

    How is PHP is built into Apache was done by downloading the tar.gz file
    from
    php.net and compile it. Then compile Apache, had it take in PHP. So,
    when
    it was done, there is never a php.ini there. So, I create one and add
    some
    of hte coding into php.ini file. This is for the Unix machine. The
    only
    scripting I have in php.ini so far is ...
    [/snip]

    You should have 2 or 3 php.ini files....usually

    php.ini-dist
    php.ini-optimized
    php.ini-recommended

    (from the command line 'locate php.ini')

    You pick the one that you want to use and copy it into /etc/apache while
    renaming it php.ini. My current php.ini file is comprised of 775 lines
    of information and directives. As I understand it the .ini is not
    required, and probaly is not affecting the rand on your machine.
    Scott Fletcher Guest

Similar Threads

  1. Interesting Issue
    By eonyron webforumsuser@macromedia.com in forum Macromedia Flash Actionscript
    Replies: 1
    Last Post: February 6th, 03:03 PM
  2. Very interesting.....
    By Scott Fletcher in forum PHP Development
    Replies: 0
    Last Post: September 5th, 06:21 PM
  3. interesting or just plain cr#p
    By wayne in forum Photography
    Replies: 0
    Last Post: July 18th, 12:37 AM
  4. interesting
    By Ursula Baranowski in forum Photography
    Replies: 0
    Last Post: July 10th, 05:57 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139