$xml_output .= "\t\t</STYLE>\n";
// Begin <EQUIPMENT> tag
if ($source == "brewLog" && $row_log['brewEquipProfile'] != "") {
    $xml_output .= "\t\t<EQUIPMENT>\n";
    $replaced = strtr($row_equip_profiles['equipProfileName'], $html_remove);
    $xml_output .= "\t\t\t<NAME>" . $replaced . "</NAME>\n";
    $xml_output .= "\t\t\t<VERSION>1</VERSION>\n";
    if ($row_pref['measWeight2'] == "pounds") {
        $xml_output .= "\t\t\t<BOIL_SIZE>" . weightconvert($row_equip_profiles['equipBoilVolume'], "kilograms") . "</BOIL_SIZE>\n";
        $xml_output .= "\t\t\t<BATCH_SIZE>" . weightconvert($row_equip_profiles['equipBatchSize'], "kilograms") . "</BATCH_SIZE>\n";
        $xml_output .= "\t\t\t<TUN_VOLUME>" . weightconvert($row_equip_profiles['equipMashTunVolume'], "kilograms") . "</TUN_VOLUME>\n";
        $xml_output .= "\t\t\t<TUN_WEIGHT>" . weightconvert($row_equip_profiles['equipMashTunWeight'], "kilograms") . "</TUN_WEIGHT>\n";
        $xml_output .= "\t\t\t<TOP_UP_WATER>" . weightconvert($row_equip_profiles['equipTopUp'], "kilograms") . "</TOP_UP_WATER>\n";
        $xml_output .= "\t\t\t<LAUTER_DEADSPACE>" . weightconvert($row_equip_profiles['equipMashTunDeadspace'], "kilograms") . "</LAUTER_DEADSPACE>\n";
        $xml_output .= "\t\t\t<TOP_UP_KETTLE>" . weightconvert($row_equip_profiles['equipTopUpKettle'], "kilograms") . "</TOP_UP_KETTLE>\n";
        $xml_output .= "\t\t\t<TRUB_CHILLER_LOSS>" . weightconvert($row_equip_profiles['equipLoss'], "kilograms") . "</TRUB_CHILLER_LOSS>\n";
    } else {
        $xml_output .= "\t\t\t<BOIL_SIZE>" . $row_equip_profiles['equipBoilVolume'] . "</BOIL_SIZE>\n";
        $xml_output .= "\t\t\t<BATCH_SIZE>" . $row_equip_profiles['equipBatchSize'] . "</BATCH_SIZE>\n";
        $xml_output .= "\t\t\t<TUN_VOLUME>" . $row_equip_profiles['equipMashTunVolume'] . "</TUN_VOLUME>\n";
        $xml_output .= "\t\t\t<TUN_WEIGHT>" . $row_equip_profiles['equipMashTunWeight'] . "</TUN_WEIGHT>\n";
        $xml_output .= "\t\t\t<TOP_UP_WATER>" . $row_equip_profiles['equipTopUp'] . "</TOP_UP_WATER>\n";
        $xml_output .= "\t\t\t<LAUTER_DEADSPACE>" . $row_equip_profiles['equipMashTunDeadspace'] . "</LAUTER_DEADSPACE>\n";
        $xml_output .= "\t\t\t<TOP_UP_KETTLE>" . $row_equip_profiles['equipTopUpKettle'] . "</TOP_UP_KETTLE>\n";
        $xml_output .= "\t\t\t<TRUB_CHILLER_LOSS>" . $row_equip_profiles['equipLoss'] . "</TRUB_CHILLER_LOSS>\n";
    }
    $xml_output .= "\t\t\t<TUN_SPECIFIC_HEAT>" . $row_equip_profiles['equipMashTunSpecificHeat'] . "</TUN_SPECIFIC_HEAT>\n";
    $xml_output .= "\t\t\t<EVAP_RATE>" . $row_equip_profiles['equipEvapRate'] . "</EVAP_RATE>\n";
    $xml_output .= "\t\t\t<BOIL_TIME>" . $row_log['brewBoilTime'] . "</BOIL_TIME>\n";
    $xml_output .= "\t\t\t<HOP_UTILIZATION>" . $row_equip_profiles['equipHopUtil'] . "</HOP_UTILIZATION>\n";
    $replaced = strtr($row_equip_profiles['equipNotes'], $string);
        }
        echo " " . $row_pref['measFluid2'];
        ?>
</div>
        </div>
        <?php 
    }
    ?>
        <?php 
    if (!empty($row_equip_profiles['equipMashTunWeight'])) {
        ?>
        <div class="row">
            <div class="col-lg-6 col-md-6 col-sm-6 col-xs-6"><strong>Mash Tun Weight:</strong></div>
            <div class="col-lg-6 col-md-6 col-sm-6 col-xs-6"><?php 
        if ($row_equip_profiles['equipMashTunWeight'] != "" && $row_pref['measWeight2'] == "kilograms" && $row_equip_profiles['equipBrewerID'] == "brewblogger") {
            echo weightconvert($row_equip_profiles['equipMashTunWeight'], "kilograms");
        } else {
            echo $row_equip_profiles['equipMashTunWeight'];
        }
        echo " " . $row_pref['measWeight2'];
        ?>
</div>
        </div>
        <?php 
    }
    ?>
        <?php 
    if (!empty($row_equip_profiles['equipMashTunSpecificHeat'])) {
        ?>
        <div class="row">
            <div class="col-lg-6 col-md-6 col-sm-6 col-xs-6"><strong>Mash Tun Specific Heat:</strong></div>