August 6th, 2007, 11:23 PM
Get current file name and path
Hi. In PHP it is commong to do something like this:
dirname() returns the full path to the directory that the current file is in; __FILE__ is the name of the file that this line is in.
Something else that comes in handy in PHP too, is the __LINE__ constant, which gives you the line number that __LINE__ is on.
Is there an equivalent in Python? Thanks.
August 7th, 2007, 12:01 AM
I got it.