Jump to content

[SOLVED] function tracking


surion

Recommended Posts

Hello, i was wondering if it is possible in a function to track from where it got called,...

 

at the moment i have a function

 

function mysql_log_query($file,$line,$sql){

// some stuf

}

 

called this way: mysql_log_query(__FILE__,__LINE__,$sql);

 

it performs a mysql_query() for the given query ($sql) and if the query takes too long it makes a log for this, using __FILE__ & __LINE__ to determine from where it got called. now i was wondering, is it possible to do the same in that function without the use of __FILE__ and __LINE__?

 

i ask this because it would make me program alot faster if i don't have to type that __FILE__,__LINE__ all the time.

 

 

grz

 

Link to comment
https://forums.phpfreaks.com/topic/126584-solved-function-tracking/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.