That code is OK. What do you mean without result?
Antonio Zdilar
linearvector.com
I'm not sure if your code example is complete, but you need a getCollection() call (or something similar) to actually query the DB and you need to create and return some output so there's something to display:
<?php
$resources = $modx->getCollection('modResource', $c);
$output = '';
foreach ($resources as $resource) {
$output .= '<br />TITLE: ' . $resource->get('pagetitle');
}
return $output;
---------------------------------------------------------------------------------------------------------------
PLEASE, PLEASE specify the version of MODX you are using . . . PLEASE!
MODx info for everyone:
http://bobsguides.com/modx.html
Hi Guys thanks for your help, everything is working well...
BobRay thanks for your example, that give me to the right direction. I thought my xpdo was wrong, seem it was my code.
have a nice day guys.
I'm glad you got it sorted. Thanks for reporting back.
---------------------------------------------------------------------------------------------------------------
PLEASE, PLEASE specify the version of MODX you are using . . . PLEASE!
MODx info for everyone:
http://bobsguides.com/modx.html