you can just use getResources:
<ul>
[[getResources?
&parents=`7`
&includeContent=`1`
&sortby=`pub_date`
&sortdir=`DESC`
&limit=`3`
&tpl=`@INLINE <li> <a href="[[+content]]" target="_blank"> [[+description]]</i> - [[+pagetitle]]</a></li> `
]]
</ul>
This is actually from a different MySQL database than the one this install of ModX is using - same server, different install of ModX.
-
☆ A M B ☆
- 24,524 Posts
Okay, thank you for the link. I've been able to get it connected and to display the number of rows (which is what the example shows) however I can't figure out how to grab data from the table and print it until all the rows have been printed.
I'm sorry I'm not a programmer, but I really can't figure out how to get this to do this part:
// keeps getting the next row until there are no more to get
while($row = mysql_fetch_array( $result )) {
// Print out the contents of each row into a table
echo "<li>";
etc...
Thanks so much!