Look into the Reverse module of PEAR MDB2.
http://pear.php.net/manual/en/package.database.mdb2.intro-reverse-module.php
Cheers,
Mattias
Matt Neimeyer wrote:
I know I CAN hack something together but I hate to reinvent the wheel.
I want to be able to compare the structure of two different clien
I don't understand completely your problem, but think that something
like this may help you:
This will output:
array(3) {
[0]=>
int(1)
[1]=>
int(2)
[2]=>
int(3)
}
As expected.
The key is using call_user_func_array in combination with
func_get_args to call the parent constructor wi
problem:
__ construct( $something ... variable argument list ){
parent::__construct( ??? );
}
I tried with func_get_args, but the problem is that it gives an indexed
array back.
lets say the argument list is mixed like this:
( "string", "string", array)
func_get_args will give this
[0] => "
Hi all
I posted this on the PHP-db list, but it is sunday.. and with so
little traffic today, perhaps no one will mind if I post this here
too? (with hoped I'll get a quicker pointer?).
I'm translating some code from another server-side language into PHP,
and I need something that 'summa
> I don't quite know how I can write a bite into a file. I also looked into a
> manual and couldn't find a mention of FLock-ing in the explaination for
> FOpen parameters.
Ok, from memory:
The 1 could be any single byte character I guess.
--
Richard Heyes
HTML5 graphing: RGraph - www.rgraph.n
Hello,
I had a thought today while walking...why do all ideas come while
walking under the sun rather than slouching in front of the LCD's glow?
Wouldn't it be cool to develop an application that allowed one to manage
Git via PHP? I'm thinking, sorta like how the PHPMyAdmin project helps
people
On Sun, Aug 2, 2009 at 2:24 PM, Larry Garfield wrote:
> On Saturday 01 August 2009 11:01:11 pm Eddie Drapkin wrote:
>> > I actually benchmarked that once. I had a reasonably large PHP file that
>> > was, in fact, over 50% docblocks. That's not even counting inline
>> > comments. While trying to
On Saturday 01 August 2009 11:01:11 pm Eddie Drapkin wrote:
> > I actually benchmarked that once. I had a reasonably large PHP file that
> > was, in fact, over 50% docblocks. That's not even counting inline
> > comments. While trying to find things to optimize, removing about 800
> > lines worth
Hi,
Does anyone has any idea how to create notification system with
combination of php, mysql and javascript. It should be something
similar to facebook notification system (when someone make some action
it should be automatically reported to other people on system through
pop-up menu or something
Dear Richard,
I don't quite know how I can write a bite into a file. I also looked into a
manual and couldn't find a mention of FLock-ing in the explaination for
FOpen parameters.
Thanks a lot for your help.
--
---
Contact info:
Skype: parham-d
MSN: fire_lizard16 at hotmail dot com
email: parha
Now this one always sets the file to one for some reason. I'll reiterate
just in case there's been a misunderstanding on my part:
[code]
$fp = fopen($f, "r+");
while (!flock($fp, LOCK_EX))
sleep(1);
$count = fgets($fp,filesize($fp));
ftruncate($fp, 0);
fwrite($fp, ($count+1));
flock($fp, LOCK_UN);
On Sun, 02 Aug 2009 07:11:27 +0300, "Parham Doustdar"
wrote:
Dear Ollisso,
I tried it with FLock() but it still didn't work. This is what I did:
[code]
$fp = fopen($f, "r");
$count =fgets($fp, 1024);
fclose($fp);
$fw = fopen($f, "w");
while (!flock($fw, LOCK_EX))
sleep(1);
$cnew = $count + 1;
Hi,
> ...
You can write a single byte to the file to "increment" the counter,
then to read the count just use filesize(). I believe the a fopen()
mode will handle locking for you. It will result in a slowly growing
file, but space isn't exactly at a premium nowadays, and when the file
gets to a c
13 matches
Mail list logo