I have created a function, myurl, that I use as a replacement for
pylons.url with the goal of giving fully-qualified URLs by default. I
implement this functionality by applying the keyword argument
"qualified=True" to everything. E.g.,
def myurl(*args,**dargs) :
dargs['qualified']=True
return url(*args,**dargs)
Now, per the documentation, I have a static route to an external
website declared as follows:
map.connect('create_facebook_page', 'http://www.facebook.com/pages/
create.php', _static=True)
When I call myurl('create_facebook_page') - hence,
url( 'create_facebook_page',qualified=True) - I get the nonsensical
result "http://myhost//www.facebook.com/pages/create.php".
To me, this does not seem like the most desirable behavior. Ideally,
pylons.url would be "smart" enough to know that routes to external
sites do not need further qualification, and would simply ignore the
qualified=True option. As a second-best, it would throw an error.
Does anyone want to chime in before I file a ticket? I am on v0.9.7.
Perhaps this is corrected in v1.0?
Thanks,
Brian
--
You received this message because you are subscribed to the Google Groups
"pylons-discuss" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/pylons-discuss?hl=en.