update
[phpmyadmin/crack.git] / ldi_table.php3
blob1d236fc25e4339ae6c43b67ed00c0e9b35f5bf4c
1 <?php
2 /* $Id$ */
3 // vim: expandtab sw=4 ts=4 sts=4:
6 /**
7 * This file defines the forms used to insert a textfile into a table
8 */
11 /**
12 * Gets some core libraries and displays links
14 require('./tbl_properties_common.php3');
15 $err_url = 'ldi_table.php3' . $err_url;
16 $url_query .= '&amp;goto=ldi_table.php3&amp;back=ldi_table.php3';
17 require('./tbl_properties_table_info.php3');
20 /**
21 * Displays the form
24 <form action="ldi_check.php3" method="post" enctype="multipart/form-data">
25 <table cellpadding="5" border="2">
26 <tr>
27 <td><?php echo $strLocationTextfile; ?></td>
28 <td colspan="2"><input type="file" name="textfile" /></td>
29 </tr>
30 <?php
31 if ($cfg['AllowAnywhereRecoding'] && $allow_recoding) {
32 $temp_charset = reset($cfg['AvailableCharsets']);
33 echo ' <tr>' . "\n"
34 . ' <td>' . $strCharsetOfFile . '</td>' . "\n"
35 . ' <td colspan="2">' . "\n"
36 . ' <select name="charset_of_file" size="1">' . "\n"
37 . ' <option value="' . $temp_charset . '"';
38 if ($temp_charset == $charset) {
39 echo ' selected="selected"';
41 echo '>' . $temp_charset . '</option>' . "\n";
42 while ($temp_charset = next($cfg['AvailableCharsets'])) {
43 echo ' <option value="' . $temp_charset . '"';
44 if ($temp_charset == $charset) {
45 echo ' selected="selected"';
47 echo '>' . $temp_charset . '</option>' . "\n";
48 } // end while
49 echo ' </select>' . "\n";
50 echo ' </td>' . "\n";
51 echo ' </tr>';
52 } // end if
53 echo "\n";
55 <tr>
56 <td><?php echo $strReplaceTable; ?></td>
57 <td><input type="checkbox" name="replace" value="REPLACE" id="checkbox_replace" /><?php echo $strReplace; ?></td>
58 <td><label for="checkbox_replace"><?php echo $strTheContents; ?></label></td>
59 </tr>
60 <tr>
61 <td><?php echo $strFieldsTerminatedBy; ?></td>
62 <td><input type="text" name="field_terminater" size="2" maxlength="2" value=";" /></td>
63 <td><?php echo $strTheTerminator; ?></td>
64 </tr>
65 <tr>
66 <td><?php echo $strFieldsEnclosedBy; ?></td>
67 <td>
68 <input type="text" name="enclosed" size="1" maxlength="1" value="&quot;" />
69 <input type="checkbox" name="enclose_option" value="OPTIONALLY" id="checkbox_enclose_option" />
70 <label for="checkbox_enclose_option"><?php echo $strOptionally; ?></label>
71 </td>
72 <td><?php echo $strOftenQuotation; ?></td>
73 </tr>
74 <tr>
75 <td><?php echo $strFieldsEscapedBy; ?></td>
76 <td><input type="text" name="escaped" size="2" maxlength="2" value="\" /></td>
77 <td><?php echo $strOptionalControls; ?></td>
78 </tr>
79 <tr>
80 <td><?php echo $strLinesTerminatedBy; ?></td>
81 <td><input type="text" name="line_terminator" size="8" maxlength="8" value="<?php echo ((PMA_whichCrlf() == "\n") ? '\n' : '\r\n'); ?>" /></td>
82 <td><?php echo $strCarriage; ?><br /><?php echo $strLineFeed; ?></td>
83 </tr>
84 <tr>
85 <td><?php echo $strColumnNames; ?></td>
86 <td><input type="text" name="column_name" /></td>
87 <td><?php echo $strIfYouWish; ?></td>
88 </tr>
89 <?php
90 // 2002/2/22 appended by Y.Kawada: Kanji encoding convert controls
91 if (function_exists('PMA_set_enc_form')) {
92 echo ' <tr>' . "\n"
93 . ' <td>' . $strKanjiEncodConvert . '</td>' . "\n"
94 . ' <td colspan=2>' . "\n"
95 . PMA_set_enc_form(' ')
96 . ' </td>' . "\n"
97 . ' </tr>' . "\n";
98 } // end if
100 <tr>
101 <td colspan="3" align="center"><?php print PMA_showMySQLDocu('Reference', 'LOAD_DATA'); ?></td>
102 </tr>
103 <tr>
104 <td colspan="3" align="center">
105 <?php echo PMA_generate_common_hidden_inputs($db, $table); ?>
106 <input type="hidden" name="zero_rows" value="<?php echo $strTheContent; ?>" />
107 <input type="hidden" name="goto" value="tbl_properties.php3" />
108 <input type="hidden" name="back" value="ldi_table.php3" />
109 <input type="hidden" name="into_table" value="<?php echo htmlspecialchars($table); ?>" />
110 <input type="submit" name="btnLDI" value="<?php echo $strSubmit; ?>" />&nbsp;&nbsp;
111 <input type="reset" value="<?php echo $strReset; ?>" />
112 </td>
113 </tr>
114 </table>
115 </form>
118 <?php
120 * Displays the footer
122 require('./footer.inc.php3');