Example #1
0
        echo $cfgMaxRows;
        ?>
" />
            <?php 
        echo $strLimitNumRows . "\n";
        ?>
            </div>
        </li>
        <li>
            <?php 
        echo $strAddSearchConditions;
        ?>
<br />
            <input type="text" name="where" />&nbsp;
            <?php 
        print show_docu("manual_Reference.html#Functions") . "\n";
        ?>
            <br /><br />
            <?php 
        echo '<i>' . $strOr . '</i> ' . $strDoAQuery;
        ?>
<br />
            <table border="<?php 
        echo $cfgBorder;
        ?>
">
            <tr>
                <th><?php 
        echo $strField;
        ?>
</th>
Example #2
0
        */
        if ($action == "tbl_create.php") {
            echo "\n\t\t\t\t<td align=\"center\" valign=\"top\">\n\t\t\t\t\t<select name=\"fk_field[]\"><option value=\"\">{$strFKFields}</select>\n\t\t\t\t</td>\n\t\t\t\t<td align=\"center\" valign=\"top\">\n\t\t\t\t\t<input type=\"checkbox\" name=\"field_primary[]\" value=\"{$i}\" {$strPriKey}>\n\t\t\t\t</td>\n\t\t\t";
        }
        echo "\n\t\t\t<td align=\"center\" valign=\"top\">\n\t\t\t\t<input type=\"checkbox\" name=\"field_index[]\" value=\"{$i}\" {$strMULKey}>\n\t\t\t</td>\n\t\t\t<td align=\"center\" valign=\"top\">\n\t\t\t\t<input type=\"checkbox\" name=\"field_unique[]\" value=\"{$i}\" {$strUNIKey}>\n\t\t\t</td>\n\t\t";
    }
    echo "</tr>";
}
?>
	<tr>
		<td colspan="5">
			<input type="submit" name="submit" value="<?php 
echo $strSave;
?>
">
			<input type="hidden" name="table" value="<?php 
echo $table;
?>
"
		</td>
	</tr>
	<tr>
		<td align="center" colspan="5">
			<?php 
print show_docu($strDocsLink);
?>
		</td>
	</tr>
</table>
</form>
Example #3
0
</td>
    </tr>
    <tr>
        <td><?php 
echo $strColumnNames;
?>
</td>
        <td><input type="text" name="column_name" /></td>
        <td><?php 
echo $strIfYouWish;
?>
</td>
    </tr>
    <tr>
        <td colspan="3" align="center"><?php 
print show_docu('manual_Reference.html#LOAD_DATA');
?>
</td>
    </tr>
    <tr>
        <td colspan="3" align="center">
            <input type="hidden" name="lang" value="<?php 
echo $lang;
?>
" />
            <input type="hidden" name="server" value="<?php 
echo $server;
?>
" />
            <input type="hidden" name="db" value="<?php 
echo $db;
Example #4
0
    echo $strTableMaintenance;
    ?>
&nbsp;:&nbsp;
        <a href="sql.php?<?php 
    echo $url_query;
    ?>
&sql_query=<?php 
    echo urlencode('OPTIMIZE TABLE ' . backquote($table));
    ?>
&display=simple">
            <?php 
    echo $strOptimizeTable;
    ?>
</a>&nbsp;
        <?php 
    echo show_docu('manual_Reference.html#OPTIMIZE_TABLE') . "\n";
    ?>
    </li>
    <?php 
    echo "\n";
}
// end MySQL < 3.23
?>

    <!-- Deletes the table -->
    <li>
        <a href="sql.php?<?php 
echo ereg_replace('tbl_properties.php$', 'db_details.php', $url_query);
?>
&back=tbl_properties.php&reload=true&sql_query=<?php 
echo urlencode('DROP TABLE ' . backquote($table));
Example #5
0
        if (!mysql_error()) {
            echo "\n";
            ?>
        <tr>
            <td valign="baseline"><img src="images/item.gif" width="7" height="7" alt="item" /></td>
            <td> 
                <a href="user_details.php?<?php 
            echo $common_url_query;
            ?>
&db=mysql&table=user">
                    <?php 
            echo $strUsers;
            ?>
</a>&nbsp;
                <?php 
            echo show_docu('manual_Privilege_system.html#Privilege_system') . "\n";
            ?>
            </td>
        </tr>
        <tr>
            <td valign="baseline"><img src="images/item.gif" width="7" height="7" alt="item" /></td>
            <td>
                <a href="db_stats.php?<?php 
            echo $common_url_query;
            ?>
">
                    <?php 
            echo $strDatabasesStats;
            ?>
</a>
            </td>
Example #6
0
</td>
			<?php 
            if (!$printview) {
                ?>
			<td><?php 
                echo "<a href=\"sql.php?{$query}&sql_query={$sql_query}&zero_rows={$zero_rows}\">{$strDrop}</a>";
                ?>
</td>
			<?php 
            }
            // end printview
            echo "</tr>";
        }
        print "</table>\n";
        if (!$printview) {
            print show_docu("indices.htm");
        }
    }
}
if (!$printview) {
    $drop_query = "server={$server}&db={$db}&goto=db_details.php&reload=true";
    ?>

<div align="left">
<ul>
<li><a href="tbl_properties.php?printview=1&<?php 
    echo $query;
    ?>
"><?php 
    echo $strPrintScreen;
    ?>
Example #7
0
&db=<?php 
    echo urlencode($db);
    ?>
&sql_query=<?php 
    echo urlencode('DROP DATABASE ' . backquote($db));
    ?>
&zero_rows=<?php 
    echo urlencode($strDatabase . ' ' . htmlspecialchars(backquote($db)) . ' ' . $strHasBeenDropped);
    ?>
&goto=main.php&back=db_details.php&reload=true">
            <?php 
    echo $strDropDB . ' ' . htmlspecialchars($db);
    ?>
</a>
        <?php 
    echo show_docu('manual_Reference.html#DROP_DATABASE') . "\n";
    ?>
    </li>
    <?php 
}
echo "\n";
?>

</ul>


<?php 
/**
 * Displays the footer
 */
echo "\n";
Example #8
0
</td>
</tr>
<tr>
	<td><?php 
echo $strColumnNames;
?>
</td>
	<td><input type="text" name="column_namer"></td>
	<td><?php 
echo $strIfYouWish;
?>
</td>
</tr>
<tr>
	<td colspan="3" align="center"><?php 
print show_docu("manual_Syntax.html#Load");
?>
</td>
</tr>
<tr>
	<td colspan="3" align="center">
	<input type="Hidden" name="server" value="<?php 
echo $server;
?>
">
	<input type="Hidden" name="db" value="<?php 
echo $db;
?>
">
	<input type="Hidden" name="table" value="<?php 
echo $table;
Example #9
0
            if ($i >= 0) {
                echo "<option value=\"{$field}\" selected>{$field}</option>\n";
            } else {
                echo "<option value=\"{$field}\">{$field}</option>\n";
            }
        }
        ?>
		</select><br>
		<div align="left">
		<ul>
		<li><?php 
        echo $strAddSearchConditions;
        ?>
<br>
		<input type="text" name="where"> <?php 
        print show_docu("sql-select.htm#SQL-WHERE");
        ?>
<br>
	
		<br>
		<li><?php 
        echo $strDoAQuery;
        ?>
<br>
		
		<?php 
        $show_defaults = false;
        $show_ops = true;
        include "tbl_form.inc.php";
        ?>
Example #10
0
    if ($aryUser[usecreatedb] == "t") {
        $strSelCreateDB = "checked";
    } else {
        unset($strSelCreateDB);
    }
    if ($aryUser[usesuper] == "t") {
        $strSelSuper = "checked";
    } else {
        unset($strSelSuper);
    }
    if ($aryUser[usecatupd] == "t") {
        $strSelCatUpd = "checked";
    } else {
        unset($strSelCatUpd);
    }
    if ($action == "edit") {
        echo "<b>{$strEdit} {$usr}</b><p>", show_docu("sql-alteruser.htm"), "<br>";
        $strUserField = "<b>{$usr}</b><input type=hidden name=usr value=\"{$usr}\">";
        $strActionVal = "ALTER";
    } else {
        echo "<b>{$strNewUser}</b><p>", show_docu("sql-createuser.htm"), "<br>";
        $strUserField = "<input type=\"text\" name=\"usr\">";
        $strActionVal = "CREATE";
    }
    if (empty($aryUser[valuntil])) {
        $aryUser[valuntil] = '2038-01-18';
    }
    echo "\n\t\t\t<table border=\"{$cfgBorder}\">\n\t\t\t<tr>\n\t\t\t\t<th>{$strUserName}</th>\n\t\t\t\t<th>{$strCreateDB}</th>\n\t\t\t\t<th>{$strSuperUser}</th>\n\t\t\t\t<!--th>{$strCatUpd}</th-->\n\t\t\t\t<th>{$strPassword}</th>\n\t\t\t\t<th>{$strExpires}</th>\n\t\t\t</tr>\n\t\t\t<form method=\"POST\">\n\t\t\t<tr bgcolor=\"{$cfgBgcolorTwo}\">\n\t\t\t\t<td align=center>{$strUserField}</td>\n\t\t\t\t<td align=center><input type=checkbox name=usecreatedb value=true {$strSelCreateDB}></td>\n\t\t\t\t<td align=center><input type=checkbox name=usesuper value=true {$strSelSuper}></td>\n\t\t\t\t<!--td align=center><input type=checkbox name=usecatupd value=true {$strSelCatUpd}></td-->\n\t\t\t\t<td align=center><input type=password name=password value=\"{$aryUser['passwd']}\"></td>\n\t\t\t\t<td align=center><input type=text name=valuntil value=\"{$aryUser['valuntil']}\"></td>\n\t\t\t</tr>\n\t\t\t<tr align=center>\n\t\t\t\t<td colspan=6>\n\t\t\t\t\t<input type=submit name=\"submit\" value=\"Save\"> &nbsp; \n\t\t\t\t\t<input type=reset value=\"Cancel\" onclick=\"history.back()\"> &nbsp; \n\t\t\t\t</td>\n\t\t\t</tr>\n\t\t\t<input type=\"hidden\" name=\"save_action\" value=\"{$strActionVal}\">\n\t\t\t</form>\n\t\t</table>\n\t\t";
}
echo "<p><a href=\"user_admin.php?server={$server}&action=new_user\">{$strNewUser}</a>";
include "footer.inc.php";
Example #11
0
function normal_operations()
{
    global $server, $lang, $self;
    global $strReloadMySQL, $strGo;
    global $strHostEmpty, $strUserEmpty, $strPasswordEmpty;
    global $strPasswordNotSame, $strAddUserMessage, $strRememberReload;
    global $strDatabase, $strHost, $strAnyHost, $strUserName;
    global $strAnyUser, $strPassword, $strNoPassword, $strReType;
    global $strPrivileges, $strAddUser, $strCheckDbPriv;
    ?>

    <script language="JavaScript">
    <!--

    function addUser(f) {
        var sql = "INSERT INTO user SET ";

        if (f.anyhost[0].checked) {
           if (f.host.value == "") {
               alert("<?php 
    echo $strHostEmpty;
    ?>
");
               return;
              }
           sql += "host = '" + f.host.value + "'";
        } else sql += "host = '%'"

        if (f.anyuser[0].checked) {
           if (f.user.value == "") {
               alert("<?php 
    echo $strUserEmpty;
    ?>
");
               return;
              }
           sql += ", user = '******'";
        } else sql += ", user = ''"

        if (f.nopass[0].checked) {
           if (f.pw.value == "") {
               alert("<?php 
    echo $strPasswordEmpty;
    ?>
");
               return;
              }

           if (f.pw.value != f.pw2.value) {
               alert("<?php 
    echo $strPasswordNotSame;
    ?>
");
               return;
              }
              sql += ", password = PASSWORD('" + f.pw.value + "')";
        }

        sql += ", " + privToString(f);
			//alert(sql);

        url  = "sql.php";
        url += "?sql_query=" + escape(sql);
        url += "&zero_rows=" + escape("<?php 
    echo "{$strAddUserMessage}<br>{$strRememberReload}";
    ?>
");
        url += "<?php 
    echo "&server={$server}&lang={$lang}&db=mysql&table=user";
    ?>
";
        url += "&goto=<?php 
    echo $self;
    ?>
";
			//alert(url);
			
        location.href = url;
    }

    //-->
    </script>

    <div align=left>
    <ul>

    <li><a href="<?php 
    echo "{$self}?server={$server}&lang={$lang}&db=mysql&table=user&mode=reload";
    ?>
"><?php 
    echo $strReloadMySQL;
    ?>
</a> <?php 
    print show_docu("manual_Reference.html#FLUSH");
    ?>
</li>

    <li><form name=userForm1 method="POST" action="<?php 
    echo $self;
    ?>
"><?php 
    echo $strCheckDbPriv;
    ?>
    <table width="100%"><tr>
    <td><?php 
    echo $strDatabase;
    ?>
:&nbsp;<select name="db">
<?php 
    $result = mysql_query("SHOW DATABASES");
    if (@mysql_num_rows($result)) {
        while ($row = mysql_fetch_row($result)) {
            echo "<option>" . $row[0] . "</option>\n";
        }
    }
    ?>
    </select></td>
    </tr></table>
    <input type="hidden" name="server" value="<?php 
    echo $server;
    ?>
">
    <input type="hidden" name="lang" value="<?php 
    echo $lang;
    ?>
">
    <input type="hidden" name="check" value="1">
    <input type="submit" value="<?php 
    echo $strGo;
    ?>
">
    </form>
    </li>

    <li><form name=userForm2 onsubmit ="return false"><?php 
    echo $strAddUser;
    ?>
    <table>
    <tr>
    <td><input type="radio" name="anyhost">
    <?php 
    echo $strHost;
    ?>
: <input type="text" name="host" size=10 onchange="anyhost[0].checked = true"></td>
    <td>&nbsp;</td><td><input type="radio" name="anyhost" checked><?php 
    echo $strAnyHost;
    ?>
</td>
    </tr>
    </table>
    <table>
    <tr>
    <td><input type="radio" name="anyuser" checked>
    <?php 
    echo $strUserName;
    ?>
: <input type="text" name="user" size=10 onchange="anyuser[0].checked = true"></td>
    <td>&nbsp;</td><td><input type="radio" name="anyuser"><?php 
    echo $strAnyUser;
    ?>
</td>
    </tr>
    </table>
    <table>
    <tr>
    <td><input type="radio" name="nopass" checked>
    <?php 
    echo $strPassword;
    ?>
: <input type="password" name="pw" size=10 onchange="nopass[0].checked = true"></td>
    <td><?php 
    echo $strReType;
    ?>
: <input type="password" name="pw2" size=10 onchange="nopass[0].checked = true"></td>
    <td>&nbsp;</td>
    <td><input type="radio" name="nopass"><?php 
    echo $strNoPassword;
    ?>
</td></tr>
    <tr><td><br><?php 
    echo $strPrivileges;
    ?>
:<br></td></tr>
    </table>
    <?php 
    table_privileges("userForm2");
    ?>
    <input type="button" value="<?php 
    echo $strGo;
    ?>
" onclick="addUser(document.userForm2)"></p>
    </form>
    </li>
    </ul>
    </div>
    <?php 
}
Example #12
0
<form method="post" action="db_readdump.php">
<input type="hidden" name="server" value="<?php 
    echo $server;
    ?>
">
<input type="hidden" name="db" value="<?php 
    echo $db;
    ?>
">
<input type="hidden" name="goto" value="db_details.php">
<input type="hidden" name="zero_rows" value="<?php 
    echo $strSuccess;
    ?>
">
<?php 
    echo $strRunSQLQuery . $db . " " . show_docu("sql-select.html");
    ?>
:<br/><a name="sql_box"></a>
<textarea name="sql_query" cols="60" rows="6" wrap="VIRTUAL" style="width: <?php 
    echo $cfgMaxTextAreaSize;
    ?>
"><?php 
    echo stripslashes($sql_query);
    ?>
</textarea>
<input type="submit" name="SQL" value="<?php 
    echo $strGo;
    ?>
">
</form>
<form method="POST" action="file_sql.php" enctype="multipart/form-data">
Example #13
0
    </table>
    <br />
    <?php 
}
echo "\n";
// END - Table Type - 2 May 2001 - Robbat2
?>

<input type="submit" name="submit" value="<?php 
echo $strSave;
?>
" />
</form>

<table>
<tr>
    <td valign="top">*&nbsp;</td>
    <td>
        <?php 
echo $strSetEnumVal . "\n";
?>
    </td>
</tr>
</table>
<br />

<center><?php 
echo show_docu('manual_Reference.html#CREATE_TABLE');
?>
</center>