[TriLUG] Smarty

Brian Henning bhenning at pineinst.com
Thu Sep 19 13:24:12 EDT 2013


Brian,

Can you not limit your database read (i.e. a carefully-crafted WHERE or
LIMIT in sql parlance) instead of limiting the iteration afterwards?

~Brian (who knows nothing of Smarty)


-----Original Message-----
From: trilug-bounces at trilug.org [mailto:trilug-bounces at trilug.org] On Behalf
Of Brian McCullough
Sent: Thursday, September 19, 2013 11:45 AM
To: Triangle Linux Users Group discussion list
Subject: [TriLUG] Smarty

Drawing once again on the deep well of knowledge here, I have a question
about Smarty.

If there a "break" ( exit early ) statement in the "foreach" block in
Smarty 2?

I have been reading the documentation and I don't seem to see that kind
of functionality.


Basically, I have a database read providing the array of data being
displayed, but I want to stop displaying after a certain number of
items, rather than blindly displaying everything, no matter what.


Thanks,
Brian


-- 
This message was sent to: Brian <bhenning at pineinst.com>
To unsubscribe, send a blank message to trilug-leave at trilug.org from that
address.
TriLUG mailing list : http://www.trilug.org/mailman/listinfo/trilug
Unsubscribe or edit options on the web	:
http://www.trilug.org/mailman/options/trilug/bhenning%40pineinst.com
Welcome to TriLUG: http://trilug.org/welcome




More information about the TriLUG mailing list