Re: [web2py] Re: Referencing Images From the Database

2010-06-07 Thread Vasile Ermicioi
this is a best practice in web2py, especially if you are going later to play with routes (both in and out)

[web2py] Re: Referencing Images From the Database

2010-06-07 Thread mdipierro
In general you should never hard code URLs in web2py, but use the URL function to generate them. This provides routing, reverse routing and makes user the links do not break if the app gets moved/renamed. On Jun 7, 11:34 am, Aaron Crowe wrote: > Ahhh thank you so much. That solves a major headach

[web2py] Re: Referencing Images From the Database

2010-06-07 Thread Aaron Crowe
Ahhh thank you so much. That solves a major headache for me. On Jun 7, 12:29 pm, mdipierro wrote: > this is a no-no. If you see a .. in a path, something is wrong. This > is how you do it > > src="{{=URL(request.application,'default','download',args=row.file)}}" / > > > > you must have the 'down

[web2py] Re: Referencing Images From the Database

2010-06-07 Thread mdipierro
this is a no-no. If you see a .. in a path, something is wrong. This is how you do it you must have the 'download' action in default.py On Jun 7, 11:26 am, Aaron Crowe wrote: > I have an image stored in the database as db.comment.file and I'm > trying to view it by using its location in applic