# Export help

**URL:** https://community.mp3tag.de/t/export-help/13614
**Category:** Support
**Created:** [July 5, 2012, 1:22am UTC](https://community.mp3tag.de/t/export-help/13614 "2012-07-05T01:22:18Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![kittmaster](https://community.mp3tag.de/user_avatar/community.mp3tag.de/kittmaster/32/14793_2.png) [@kittmaster](https://community.mp3tag.de/u/kittmaster)
#### Post date: [July 5, 2012, 1:22am UTC](https://community.mp3tag.de/t/export-help/13614/1 "2012-07-05T01:22:18Z")

</div>

I'm trying to do an export of the %publisher% field, I use it for transistion data. When I export using:

%PUBLISHER%

if there is no data in the publisher field while the rest of the fields that do have data, a table border is drawn around it if there is data in it, when there is no data, the table border is not drawn, if I put a -134 for example, then the publisher field draws the border and puts the related data there.

Is there a way in the export to do something like:

[if2(%PUBLISHER%,"")]

Which clearly doesn't work.

Any thoughts to handle this?

Thanks

Here is the full export script:

```
</p><p>$filename(%_directory%_ABP_MASTER.html)<html>
    <html>
    <head>
        <meta name="GENERATOR" content="">
        <meta HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=utf-8">
    
        <style type="text/css"><!--
            h1 { color: #FFAA55; font-family: Calibri; font-size: 11pt }
            h2 { font-family: Calibri; font-size: 9pt }
            h3 { color: #000000; font-family: Calibri; font-size: 9pt }
            body { font-family: Calibri; font-size: 8pt }
            table { font-family: Calibri; font-size: 8pt }
            a {color: #A10000; text-decoration: none }
            a:hover {color: #A10000; text-decoration: none}
            #wrap { width: 95%%; }
            .tbox { padding: 10px; margin: 10px; background-color: #EFEFEF;}
        --></style>
    </head>
    
    
    
    <body>
    <body bgcolor="000000">
    <div id="wrap">
    $loop(%_folderpath%)
    <div class="tbox">
        <table border="0" width="100%%">
            <tr>
                <td width="75%%">
                    <table border="0" width="40%%">
                        <tr>
                            <td width="5%%" valign="top">
                                <h1>ALBUM: </h1>
                            </td>
                            <td width="20%%" valign="top">
                                <h1>%album%</a></h1>
                            </td>
                        </tr>
                        <tr>
                            <td width="5%%" valign=top>
                                <h1>YEAR: </h1>
                            </td>
                            <td width="20%%" valign=top>
                                <h1>%year%</h1>
                            </td>
                        </tr>
                    </table>
                </td>            
                <td width="25%%" rowspan=4 valign="top" align="right">                
                </td>
            </tr>
        </table>
    
        <table border="2" bgcolor="DCDCDC" width="100%%">
            <tr bgcolor="#AAAAAA">
                <td align="center"><b>TRACK</b></td>
                <td><b>ARTIST</b></td>
                <td><b>TITLE</b></td>            
                <td align="center"><b>BPM</b></td>
                <td align="center"><b>LABEL</b></td>
                <td align="center"><b>INITIAL KEY</b></td>
                <td align="center"><b>LENGTH</b></td>
                <td align="center"><b>BITRATE</b></td>
                
            </tr>
    
    $loop(%_path%) <tr>
                <h3>
                <td width=1 valign="top" align="center">[$num(%track%,1)]</td>
                <td width=1 td valign="top">$if(%album artist%,%artist% - ,)%artist%</a></td>
                <td width=1 td valign="top">$if(%album artist%,%artist% - ,)%title%</a></td>
                <td width=1 valign="top" align="center">%bpm%</td>
                <td width=1 valign="top" align="center">if2(%PUBLISHER%,"1")</td>
                <td width=1 valign="top" align="center">%initialkey%</td>
                <td width=1 valign="top" align="center">%_length%</td>
                <td width=1 valign="top" align="center">%_bitrate%</td>
                <td width=1 valign="top" align="center"></td></h3>
            </tr>
    $loopend()
    
    </table>
    </div>
    $loopend()
    </div>
    </div>
    </body>
    </html></p><p>
```

---

<div class="post-metadata">

### Author: ![DetlevD](https://community.mp3tag.de/user_avatar/community.mp3tag.de/detlevd/32/123_2.png) [@DetlevD](https://community.mp3tag.de/u/DetlevD)
#### Post date: [July 5, 2012, 3:21am UTC](https://community.mp3tag.de/t/export-help/13614/2 "2012-07-05T03:21:50Z")

</div>

> [@kittmaster](#):
>
> ... When I export using:
> 
> %PUBLISHER% if there is no data in the publisher field while the rest of the fields that do have data, a table border is drawn around it if there is data in it, when there is no data, the table border is not drawn ...

Well, your question has mainly to do with scripting in the HTML language and how to apply table formatting rules.  
Because your Mp3tag MTE script, which in turn creates a HTML script, both scripting layers have some quirks embedded, I do recommend that you learn how to write MTE script and HTML script error free and how to apply HTML TABLE formatting rules.  
Learn from there ...  
[http://www.w3schools.com/html/default.asp](http://www.w3schools.com/html/default.asp)  
[http://de.selfhtml.org/](http://de.selfhtml.org/)  
[http://www.google.de/search?q=html%20table...le%20formatting](http://www.google.de/search?q=html%20table%20style%20OR%20html%20table%20formatting)

A simple work around the problem of a borderless empty TD cell is to fill the cell with an invisible value, for example with one "non breaking space".

**$if2(%PUBLISHER%,'&nbsp;')**

DD.20120705.0730.CEST

---

<div class="post-metadata">

### Author: ![kittmaster](https://community.mp3tag.de/user_avatar/community.mp3tag.de/kittmaster/32/14793_2.png) [@kittmaster](https://community.mp3tag.de/u/kittmaster)
#### Post date: [July 5, 2012, 10:10am UTC](https://community.mp3tag.de/t/export-help/13614/3 "2012-07-05T10:10:12Z")

</div>

That workaround is exactly what I was looking for. I know my export isn't perfect, just need it to do a summary view. I'm finding that I using the HTML to do a fast review is easier on my eyes than trying to do it in the app.

I was trying to place "" in there and had the wrong syntax for the language requirement.

Thanks for the help

Chris

---

<div class="post-metadata">

### Author: ![DetlevD](https://community.mp3tag.de/user_avatar/community.mp3tag.de/detlevd/32/123_2.png) [@DetlevD](https://community.mp3tag.de/u/DetlevD)
#### Post date: [July 5, 2012, 3:29pm UTC](https://community.mp3tag.de/t/export-help/13614/4 "2012-07-05T15:29:38Z")

</div>

> [@kittmaster](#):
>
> That workaround is exactly what I was looking for. I know my export isn't perfect, just need it to do a summary view. I'm finding that I using the HTML to do a fast review is easier on my eyes than trying to do it in the app. ...

Yes, all the small font in Mp3tag edit fields is also beginning to hurt me.

DD.20120705.1929.CEST

---

<div class="post-metadata">

### Author: ![system](https://community.mp3tag.de/uploads/default/original/2X/c/ce7035d426cb755a7916793326d23b465222a407.png) [@system](https://community.mp3tag.de/u/system)
#### Post date: [February 9, 2026, 12:23pm UTC](https://community.mp3tag.de/t/export-help/13614/5 "2026-02-09T12:23:55Z")

</div>


