# adding a counter?

**URL:** https://community.mp3tag.de/t/adding-a-counter/8509
**Category:** Export
**Created:** [June 25, 2009, 11:12pm UTC](https://community.mp3tag.de/t/adding-a-counter/8509 "2009-06-25T23:12:49Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![nimedon](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/n/e495f1/32.png) [@nimedon](https://community.mp3tag.de/u/nimedon)
#### Post date: [June 25, 2009, 11:12pm UTC](https://community.mp3tag.de/t/adding-a-counter/8509/1 "2009-06-25T23:12:49Z")

</div>

Hello,  
Firstable I would like to thank all the mp3tag team for making such a great work,  
I am trying to make an exporte code with a counter, this is what I have:

```
$filename(html,utf-8)
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="de">
<head>
    <meta name="GENERATOR" content="Mp3tag - http://www.mp3tag.de" />
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>Mp3tag - File Overview</title>
    <style type="text/css"><!--
        h1 { font-family: Verdana, Tahoma, Arial, sans-serif; font-size: 14pt; color: #000 }
        body { font-family: Verdana, Tahoma, Arial, sans-serif; font-size: 8pt; background: #fff }
        table, tr, td { font-family: Verdana, Tahoma, Arial, sans-serif; font-size: 9pt; color: #000; }
        a:link, a:visited, a:active { text-decoration: none; color: #03f; }
        a:hover { text-decoration: none; color: #f03; }
        .title { font-weight: bold; padding: 7px; margin: 0px; color: #000; }
        .odd { background-color: #ccc; }
    --></style>
</head>
<body>
    <h1>Mp3tag - File Overview</h1>
    <p>%_date%</p>
    <table>
        <tr>
            <th class="title">No.</th>
            <th class="title">Title</th>
            <th class="title">Artist</th>
            <th class="title">Genre</th>
            <th class="title">Length</th>
            <th class="title">BitRate</th>
        </tr>

$loop(%_filename_ext%)
        <tr>    
            <td$if($odd(%_counter%), class="odd",)></td>
            <td$if($odd(%_counter%), class="odd",)>%title%</td>
            <td$if($odd(%_counter%), class="odd",)>%artist%</td>
            <td$if($odd(%_counter%), class="odd",)>%genre%</td>
            <td$if($odd(%_counter%), class="odd",)>%_length%</td>
            <td$if($odd(%_counter%), class="odd",)>%_bitrate% kBit/s</td>
        </tr>
$loopend()

    </table>
    
</body>
</html>

```

what should I put in the first

 so I can have counter, in the "No."

I just want a simple counter of the songs, 1,2,3,4,5,6

etc

Thanks!

---

<div class="post-metadata">

### Author: ![Stevest](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/s/a698b9/32.png) [@Stevest](https://community.mp3tag.de/u/Stevest)
#### Post date: [June 28, 2009, 1:14pm UTC](https://community.mp3tag.de/t/adding-a-counter/8509/2 "2009-06-28T13:14:35Z")

</div>

?

What is the problem with %\_counter%?

```
<td$if($odd(%_counter%), class="odd",)>%_counter%</td>
```
