[support] Views: is better node or fields for the "Row styles" ?
Michel Morelli
michel at ziobuddalabs.it
Thu Oct 8 08:24:45 UTC 2009
Larry Garfield ha scritto:
> Actually, I virtually never use "node" rows. A node row does a full node load
> for every node that gets loaded. A full node load could mean anywhere from
> 5-15 queries depending on what modules you have installed... *per node*.
> That's in addition to the query of the view itself. You can easily burn 100
> queries that way.
>
Ok, but why the VIEW extract the "node" that corrispond to my "request"
via a "SELECT DISTINCT node.nid" ?
I have analyzed the query via hook_views_pre_executed().
> You also then cannot effectively theme the node rows separately from their
> normal "page at node/X" and teaser versions. It uses the same theming.
>
No. For the "node" row I can use node-view-MYVIEWNAME.tpl.php so I can
use a template file only for the result of the view.
> With a fields-based row style, most fields (although not all) can be gotten in a
> single query for the view itself.
Ok, but how to recreate (via fields row) a structure like this:
<a href="#NODE/NID#">
<img src=#IMG#>
#TITLE#
</a>
With "node" rows I use a node-view-MYVIEWNAME.tpl.php and I have what I
want.
--
Michel 'ZioBudda' Morelli michel at ziobuddalabs.net
Sviluppo applicazioni CMS DRUPAL e web dinamiche (LAMP+Ajax)
Telefono: 0200619074
Telefono Cell: +39-3939890025 -- Fax: +39-0291390660
http://www.ziobudda.net ICQ: 58351764
http://www.ziobuddalabs.it Skype: zio_budda
http://www.ziodrupal.net MSN: michel at ziobuddalabs.it
JABBER: michel at ziobuddalabs.it
More information about the support
mailing list