Using sql.php from an AGI?

Patrick_elx

Joined
Dec 14, 2008
Messages
1,120
Likes
0
Points
0
#1
I'm having some trouble with Freepbx sql.php library for an agi.

I can use it without problem to access the asterisk database, however I can't use this class to access the asteriskcdrb.

The problem is that $dbname is declared as private. If I replace private by public in sql.php I can then do a
$db2 = new AGIDB($AGI);
$db2->dbname='asteriskcdrdb';
and it works well.

Is there a way to use the public $dbhandle to change the $dbname from the agi without having to change sql.php?
 

Members online

No members online now.

Latest posts

Forum statistics

Threads
30,902
Messages
130,887
Members
17,565
Latest member
omarmenichetti
Top