Re: Generic routes for API functions

2009-11-24 Thread Mike Orr
On Tue, Nov 24, 2009 at 1:35 AM, Mike Burrows (asplake) m...@asplake.co.uk wrote: Maybe.  The action name implies the nature of the ID.  And you have to validate/convert the ID anyway, so 'id' is not necessarily the same as 'acct' or 'name'.  Action methods by definition take routing variables

CSS, images and JavaScript in /template?

2009-11-24 Thread jon
Hi, I'm wondering if it's possible to put CSS, images and JavaScript into the /template directory of Pylons and somehow get the Mako templates to refer to those files and not the ones in /public? I'm building a system which is themeable and I want to keep all of the theme files together and

Re: Generic routes for API functions

2009-11-24 Thread Wyatt Baldwin
On Nov 24, 9:44 am, Mike Orr sluggos...@gmail.com wrote: [...] I normally do use specific variable names.  But that's impossible when you want to have a generic route that serves a variety of different purposes.  You can't have two routes whose paths differ only by a variable name, because

Re: CSS, images and JavaScript in /template?

2009-11-24 Thread Wyatt Baldwin
On Nov 24, 10:30 am, jon jon.wyna...@lucasfilm.com wrote: Hi, I'm wondering if it's possible to put CSS, images and JavaScript into the /template directory of Pylons and somehow get the Mako templates to refer to those files and not the ones in /public? I'm building a system which is

Re: Counting feed subscribers

2009-11-24 Thread Damjan
The only thing I can think of is to put a random number in a query parameter when generating feed URLs.  Then the number of active feeds each month would be the count of unique feed numbers. Or is there a better way? route them through feedburner? :) -- You received this message because you

Re: Generic routes for API functions

2009-11-24 Thread Mike Burrows (asplake)
Apologies if this comes out as a (near) dupe - I was sure I had replied to this! On Nov 24, 5:44 pm, Mike Orr sluggos...@gmail.com wrote: By described_routes I guess you mean this:http://github.com/asplake/described_routes/tree Yes, that's it It looks like a pretty printer for route

Re: Generic routes for API functions

2009-11-24 Thread Mike Orr
On Tue, Nov 24, 2009 at 10:47 AM, Mike Burrows (asplake) m...@asplake.co.uk wrote: Yes it uses standard Rails routes, and no it doesn't address output formats (nor will it). I'm not sure what this means. XML, JSON, YAML, and text are all output formats, which it does. Yes there's a small

WebHelpers status

2009-11-24 Thread Mike Orr
Thanks to everyone who has posted WebHelpers bugfixes the past few days. As soon as I feel up to it (I'm currently home sick), I'll put them in. I'd still like to communicate with everybody who uses webhelpers.feedgenerator, so if that's you, please send me a note. -- Mike Orr

Re: CSS, images and JavaScript in /template?

2009-11-24 Thread Jonathan Vanasco
you could put everything into /templates/_themes and then have routes/a controller dispatch stuff to the right files as needed -- You received this message because you are subscribed to the Google Groups pylons-discuss group. To post to this group, send email to

Re: Generic routes for API functions

2009-11-24 Thread Mike Burrows (asplake)
On Nov 24, 7:39 pm, Mike Orr sluggos...@gmail.com wrote: On Tue, Nov 24, 2009 at 10:47 AM, Mike Burrows (asplake) Yes it uses standard Rails routes, and no it doesn't address output formats (nor will it). I'm not sure what this means.  XML, JSON, YAML, and text are all output formats,

Re: Generic routes for API functions

2009-11-24 Thread Wyatt Baldwin
On Nov 24, 11:39 am, Mike Orr sluggos...@gmail.com wrote: [...] That would be great.  The data structures in Mapper and Route are rather opaque and underdocumented though. We're considering a more transparent structure for a future version of Routes. Sign me up for that, at least as an

Re: Generic routes for API functions

2009-11-24 Thread Mike Orr
On Tue, Nov 24, 2009 at 1:10 PM, Mike Burrows (asplake) m...@asplake.co.uk wrote: On Nov 24, 7:39 pm, Mike Orr sluggos...@gmail.com wrote: On Tue, Nov 24, 2009 at 10:47 AM, Mike Burrows (asplake) On a related subject, I'm a little concerned that Pylons has the choice of constraining

Re: Generic routes for API functions

2009-11-24 Thread Mike Orr
On Tue, Nov 24, 2009 at 1:40 PM, Wyatt Baldwin wyatt.lee.bald...@gmail.com wrote: On Nov 24, 11:39 am, Mike Orr sluggos...@gmail.com wrote: [...] That would be great.  The data structures in Mapper and Route are rather opaque and underdocumented though. We're considering a more transparent

Re: CSS, images and JavaScript in /template?

2009-11-24 Thread jon
These all seem like really good ideas, for certain. What I ended up doing is in my middleware.py I query my database to get all the current themes and a dirname attribute. I then build and add the paths for each theme along with building a StaticURLParser for each theme. All of that gets passed

Re: WebHelpers status

2009-11-24 Thread Gael Pasgrimaud
Hi Mike, On Tue, Nov 24, 2009 at 8:43 PM, Mike Orr sluggos...@gmail.com wrote: Thanks to everyone who has posted WebHelpers bugfixes the past few days.  As soon as I feel up to it (I'm currently home sick), I'll put them in. I'd still like to communicate with everybody who uses

Re: CSS, images and JavaScript in /template?

2009-11-24 Thread Wyatt Baldwin
On Nov 24, 3:22 pm, jon jon.wyna...@lucasfilm.com wrote: These all seem like really good ideas, for certain. What I ended up doing is in my middleware.py I query my database to get all the current themes and a dirname attribute. I then build and add the paths for each theme along with building

Beaker 1.5 Release

2009-11-24 Thread Ben Bangert
Beaker 1.5 has been released, it was mainly a bug fix, though there's a new decorator for cache regions that does *not* require caching to be configured before its used. This makes it possible to decorate functions in the top level of a module, then have the config setup before they're used.