Esempio n. 1
0
    /**
     * @dataProvider dataProvider
     * @return void
     */
    function testBrowseUploadFile($size, $unit, $res){

        $this->expectOutputString('<label for="radio_import_file">' . __("Browse your computer:") . '</label>'
                                  . '<div id="upload_form_status" style="display: none;"></div>'
                                  . '<div id="upload_form_status_info" style="display: none;"></div>'
                                  . '<input type="file" name="import_file" id="input_import_file" />'
                                  . "(" . __('Max: '). $res . $unit .")" . "\n"
                                  . '<input type="hidden" name="MAX_FILE_SIZE" value="' .$size . '" />' . "\n");

        PMA_browseUploadFile($size);
    }
Esempio n. 2
0
                <?php 
    PMA_browseUploadFile($max_upload_size);
    ?>
            </li>
            <li>
                <input type="radio" name="file_location" id="radio_local_import_file" />
                <?php 
    PMA_selectUploadFile($import_list, $cfg['UploadDir']);
    ?>
            </li>
            </ul>
        <?php 
} else {
    if ($GLOBALS['is_upload']) {
        $uid = uniqid("");
        PMA_browseUploadFile($max_upload_size);
    } else {
        if (!$GLOBALS['is_upload']) {
            PMA_Message::notice(__('File uploads are not allowed on this server.'))->display();
        } else {
            if (!empty($cfg['UploadDir'])) {
                PMA_selectUploadFile($import_list, $cfg['UploadDir']);
            }
        }
    }
}
// end if (web-server upload directory)
?>
        </div>

       <div class="formelementrow" id="charaset_of_file">