I've just been looking at an external script as an alternative option.
I remember now why I went the database route and doing it all in register.conf and the pg function!
Setting up an external script is straightforward.
I can also make it listen for the the call.route message event and point it at something eg tone/busy or moh/default to test.
But my problem has always been authentication.
The auth process it's self is ok,
My problem is when i come to route the call in the .php script, how do I check the user is authenticated before routing ?
There's no username parameter in my call.route, so I've installed user.auth as well.
But, if i try to listen for the the user.auth event, i can quite often get the call.route event before seeing an auth event, defeating the purpose.
I must be looking at this in the wrong way. I suspect priorities !
Sorry to leave you with two questions, but any pointers would be really helpful !
Thank you!
Jamie
PS I'm still using register.conf for it's other features, eg auth, cdr, line status etc