arrays

onid

No avatar

2007-09-01 00:43

Hi,

I am trying to display an array I have created in pages_list.tpl using the page number.
$my_array[$aList[iPage]]

but this code doesn't work, is there a way I can do this.

thanks

merci

No avatar

2007-09-03 08:40

onid - cna you send us a link to your page, and write what exactly do you want to display in that array.

onid

No avatar

2007-09-03 10:30

I can't send a link because it is in the admin area. the file is '/templates/admin/pages_list.tpl'.
I have written a script that records page hits and stores them in an array.
I want to show the page hits for each page in 'pages_list.tpl'
Instead of using $my_array[10], I want to use the number stored inside $aList[iPage].

'/templates/admin/pages_list.tpl' ;
<!-- BEGIN LIST_LIST -->
<tr class="l_$aList[iDepth]">
<td>
$aList[iPage]
</td>

<td>
$my_array[ $aList[iPage] ]
</td>

<td class="name">
<a href="?p=$aActions[g]Form&amp;iPage=$aList[iPage]">$aList[sName]</a>
</td>
<td>
$aList[iPosition]
</td>
<th>
<a href="?p=$aActions[g]Form .................

merci

No avatar

2007-09-05 09:31

onid - the problem is that you should $my_array[$aList[iPage]] put in actions_client/p_.php. It can't be in tpl file.

Back to top
about us | contact