Hi there,
I'm using Php version 4.0.5 on PWS
with this codes
@include('adodb\adodb.inc.php'); // load code common to ADODB
ADOLoadCode('access'); // load Access code
$con = &ADONewConnection(); // create a connection
$con->PConnect('CD'); // connect to MS-Access using DSN name
$recordSet = &$con->Execute('select max(UniqueNum) from Num');
$num = $recordSet->fields[0].' '.@$recordSet->fields[1];
$num = $num + 1;
print $num;
@print str_pad($num, 4, '0', STR_PAD_LEFT);
//$con->Close();
}
But when I port it over to IIS that has Php version 4.0.1pl2, its very clear that str_pad() doesn't work.
From the php manual (in chm format), it is said that str_pad function works for php ver (PHP 4 >= 4.0.1)
I'm puzzled as to why I can't get the str_pad to work. could it be the IIS or the php4isapi.dll file is corrupted? or are there any reasons to this problem?