db(some_query) creates a DAL Set object (on which you can then call methods
such as .select(), .update(), etc.). A Set object is also callable, and if
you call it by passing in another query, it will simply add the new query
as an AND condition. So, that code is just equivalent to:
db(
Note, I'm not sure the fact that a Set is callable is documented in the
book.
On Tuesday, May 21, 2013 4:14:48 PM UTC-4, Anthony wrote:
db(some_query) creates a DAL Set object (on which you can then call
methods such as .select(), .update(), etc.). A Set object is also callable,
and if you
Hm, but how does it know to return a set object from the product_filter
table rather than the product or filter table?
And what does these two queries mean when it comes executing the queries?
(db.products.id == db.product_filter.product_id)
(db.filters.id ==
all those (query) just add a bit of where clause in the select that you
pass to the db.
you can use them with db((query) (query) (query)) or with
db(query)(query)(query) ... the resulting select passed to the db would be
the same!
On Tuesday, May 21, 2013 10:43:48 PM UTC+2, brac...@gmail.com
it's explained here:
http://web2py.com/books/default/chapter/29/06#Many-to-many
Den tisdagen den 21:e maj 2013 kl. 22:02:00 UTC+2 skrev brac...@gmail.com:
Is there a section in the online web2py book that explains Niphlod's way
to building a query?
Near the bottom of this
Hm, but how does it know to return a set object from the product_filter
table rather than the product or filter table?
Set objects are not associated with a particular table -- they represent a
set of records to be returned by the db, which may involve a join of
multiple tables.
Take a look at this for the explanation of _why_ you use escaping:
http://en.wikipedia.org/wiki/Cross-site_scripting
On Sat, Dec 25, 2010 at 8:02 AM, Sahil Arora sahilarora...@gmail.com wrote:
thanks
On Sat, Dec 25, 2010 at 12:09 PM, Thadeus Burgess thade...@thadeusb.com
wrote:
Escape will
{{=x}}
is equivalent to
{{response.write(x,escape=True)}}
Did I answer the question?
On Dec 24, 10:04 pm, Sahil Arora sahilarora...@gmail.com wrote:
what do you mean by word 'escape' when we say escape = False
or
in
{{=x}}
Variables injected into the HTML in this way are escaped by
I am asking what does escape=true does
On Sat, Dec 25, 2010 at 11:02 AM, mdipierro mdipie...@cs.depaul.edu wrote:
{{=x}}
is equivalent to
{{response.write(x,escape=True)}}
Did I answer the question?
On Dec 24, 10:04 pm, Sahil Arora sahilarora...@gmail.com wrote:
what do you mean by
Escape will convert the text to html entities. For example,
x = A 'quote' is bbold/b
print response.write(x, escape=True)
A 'quote' is lt;bgt;boldlt;/bgt;
This protects your page from html injection hacks. If you need to display
html from a variable and you know absolutely sure that it is
thanks
On Sat, Dec 25, 2010 at 12:09 PM, Thadeus Burgess thade...@thadeusb.comwrote:
Escape will convert the text to html entities. For example,
x = A 'quote' is bbold/b
print response.write(x, escape=True)
A 'quote' is lt;bgt;boldlt;/bgt;
This protects your page from html injection
Oops. It seems the link got truncated
http://www.computer.org/portal/web/csdl/doi/10.1109/MCSE.2010.97
12 matches
Mail list logo