What the example5-handler does is that it parses the url entered and if the
url does not satisfy the given conditions, displays a message. However, if
the conditions are satisfied by the url entered the example5-handler
returns DECLINED.
This is where the example1-handler is called and executed.
On Tue, Jul 19, 2016 at 4:21 PM, Yann Ylavic wrote:
>
> There are other ways to do this (by setting an environment variable
> with for example SetEnvIf, and checking it in your handler), in any
> case a DECLINing handler should not have to deal with r->handler
> unless it knows which handler to fo
On Tue, Jul 19, 2016 at 2:42 PM, Amlaan Kar wrote:
> example1_handler is as given below:
> module AP_MODULE_DECLARE_DATA example1_module;
>
> static int example1_handler(request_rec *r)
> {
> if (!r->handler || strcmp(r->handler, "example1-handler")) return
> (DECLINED);
So it does nothing un
example1_handler is as given below:
module AP_MODULE_DECLARE_DATA example1_module;
static int example1_handler(request_rec *r)
{
if (!r->handler || strcmp(r->handler, "example1-handler")) return
(DECLINED);
ap_set_content_type(r, "text/html");
ap_rprintf(r, "Hello, world!");
return
On Tue, Jul 19, 2016 at 2:15 PM, Amlaan Kar wrote:
> static void register_hooks(apr_pool_t *pool)
> {
> static const char *const succs[] = {"mod_example1.c", NULL };
> ap_hook_handler(example5_handler, NULL, succs, APR_HOOK_FIRST);
> }
> AP_DECLARE_MODULE(example5) =
> {
> STANDARD20_M
static void register_hooks(apr_pool_t *pool)
{
static const char *const succs[] = {"mod_example1.c", NULL };
ap_hook_handler(example5_handler, NULL, succs, APR_HOOK_FIRST);
}
AP_DECLARE_MODULE(example5) =
{
STANDARD20_MODULE_STUFF,
NULL,
NULL,
NULL,
NULL,
NULL,
r
The first handler runs properly. However, the successor does not run.
The module I am using has been written by me and is not a built-in one.
Is there any separate method for httpd built-in handlers?
On Tue, Jul 19, 2016 at 5:37 PM, Yann Ylavic wrote:
> On Tue, Jul 19, 2016 at 1:58 PM, Amlaan
On Tue, Jul 19, 2016 at 1:58 PM, Amlaan Kar wrote:
> Thank You for answering. The method described above is not working.
Please describe not working..
Your handler does not run before the one you specified as successor ?
> Do I
> have to make any changes before using the above given code?
> PS:
Thank You for answering. The method described above is not working. Do I
have to make any changes before using the above given code?
PS: Both the handlers work properly individually
On Tue, Jul 19, 2016 at 4:44 PM, Yann Ylavic wrote:
> On Tue, Jul 19, 2016 at 12:29 PM, Amlaan Kar wrote:
> > I h
On Tue, Jul 19, 2016 at 12:29 PM, Amlaan Kar wrote:
> I have two handlers to be accessed. My motive is to use the second handler
> if the first handler returns DECLINED.
>
> I have tried various combinations of SetHandler, AddHandler and AddType but
> none has worked as overriding takes place in a
I have two handlers to be accessed. My motive is to use the second handler
if the first handler returns DECLINED.
I have tried various combinations of SetHandler, AddHandler and AddType but
none has worked as overriding takes place in all of these combinations.
Is there any method in Apache to us
11 matches
Mail list logo