Code

rrd_flush.c: Provide a more useful error message.
[rrdtool-all.git] / contrib / php4 / examples / rrd_update.php
1 <?
3  ## the following line is only needed if built as a self-contained
4  ## extension.  If you build the rrdtool module as an embedded
5  ## extension, the rrd_* functions will always be available, so you
6  ## do not need the dl() call.
7  dl("rrdtool.so");
9  ##
10  ## demonstration of the rrd_update() command
11  ##
13   $ret = rrd_update("/some/file.rrd", "N:1245:98344");
15   if ( $ret == 0 )
16   {
17       $err = rrd_error();
18       echo "ERROR occurred: $err\n";
19   }
20  /* else rrd_update() was successful */
23 ?>