<div class="content_custom"  id="content_custom">
    <h3>Send new update data</h3>
    <iframe name="upload_iframe" src="" style="display:none;" onLoad="upload2();"></iframe>
    <form method="post" action="/FWUPDTAPP" name="form1" enctype="multipart/form-data" target = "upload_iframe" style="margin-bottom: 5px;">

        <table>
            <tr>
                <td><input style="padding: 0; height: 18px" id="first_file" value="(select a file)" readonly="readonly" type="text" title="Firmware- / Project file (.zip)" /></td>
                <td>
                    <div class="container" title="Choose File">
                        <div class = "doit">
                            <span class="icons folder"></span>
                        </div>
                        <input id="hid" name="file1" type="file" onchange="fill('first_file','hid');controleHid2()" />
                    </div>
                </td>

            </tr>
        </table>
    </form>

    <form method="post" action="/FWUPDTAPP" name="form2" enctype="multipart/form-data" target = "upload_iframe" style="margin-bottom: 5px;">
        <table>
            <tr>
                <td><input style="padding: 0; height: 18px" id="second_file" value="(select a file)" readonly="readonly" type="text"  title="Project file (.zip)" disabled/></td>
                <td>
                    <div class="container" title="Choose File">
                        <div class = "doit">
                            <span class="icons folder"></span>
                        </div>
                        <input name="file2" id="hid2" type="file" onchange="fill('second_file','hid2')" disabled/>
                    </div>
                </td>
            </tr>
        </table>
    </form>

    <table>
        <tr>
            <td style="width: 100px ;font-size: 12px">  <input class="manage_config_checkbox" type="checkbox" value="no_backup" id="no_backup" disabled/>No backup</td>
            <td style="width: 100px ;font-size: 12px">  <input class="manage_config_checkbox" type="checkbox" value="no_check" id="no_check" disabled/>No check</td>
        </tr>
        <tr>
            <td style="width: 100px ;font-size: 12px"><input class="manage_config_checkbox" type="checkbox" value="no_reset" id="no_reset" disabled/>No reset</td>
            <td style="width: 100px ;font-size: 12px"><input class="manage_config_checkbox" type="checkbox" value="delete_all" id="delete_all" disabled/>Delete all</td>
        </tr>
    </table>
    <input
        type="submit"
        class="btn"
        value="Send update data"
        onclick="update_prepare();"
        id="updatebutton" disabled/>
    <div style="width: 330px; height: 1px; background: black; margin-top: 15px;margin-bottom: 15px;"></div>
        <textarea id="updateStatus" readonly="readonly" style="height: 270px; position: absolute; top: 20px; left: 350px;" rows="19" cols="50"></textarea>
    <h3>Restore last update</h3>
    <div class="annotation">
        <table>
            <tr>
                <td><span style="font-size: 12px;">Restorable update data available: </span></td>
                <td style="padding-left:5px"><div id="yesno"><img src="progress.gif"/></div></td>
            </tr>
            <tr>
                <td><span style="font-size: 12px;">Backup Firmware version: </span></td>
                <td style="padding-left:5px"><div id="version"><img src="progress.gif"/></div></td>
            </tr>
            <tr>
                <td><span style="font-size: 12px;">Actual Firmware version: </span></td>
                <td style="padding-left:5px"><MWSL> write(GetVar("SINAMICS.FirmwareVersion")); </MWSL></td>
            </tr>
            <tr>
                <td><span style="font-size: 12px;">Failsafe update: </span></td>
                <td style="padding-left:5px"><MWSL> write(GetVar("SINAMICS.IsFailSafe")); </MWSL></td>
            </tr>
        </table>
    </div>
    <table>
        <tr>
            <td style="font-size: 12px"><input class="manage_config_checkbox" type="checkbox" value="no_reset_restore" id="no_reset_restore" disabled/>No reset</td>
        </tr>
    </table>
    <input onclick="restore();" type="button" name="restore" class="btn" value="Restore last update" title="" id="restorebutton" disabled/>
    <br>
    <br/>
    <div id ="upload_response"></div>
    <div id ="update_response"></div>
    <div id ="restore_response"></div>
    <div id="progress_bar"></div>
</div>
