|
|
Line 20: |
Line 20: |
| {list_sites} | | {list_sites} |
| {foreach from=$sites key=site_id item=site_name} | | {foreach from=$sites key=site_id item=site_name} |
− | <br /><br /> Site :<b>{$site_name}</b>:
| |
| <b>5 Latest FHG for {$site_name}:</b> | | <b>5 Latest FHG for {$site_name}:</b> |
− | {display_adtools data_only=1 order="published_date DESC" count=5 category=2 typeid=2 siteid=$site_id}
| + | {display_adtools data_only=1 order="published_date DESC" count=5 category=2 typeid=2 siteid=$site_id} |
− | {foreach from=$adtools key=adtool_id item=adtool_data}
| + | {foreach from=$adtools key=adtool_id item=adtool_data} |
− | {nats_encode siteid=$siteid programid=1 userid=$toid adtoolid=$adtool_id}<br />
| + | {nats_encode siteid=$siteid programid=1 userid=$toid adtoolid=$adtool_id}<br /> |
− | <a href="{$encoded}">{$adtool_data.name}</a><br />
| + | <a href="{$encoded}">{$adtool_data.name}</a><br /> |
− | <b>{$adtool_data.description}</b>
| + | <b>{$adtool_data.description}</b> |
− | {/foreach}
| + | {/foreach} |
| {/foreach} | | {/foreach} |
| </pre> | | </pre> |
Line 33: |
Line 32: |
| *"{list_sites}" - is creating an array with all sites<br> | | *"{list_sites}" - is creating an array with all sites<br> |
| *"{foreach from=$sites key=site_id item=site_name}" - will loop through every site defining a variable for both its id(key) and name(item)<br> | | *"{foreach from=$sites key=site_id item=site_name}" - will loop through every site defining a variable for both its id(key) and name(item)<br> |
− | *"{$site_name}": - will display "Site :" and then the current site name that the loop is on <br>
| |
| *"5 Latest FHG for {$site_name}": - will display the text "5 Latest FHG for " and then your current site name <br> | | *"5 Latest FHG for {$site_name}": - will display the text "5 Latest FHG for " and then your current site name <br> |
| *"{display_adtools data_only=1 order="published_date DESC" count=5 category=2 typeid=2 siteid=$site_id}" - doesnt actually display anything, what it does is grab paramaters such as order, count, category, typeid, and siteid. As you can see in this example, it will count the latest 5 sites within category 2 (hosted galleries)and typeid 2 (free hosted galleries) for siteid of the current site the loop is on.<br> | | *"{display_adtools data_only=1 order="published_date DESC" count=5 category=2 typeid=2 siteid=$site_id}" - doesnt actually display anything, what it does is grab paramaters such as order, count, category, typeid, and siteid. As you can see in this example, it will count the latest 5 sites within category 2 (hosted galleries)and typeid 2 (free hosted galleries) for siteid of the current site the loop is on.<br> |