Re: about request route

2017-08-07 Thread 风河
Thanks for all helps. On Mon, Aug 7, 2017, at 08:26 PM, André Warnier (tomcat) wrote: > On 07.08.2017 13:18, 风河 wrote: > > Hi, > > > > for this like request: > > curlhttp://dns-api.org//dns-api.org > > > > in Dancer we could write: > > > > get '/:type/:domain/?' => sub { > > > > my $rtype

Re: about request route ($r->path_info)

2017-08-07 Thread Randolf Richardson
In your "httpd.conf" file (for your VirtualHost if you're using virtual hosts) you'll need to add this line: AcceptPathInfoOn Then you may find the documentation surrounding $r->path_info to be of particular interest, which you can read about here:

Re: about request route

2017-08-07 Thread John Dunlap
This is what I do in our application, using a module that we created in-house: my $registry = ServiceRegistry->new; $registry->register('SERVICE1', '/api/rest/service1/{param1}/list'); my $service = $registry->find($r->uri); # $r->uri returns '/api/rest/service1/5732/list' print "$service\n"; # Pri

Re: about request route

2017-08-07 Thread Mithun Bhattacharya
Another way to look at this is Apache has hooks for the location - that is the URI you are requesting. Apache doesn't care whether you do a GET or a POST/PUT to it and it is left to the underlying subsytems to manage it - which is your case would be mod_perl. You can easily have the handler do a if

Re: unsubscribe

2017-08-07 Thread Clive Eisen
Quite AND the info is in the headers of EVERY email -- Clive Eisen GPG: 75056DD0 > On 7 Aug 2017, at 13:39, André Warnier (tomcat) wrote: > > On 07.08.2017 14:30, Timon Roth wrote: >> unsubscribe > > See : http://perl.apache.org/maillist/modperl.html#Subscription_Information > . unsubscr

Re: unsubscribe

2017-08-07 Thread tomcat
On 07.08.2017 14:30, Timon Roth wrote: unsubscribe See : http://perl.apache.org/maillist/modperl.html#Subscription_Information . unsubscribe from the list

unsubscribe

2017-08-07 Thread Timon Roth
unsubscribe

Re: about request route

2017-08-07 Thread tomcat
On 07.08.2017 13:18, 风河 wrote: Hi, for this like request: curlhttp://dns-api.org//dns-api.org in Dancer we could write: get '/:type/:domain/?' => sub { my $rtype = params->{ 'type' }; my $domain = params->{ 'domain' }; But in a MP handler, how could we get the similiar result

Re: about request route

2017-08-07 Thread Lathan Bidwell
Hello, MP does not by default include a routing engine like Dancer or Mojo or other frameworks. There are routing engines available (but I'm not very familair with them). For a pure MP option, see this example from something I've done: $base_uri = "/app/" uri = /app/type//domain/dns-api.org

about request route

2017-08-07 Thread 风河
Hi, for this like request: curl http://dns-api.org//dns-api.org in Dancer we could write: get '/:type/:domain/?' => sub { my $rtype = params->{ 'type' }; my $domain = params->{ 'domain' }; But in a MP handler, how could we get the similiar result, treating request path as GET/POS