Enumerate content in custom view template I am very new in Drupal. I am using Drupal 7.
I would like to create a custom rendering for a view I have created. 
Thanks to many posts found on the internet I have already done the following steps:


Created a content type with Title and URL (it simulate a link list)
Added 4 items of this content type
Created a view which return items of my content type unsorted 
Thanks to the Theme Information link I have created a template named views-view--xxxx--page.tpl.php where xxxx is the name of my view.
I have added the following code to the TPL file



&lt;article id="node-123456"&gt;
    &lt;header&gt;
        &lt;h1&gt;Sample Title&lt;/h1&gt;
    &lt;/header&gt;
    &lt;div class="content"&gt;
    &lt;/div&gt;
    &lt;footer&gt; &lt;/footer&gt;
&lt;/article&gt;



And this works perfectly because I am seeing the Sample Title text when navigating on the page. I want now to enumerate the list of content item produced by the view but I dont know how to enumerate them. I have tried with 

&lt;ul&gt;
&lt;?php foreach ($rows as $id =&gt; $row): ?&gt;
    &lt;li&gt;&lt;?php print $view-&gt;render_field('field_url', $id);?&gt;&lt;/li&gt;
&lt;?php endforeach; ?&gt;
&lt;/ul&gt;
Welcome to Drupal!

Use row level templating in template suggestion and follow exactly the same markup so your code should look like the following

&lt;article id=""&gt;
    &lt;header&gt;
        &lt;h1&gt;&lt;?php print $fields['title']-&gt;content; ?&gt;&lt;/h1&gt;
    &lt;/header&gt;
    &lt;div class="content"&gt;
    &lt;/div&gt;
    &lt;footer&gt; &lt;/footer&gt;
&lt;/article&gt;


It will follow the same markup for each row.