Hi All,
Sorry for the OT:
I'm new to PHP, and am trying to find out if there is the equivalent
of application.cfc onrequest() function:
I.e, I want to be able to do this, without having to put the includes
in every file:
cffunction name=onrequest
cfargument name=targetpage''
02 11:35:43 2007
Subject: OT: php equivalent of application.cfc
Hi All,
Sorry for the OT:
I'm new to PHP, and am trying to find out if there is the equivalent
of application.cfc onrequest() function:
I.e, I want to be able to do this, without having to put the includes
in every file
Hey Tom -
It's been a couple of years (like 5), but as of PHP 4, there was a
setting in php.ini that allowed you to define a file that would be
called before every request the way Application.cfm is called. You
have to define it explicitly, but it behaves exactly the same way, in
my experience.
That sounds like the sort of thing I'm after...
Will now have to see if I can get to the ini file on shared hosting :(
T
On 2 Mar 2007, at 13:01, Rob Wilkerson wrote:
Hey Tom -
It's been a couple of years (like 5), but as of PHP 4, there was a
setting in php.ini that allowed you to define
On Friday 02 Mar 2007, Tom King wrote:
I.e, I want to be able to do this, without having to put the includes
in every file:
Every PHP app I've looked at has an include_once() at the top of each file :-/
--
Tom Chiverton
Helping to augmentatively transition revolutionary segments
On:
That could work (as would the related require_once() function), but
it's maintenance-intensive since it has to be explicitly included on
every page. Look at the auto_prepend_file directive in php.ini (I
looked it up and I think that's what I was referring to in my earlier
post). If you need
On Friday 02 Mar 2007, Rob Wilkerson wrote:
That could work (as would the related require_once() function), but
it's maintenance-intensive since it has to be explicitly included on
every page.
OTTOMH:
find . -name '*.php' -exec cp {} {}.1;cat header.php {}.1 {} \;
:-)
--
Tom Chiverton
Ugh. :-)
On 3/2/07, Tom Chiverton [EMAIL PROTECTED] wrote:
On Friday 02 Mar 2007, Rob Wilkerson wrote:
That could work (as would the related require_once() function), but
it's maintenance-intensive since it has to be explicitly included on
every page.
OTTOMH:
find . -name '*.php' -exec
hehe, so glad I don't have to deal with this on a regular basis -
thanks for the tips!
T
On 2 Mar 2007, at 14:05, Rob Wilkerson wrote:
Ugh. :-)
On 3/2/07, Tom Chiverton [EMAIL PROTECTED] wrote:
On Friday 02 Mar 2007, Rob Wilkerson wrote:
That could work (as would the related
9 matches
Mail list logo