Hello,
this functionality should be already there. Doesn't work for you?
Cheers,
Daniel
On 8/14/12 7:16 PM, Brandon Armstead wrote:
Sorry to wake up an old thread.
However - I am looking to export this $timef function to the param
initialization for accounting, i.e. db_table_acc
modparam("db_table_acc", "acc_$ftime(Ymd)");
I've looked into completing this myself however I simply am not
familiar enough at this point between the three different modules that
it would take to implement this (acc, dbsr1, pv).
Look forward to any help / insight you may be able to provide.
Thanks as always!
Sincerely,
Brandon Armstead
On Mon, Dec 19, 2011 at 11:55 AM, Daniel-Constantin Mierla
<miconda(a)gmail.com <mailto:miconda@gmail.com>> wrote:
Hello,
On 12/19/11 7:50 PM, Andreas Granig wrote:
Hi Daniel,
On 12/19/2011 07:29 PM, Daniel-Constantin Mierla wrote:
I don't know what are all the functions you think of, but
for the
example provided above, config file does it easy right
now. There is a
pseudo-variable that gives broken-time attribute that can
be used with
avp_check(), iirc, should be:
avp_db_load(...);
if(avp_check("$time(wday)", "eq/$avp(s:cf_weekday)/g"))
{
do CF }
Of course there is the option of doing while loop, but
maybe gets to
large for desired config file.
This is pretty much what I had in mind with my new
functions/module, but
I've completely overlooked that PV when searching the docs for
this
feature. Thank you very much for pointing that out!
for sake of public knowledge, just to add on time specific
features: there is also $timef(format) which returns current time
attributes based on strftime specifiers -- its documentation was
missing, I just added it. Also, there is a transformation
{s.ftime,format) which can take any integer variable holding
timestamp and return value based on strftime format.
Cheers,
Daniel
--
Daniel-Constantin Mierla --
http://www.asipto.com
http://linkedin.com/in/miconda --
http://twitter.com/miconda
_______________________________________________
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing
list
sr-users(a)lists.sip-router.org <mailto:sr-users@lists.sip-router.org>
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
--
Daniel-Constantin Mierla -
http://www.asipto.com
http://twitter.com/#!/miconda -
http://www.linkedin.com/in/miconda
Kamailio Advanced Training, Seattle, USA, Sep 23-26, 2012 -
http://asipto.com/u/katu
Kamailio Practical Workshop, Netherlands, Sep 10-12, 2012 -
http://asipto.com/u/kpw