Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Comparing changes

Choose two branches to see what's changed or to start a new pull request. If you need to, you can also compare across forks.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also compare across forks.
...
Checking mergeability… Don't worry, you can still create the pull request.
  • 5 commits
  • 34 files changed
  • 0 commit comments
  • 1 contributor
Commits on Jun 09, 2011
@leonardosapiras Fixed problem with encoding 32159a4
@leonardosapiras Removed useless condition cc7497b
@leonardosapiras Fixed problem in toplink bf085b8
@leonardosapiras Navigation links
-Created method printNavLink.
-Refatored tables.php.
bca3351
@leonardosapiras Navigation links - refactor 2
Files:
-schemas.php
-domains.php
-tables.php
-tablespaces.php
-operators.php
-sequences.php
-privileges.php
-history.php
-display.php
-colproperties.php
-rules.php
-types.php
-roles.php
-groups.php
-users.php
-reports.php
-aggregates.php
-functions.php
-views.php
-all_db.php
-triggers.php
-constraints.php
-indexes.php
-viewproperties.php
-fulltext.php
-servers.php
-tblproperties.php
-sql.php
c619921
View
32 aggregates.php
@@ -245,13 +245,25 @@ function doProperties($msg = '') {
}
else echo "<p>{$lang['strnodata']}</p>\n";
- echo "<ul class=\"navlink\">\n\t<li><a class=\"navlink\" href=\"aggregates.php?{$misc->href}\">{$lang['straggrshowall']}</a></li>\n";
+ $navlinks = array (
+ array (
+ 'attr'=> array ('href' => "aggregates.php?{$misc->href}"),
+ 'content' => $lang['straggrshowall']
+ )
+ );
+
if ($data->hasAlterAggregate()) {
- echo "\t<li><a class=\"navlink\" href=\"aggregates.php?action=alter&amp;{$misc->href}&amp;aggrname=",
- urlencode($_REQUEST['aggrname']), "&amp;aggrtype=", urlencode($_REQUEST['aggrtype']), "\">{$lang['stralter']}</a></li>\n";
+ $navlinks[] = array (
+ 'attr'=> array ('href' => "aggregates.php?action=alter&amp;{$misc->href}&amp;aggrname=".urlencode($_REQUEST['aggrname'])."&amp;aggrtype=".urlencode($_REQUEST['aggrtype'])),
+ 'content' => $lang['stralter']
+ );
}
- echo "\t<li><a class=\"navlink\" href=\"aggregates.php?action=confirm_drop&amp;{$misc->href}&amp;aggrname=",
- urlencode($_REQUEST['aggrname']), "&amp;aggrtype=", urlencode($_REQUEST['aggrtype']), "\">{$lang['strdrop']}</a></li>\n</ul>\n";
+ $navlinks[] = array (
+ 'attr'=> array ('href' => "aggregates.php?action=confirm_drop&amp;{$misc->href}&amp;aggrname=".urlencode($_REQUEST['aggrname'])."&amp;aggrtype=".urlencode($_REQUEST['aggrtype'])),
+ 'content' => $lang['strdrop']
+ );
+
+ $misc->printNavLinks($navlinks);
}
@@ -311,8 +323,14 @@ function doDefault($msg = '') {
if (!$data->hasAlterAggregate()) unset($actions['alter']);
$misc->printTable($aggregates, $columns, $actions, $lang['strnoaggregates']);
-
- echo "<p><a class=\"navlink\" href=\"aggregates.php?action=create&amp;{$misc->href}\">{$lang['strcreateaggregate']}</a></p>\n";
+
+ $navlinks = array (
+ array (
+ 'attr'=> array ('href' => "aggregates.php?action=create&amp;{$misc->href}"),
+ 'content' => $lang['strcreateaggregate']
+ )
+ );
+ $misc->printNavLinks($navlinks);
}
/**
View
8 all_db.php
@@ -427,7 +427,13 @@ function doDefault($msg = '') {
$misc->printTable($databases, $columns, $actions, $lang['strnodatabases']);
- echo "<p><a class=\"navlink\" href=\"all_db.php?action=create&amp;{$misc->href}\">{$lang['strcreatedatabase']}</a></p>\n";
+ $navlinks = array (
+ array (
+ 'attr'=> array ('href' => "all_db.php?action=create&amp;{$misc->href}"),
+ 'content' => $lang['strcreatedatabase']
+ )
+ );
+ $misc->printNavLinks($navlinks);
}
View
34 classes/Misc.php
@@ -1098,7 +1098,7 @@ function printTopbar() {
$tag.= " ".$attr."=\"".htmlentities($value)."\"";
}
$tag.=">";
- $tag.= htmlentities($link['content']);
+ $tag.= $link['content'];
$tag.="</a></li>\n";
echo $tag;
@@ -1183,6 +1183,36 @@ function getTopLinks() {
}
/**
+ * Display the navlinks
+ *
+ * @param $navlinks - An array with the the attributes and values that will be shown.
+ *
+ * $navlinks = array (
+ * array (
+ * 'attr'=> array ('href' => 'test.php', 'class' => 'green'),
+ * 'content' => 'Test'
+ * ), array (
+ * 'attr'=> array ('href' => 'anotherlink.php')
+ * 'content' => 'Another Link'
+ * )
+ * );
+ */
+ function printNavLinks($navlinks=array()) {
+ if (count($navlinks) > 0) {
+ echo "<ul class=\"navlink\">\n";
+ foreach ($navlinks as $navlink) {
+ $tag = "\t<li><a ";
+ foreach ($navlink['attr'] as $attr => $value) {
+ $tag.= "{$attr}=\"{$value}\"";
+ }
+ $tag.= ">".$navlink['content']."</a></li>\n";
+ echo $tag;
+ }
+ echo "</ul>\n";
+ }
+ }
+
+ /**
* Display a bread crumb trail.
*/
function printTrail($trail = array()) {
@@ -1216,7 +1246,7 @@ function printTrail($trail = array()) {
if (isset($crumb['icon']) && $icon = $this->icon($crumb['icon']))
$crumblink .= "<span class=\"icon\"><img src=\"{$icon}\" alt=\"{$iconalt}\" /></span>";
- $crumblink .= "<span class=\"label\">" . htmlspecialchars($crumb['text']) . "</span></a>";
+ $crumblink .= "<span class=\"label\">" . $crumb['text'] . "</span></a>";
if (isset($crumb['help']))
$this->printHelp($crumblink, $crumb['help']);
View
47 colproperties.php
@@ -230,7 +230,6 @@ function attPre(&$rowdata) {
echo "<br />\n";
- echo "<ul class=\"navlink\">\n";
$f_attname = $_REQUEST['column'];
$f_table = $tableName;
$f_schema = $data->_schema;
@@ -246,28 +245,42 @@ function attPre(&$rowdata) {
/* Browse link */
/* FIXME browsing a col should somehow be a action so we don't
* send an ugly SQL in the URL */
- echo "\t<li><a href=\"display.php?{$misc->href}&amp;subject=column&amp;table=",
- urlencode($_REQUEST['table']),
- "&amp;column=", urlencode($_REQUEST['column']),
- "&amp;return_url={$return_url}&amp;return_desc=", urlencode($lang['strback']),
- "&amp;query={$query_url}\">{$lang['strbrowse']}</a></li>\n";
+ $url = "display.php?{$misc->href}&amp;subject=column&amp;table=";
+ $url.= urlencode($_REQUEST['table']);
+ $url.= "&amp;column=". urlencode($_REQUEST['column']);
+ $url.= "&amp;return_url={$return_url}&amp;return_desc=". urlencode($lang['strback']);
+ $url.= "&amp;query={$query_url}";
+ $navlinks = array (
+ array (
+ 'attr'=> array ('href' => $url),
+ 'content' => $lang['strbrowse']
+ ), array (
+ 'attr'=> array ('href' => "colproperties.php?action=properties&amp;{$misc->href}&amp;table=".urlencode($tableName)."&amp;column=".urlencode($_REQUEST['column'])),
+ 'content' => $lang['stralter']
+ ), array (
+ 'attr'=> array ('href' => "tblproperties.php?action=confirm_drop&amp;{$misc->href}&amp;table=".urlencode($tableName)."&amp;column=".urlencode($_REQUEST['column'])),
+ 'content' => $lang['strdrop']
+ )
+ );
- /* Edit link */
- echo "\t<li><a href=\"colproperties.php?action=properties&amp;{$misc->href}&amp;table=", urlencode($tableName),
- "&amp;column=", urlencode($_REQUEST['column']) . "\">{$lang['stralter']}</a></li>\n";
-
- echo "\t<li><a href=\"tblproperties.php?action=confirm_drop&amp;{$misc->href}&amp;table=", urlencode($tableName),
- "&amp;column=" . urlencode($_REQUEST['column']) . "\">{$lang['strdrop']}</a></li>\n";
} else {
$return_url = urlencode("colproperties.php?{$misc->href}&amp;view=". urlencode($tableName)
."&amp;column=". urlencode($_REQUEST['column']));
+ $url = "\t<li><a href=\"display.php?{$misc->href}&amp;subject=column&amp;column=";
+ $url.= urlencode($_REQUEST['column']). "&amp;return_url={$return_url}&amp;return_desc=". urlencode($lang['strback']);
+ $url.= "&amp;query={$query_url}";
/* Browse link */
- echo "\t<li><a href=\"display.php?{$misc->href}&amp;subject=column&amp;column=",
- urlencode($_REQUEST['column']), "&amp;return_url={$return_url}&amp;return_desc=", urlencode($lang['strback']),
- "&amp;query={$query_url}\">{$lang['strbrowse']}</a></li>\n";
- }
+ $navlinks = array (
+ array (
+ 'attr'=> array ('href' => $url),
+ 'content' => $lang['strbrowse']
+ )
+ );
- echo "</ul>\n";
+ }
+ $misc->printNavLinks($navlinks);
+
+
}
}
View
24 constraints.php
@@ -472,14 +472,22 @@ function cnPre(&$rowdata) {
$misc->printTable($constraints, $columns, $actions, $lang['strnoconstraints'], 'cnPre');
- echo "<ul class=\"navlink\">\n\t<li><a href=\"constraints.php?action=add_check&amp;{$misc->href}&amp;table=", urlencode($_REQUEST['table']),
- "\">{$lang['straddcheck']}</a></li>\n";
- echo "\t<li><a href=\"constraints.php?action=add_unique_key&amp;{$misc->href}&amp;table=", urlencode($_REQUEST['table']),
- "\">{$lang['stradduniq']}</a></li>\n";
- echo "\t<li><a href=\"constraints.php?action=add_primary_key&amp;{$misc->href}&amp;table=", urlencode($_REQUEST['table']),
- "\">{$lang['straddpk']}</a></li>\n";
- echo "\t<li><a href=\"constraints.php?action=add_foreign_key&amp;{$misc->href}&amp;table=", urlencode($_REQUEST['table']),
- "\">{$lang['straddfk']}</a></li>\n</ul>\n";
+ $navlinks = array (
+ array (
+ 'attr'=> array ('href' => "constraints.php?action=add_check&amp;{$misc->href}&amp;table=".urlencode($_REQUEST['table'])),
+ 'content' => $lang['straddcheck']
+ ), array (
+ 'attr'=> array ('href' => "constraints.php?action=add_unique_key&amp;{$misc->href}&amp;table=".urlencode($_REQUEST['table'])),
+ 'content' => $lang['stradduniq']
+ ), array (
+ 'attr'=> array ('href' => "constraints.php?action=add_primary_key&amp;{$misc->href}&amp;table=".urlencode($_REQUEST['table'])),
+ 'content' => $lang['straddpk']
+ ), array (
+ 'attr'=> array ('href' => "constraints.php?action=add_foreign_key&amp;{$misc->href}&amp;table=".urlencode($_REQUEST['table'])),
+ 'content' => $lang['straddfk']
+ )
+ );
+ $misc->printNavLinks($navlinks);
}
function doTree() {
View
88 display.php
@@ -567,53 +567,83 @@ function doBrowse($msg = '') {
}
else echo "<p>{$lang['strnodata']}</p>\n";
- // Navigation links
- echo "<ul class=\"navlink\">\n";
+ // Navigation links
+ $navlinks = array();
// Return
- if (isset($_REQUEST['return_url']) && isset($_REQUEST['return_desc']))
- echo "\t<li><a href=\"{$_REQUEST['return_url']}\">{$_REQUEST['return_desc']}</a></li>\n";
+ if (isset($_REQUEST['return_url']) && isset($_REQUEST['return_desc'])) {
+ $navlinks[] = array (
+ 'attr'=> array ('href' => $_REQUEST['return_url']),
+ 'content' => $_REQUEST['return_desc']
+ );
+ }
// Edit SQL link
- if (isset($_REQUEST['query']))
- echo "\t<li><a href=\"database.php?{$misc->href}&amp;action=sql&amp;paginate=on&amp;query=",
- urlencode($_REQUEST['query']), "\">{$lang['streditsql']}</a></li>\n";
+ if (isset($_REQUEST['query'])) {
+ $navlinks[] = array (
+ 'attr'=> array ('href' => "database.php?{$misc->href}&amp;action=sql&amp;paginate=on&amp;query=".urlencode($_REQUEST['query'])),
+ 'content' => $lang['streditsql']
+ );
+ }
// Expand/Collapse
- if ($_REQUEST['strings'] == 'expanded')
- echo "\t<li><a href=\"display.php?{$gets}&amp;{$getsort}&amp;strings=collapsed&amp;page=",
- urlencode($_REQUEST['page']), "\">{$lang['strcollapse']}</a></li>\n";
- else
- echo "\t<li><a href=\"display.php?{$gets}&amp;{$getsort}&amp;strings=expanded&amp;page=",
- urlencode($_REQUEST['page']), "\">{$lang['strexpand']}</a></li>\n";
+ if ($_REQUEST['strings'] == 'expanded') {
+ $navlinks[] = array (
+ 'attr'=> array ('href' => "display.php?{$gets}&amp;{$getsort}&amp;strings=collapsed&amp;page=".urlencode($_REQUEST['page'])),
+ 'content' => $lang['strcollapse']
+ );
+ } else {
+ $navlinks[] = array (
+ 'attr'=> array ('href' => "display.php?{$gets}&amp;{$getsort}&amp;strings=expanded&amp;page=".urlencode($_REQUEST['page'])),
+ 'content' => $lang['strexpand']
+ );
+ }
// Create report
- if (isset($_REQUEST['query']) && ($subject !== 'report') && $conf['show_reports'] && isset($rs) && is_object($rs) && $rs->recordCount() > 0)
- echo "\t<li><a href=\"reports.php?{$misc->href}&amp;action=create&amp;report_sql=",
- urlencode($_REQUEST['query']), "&amp;paginate=", (isset($_REQUEST['paginate'])? urlencode($_REQUEST['paginate']):'f'), "\">{$lang['strcreatereport']}</a></li>\n";
+ if (isset($_REQUEST['query']) && ($subject !== 'report') && $conf['show_reports'] && isset($rs) && is_object($rs) && $rs->recordCount() > 0) {
+ $navlinks[] = array (
+ 'attr'=> array ('href' => "reports.php?{$misc->href}&amp;action=create&amp;report_sql=".urlencode($_REQUEST['query'])."&amp;paginate=", (isset($_REQUEST['paginate'])? urlencode($_REQUEST['paginate']):'f')),
+ 'content' => $lang['strcreatereport']
+ );
+ }
// Create view and download
if (isset($_REQUEST['query']) && isset($rs) && is_object($rs) && $rs->recordCount() > 0) {
// Report views don't set a schema, so we need to disable create view in that case
- if (isset($_REQUEST['schema']))
- echo "\t<li><a href=\"views.php?action=create&amp;formDefinition=",
- urlencode($_REQUEST['query']), "&amp;{$misc->href}\">{$lang['strcreateview']}</a></li>\n";
- echo "\t<li><a href=\"dataexport.php?query=", urlencode($_REQUEST['query']);
+ if (isset($_REQUEST['schema'])) {
+ $navlinks[] = array (
+ 'attr'=> array ('href' => "views.php?action=create&amp;formDefinition=".urlencode($_REQUEST['query'])."&amp;{$misc->href}"),
+ 'content' => $lang['strcreateview']
+ );
+ }
+
+ $url = "dataexport.php?query=".urlencode($_REQUEST['query']);
if (isset($_REQUEST['search_path']))
- echo "&amp;search_path=", urlencode($_REQUEST['search_path']);
- echo "&amp;{$misc->href}\">{$lang['strdownload']}</a></li>\n";
+ $url .= "&amp;search_path=".urlencode($_REQUEST['search_path']);
+
+ $url .= "&amp;{$misc->href}";
+ $content = $lang['strdownload'];
+ $navlinks[] = array (
+ 'attr'=> array ('href' => $url),
+ 'content' => $content
+ );
}
// Insert
- if (isset($object) && (isset($subject) && $subject == 'table'))
- echo "\t<li><a href=\"tables.php?action=confinsertrow&amp;table=",
- urlencode($object), "&amp;{$misc->href}\">{$lang['strinsert']}</a></li>\n";
+ if (isset($object) && (isset($subject) && $subject == 'table')) {
+ $navlinks[] = array (
+ 'attr'=> array ('href' => "tables.php?action=confinsertrow&amp;table=".urlencode($object)."&amp;{$misc->href}"),
+ 'content' => $lang['strinsert']
+ );
+ }
// Refresh
- echo "\t<li><a href=\"display.php?{$gets}&amp;{$getsort}&amp;strings=", urlencode($_REQUEST['strings']),
- "&amp;page=" . urlencode($_REQUEST['page']),
- "\">{$lang['strrefresh']}</a></li>\n";
- echo "</ul>\n";
+ $navlinks[] = array (
+ 'attr'=> array ('href' => "display.php?{$gets}&amp;{$getsort}&amp;strings=".urlencode($_REQUEST['strings'])."&amp;page=" . urlencode($_REQUEST['page'])),
+ 'content' => $lang['strrefresh']
+ );
+
+ $misc->printNavLinks($navlinks);
}
View
23 domains.php
@@ -228,14 +228,25 @@ function doProperties($msg = '') {
}
else echo "<p>{$lang['strnodata']}</p>\n";
- echo "<ul class=\"navlink\">\n\t<li><a href=\"domains.php?action=confirm_drop&amp;{$misc->href}&amp;domain=", urlencode($_REQUEST['domain']),"\">{$lang['strdrop']}</a></li>\n";
+ $navlinks = array (
+ array (
+ 'attr'=> array ('href' => "domains.php?action=confirm_drop&amp;{$misc->href}&amp;domain=".urlencode($_REQUEST['domain'])),
+ 'content' => $lang['strdrop']
+ )
+ );
+
if ($data->hasAlterDomains()) {
- echo "\t<li><a href=\"domains.php?action=add_check&amp;{$misc->href}&amp;domain=", urlencode($_REQUEST['domain']),
- "\">{$lang['straddcheck']}</a></li>\n";
- echo "\t<li><a href=\"domains.php?action=alter&amp;{$misc->href}&amp;domain=",
- urlencode($_REQUEST['domain']), "\">{$lang['stralter']}</a></li>\n";
+ $navlinks[] = array (
+ 'attr'=> array ('href' => "domains.php?action=add_check&amp;{$misc->href}&amp;domain=".urlencode($_REQUEST['domain'])),
+ 'content' => $lang['straddcheck']
+ );
+
+ $navlinks[] = array (
+ 'attr'=> array ('href' => "domains.php?action=alter&amp;{$misc->href}&amp;domain=".urlencode($_REQUEST['domain'])),
+ 'content' => $lang['stralter']
+ );
}
- echo "</ul>\n";
+ $misc->printNavLinks($navlinks);
}
/**
View
42 fulltext.php
@@ -58,10 +58,13 @@ function doDefault($msg = '') {
$misc->printTable($cfgs, $columns, $actions, $lang['strftsnoconfigs']);
-
- echo "<ul class=\"navlink\">\n";
- echo "\t<li><a href=\"fulltext.php?action=createconfig&amp;{$misc->href}\">{$lang['strftscreateconfig']}</a></li>\n";
- echo "</ul>\n";
+ $navlinks = array (
+ array (
+ 'attr'=> array ('href' => "fulltext.php?action=createconfig&amp;{$misc->href}"),
+ 'content' => $lang['strftscreateconfig']
+ )
+ );
+ $misc->printNavLinks($navlinks);
}
function doDropConfig($confirm) {
@@ -345,9 +348,13 @@ function doViewParsers($msg = '') {
$misc->printTable($parsers, $columns, $actions, $lang['strftsnoparsers']);
//TODO: create parser
- //echo "<ul class=\"navlink\">\n";
- //echo "\t<li><a href=\"#\">{$lang['strftscreateparser']}</a></li>\n";
- //echo "</ul>\n";
+ //$navlinks = array (
+ // array (
+ // 'attr'=> array ('href' => "#"),
+ // 'content' => $lang['strftscreateparser']
+ // )
+ //);
+ //$misc->printNavLinks($navlinks);
}
@@ -398,9 +405,13 @@ function doViewDicts($msg = '') {
$misc->printTable($dicts, $columns, $actions, $lang['strftsnodicts']);
- echo "<ul class=\"navlink\">\n";
- echo "\t<li><a href=\"fulltext.php?action=createdict&amp;{$misc->href}&amp;\">{$lang['strftscreatedict']}</a></li>\n";
- echo "</ul>\n";
+ $navlinks = array (
+ array (
+ 'attr'=> array ('href' => "fulltext.php?action=createdict&amp;{$misc->href}"),
+ 'content' => $lang['strftscreatedict']
+ )
+ );
+ $misc->printNavLinks($navlinks);
}
@@ -461,10 +472,13 @@ function doViewConfig($ftscfg, $msg = '') {
$misc->printTable($map, $columns, $actions, $lang['strftsemptymap']);
- echo "<ul class=\"navlink\">\n";
- echo "\t<li><a href=\"fulltext.php?action=addmapping&amp;{$misc->href}&ftscfg={$ftscfg}\">{$lang['strftsaddmapping']}</a></li>\n";
- echo "</ul>\n";
-
+ $navlinks = array (
+ array (
+ 'attr'=> array ('href' => "fulltext.php?action=addmapping&amp;{$misc->href}&ftscfg={$ftscfg}"),
+ 'content' => $lang['strftsaddmapping']
+ )
+ );
+ $misc->printNavLinks($navlinks);
}
/**
View
34 functions.php
@@ -326,11 +326,19 @@ function doProperties($msg = '') {
}
else echo "<p>{$lang['strnodata']}</p>\n";
- echo "<ul class=\"navlink\">\n\t<li><a href=\"functions.php?{$misc->href}\">{$lang['strshowallfunctions']}</a></li>\n";
- echo "\t<li><a href=\"functions.php?action=edit&amp;{$misc->href}&amp;function=",
- urlencode($_REQUEST['function']), "&amp;function_oid=", urlencode($_REQUEST['function_oid']), "\">{$lang['stralter']}</a></li>\n";
- echo "\t<li><a href=\"functions.php?action=confirm_drop&amp;{$misc->href}&amp;function=",
- urlencode($func_full), "&amp;function_oid=", $_REQUEST['function_oid'], "\">{$lang['strdrop']}</a></li>\n</ul>";
+ $navlinks = array (
+ array (
+ 'attr'=> array ('href' => "functions.php?{$misc->href}"),
+ 'content' => $lang['strshowallfunctions']
+ ), array (
+ 'attr'=> array ('href' => "functions.php?action=edit&amp;{$misc->href}&amp;function=".urlencode($_REQUEST['function'])."&amp;function_oid=".urlencode($_REQUEST['function_oid'])),
+ 'content' => $lang['stralter']
+ ), array (
+ 'attr'=> array ('href' => "functions.php?action=confirm_drop&amp;{$misc->href}&amp;function=".urlencode($func_full)."&amp;function_oid=".$_REQUEST['function_oid']),
+ 'content' => $lang['strdrop']
+ )
+ );
+ $misc->printNavLinks($navlinks);
}
/**
@@ -825,9 +833,19 @@ function doDefault($msg = '') {
$misc->printTable($funcs, $columns, $actions, $lang['strnofunctions']);
- echo "<ul class=\"navlink\">\n\t<li><a href=\"functions.php?action=create&amp;{$misc->href}\">{$lang['strcreateplfunction']}</a></li>\n";
- echo "\t<li><a href=\"functions.php?action=create&amp;language=internal&amp;{$misc->href}\">{$lang['strcreateinternalfunction']}</a></li>\n";
- echo "\t<li><a href=\"functions.php?action=create&amp;language=C&amp;{$misc->href}\">{$lang['strcreatecfunction']}</a></li>\n</ul>\n";
+ $navlinks = array (
+ array (
+ 'attr'=> array ('href' => "functions.php?action=create&amp;{$misc->href}"),
+ 'content' => $lang['strcreateplfunction']
+ ), array (
+ 'attr'=> array ('href' => "functions.php?action=create&amp;language=internal&amp;{$misc->href}"),
+ 'content' => $lang['strcreateinternalfunction']
+ ), array (
+ 'attr'=> array ('href' => "functions.php?action=create&amp;language=C&amp;{$misc->href}"),
+ 'content' => $lang['strcreatecfunction']
+ )
+ );
+ $misc->printNavLinks($navlinks);
}
/**
View
20 groups.php
@@ -104,8 +104,14 @@ function doProperties($msg = '') {
echo "<input type=\"hidden\" name=\"group\" value=\"", htmlspecialchars($_REQUEST['group']), "\" />\n";
echo "<input type=\"hidden\" name=\"action\" value=\"add_member\" />\n";
echo "</form>\n";
-
- echo "<p><a class=\"navlink\" href=\"groups.php?{$misc->href}\">{$lang['strshowallgroups']}</a></p>\n";
+
+ $navlinks = array (
+ array (
+ 'attr'=> array ('href' => "groups.php?{$misc->href}"),
+ 'content' => $lang['strshowallgroups']
+ )
+ );
+ $misc->printNavLinks($navlinks);
}
/**
@@ -236,8 +242,14 @@ function doDefault($msg = '') {
);
$misc->printTable($groups, $columns, $actions, $lang['strnogroups']);
-
- echo "<p><a class=\"navlink\" href=\"groups.php?action=create&amp;{$misc->href}\">{$lang['strcreategroup']}</a></p>\n";
+
+ $navlinks = array (
+ array (
+ 'attr'=> array ('href' => "groups.php?action=create&amp;{$misc->href}"),
+ 'content' => $lang['strcreategroup']
+ )
+ );
+ $misc->printNavLinks($navlinks);
}
View
19 history.php
@@ -68,12 +68,23 @@ function doDefault() {
}
else echo "<p>{$lang['strnohistory']}</p>\n";
- echo "<ul class=\"navlink\">\n";
+ $navlinks = array();
if (isset($_SESSION['history'][$_REQUEST['server']][$_REQUEST['database']])
&& count($_SESSION['history'][$_REQUEST['server']][$_REQUEST['database']]))
- echo "\t<li><a href=\"history.php?action=confclearhistory&amp;{$misc->href}\">{$lang['strclearhistory']}</a></li>\n";
- echo "\t<li><a href=\"history.php?action=history&amp;{$misc->href}\">{$lang['strrefresh']}</a></li>\n";
- echo "\t<li><a href=\"history.php?action=download&amp;{$misc->href}\">{$lang['strdownload']}</a></li>\n</ul>\n";
+ $navlinks[] = array (
+ 'attr'=> array ('href' => "history.php?action=confclearhistory&amp;{$misc->href}"),
+ 'content' => $lang['strclearhistory']
+ );
+
+ $navlinks[] = array (
+ 'attr'=> array ('href' => "history.php?action=history&amp;{$misc->href}"),
+ 'content' => $lang['strrefresh']
+ );
+ $navlinks[] = array (
+ 'attr'=> array ('href' => "history.php?action=download&amp;{$misc->href}"),
+ 'content' => $lang['strdownload']
+ );
+ $misc->printNavLinks($navlinks);
}
function doDelHistory($qid, $confirm) {
View
11 indexes.php
@@ -310,9 +310,14 @@ function indPre(&$rowdata, $actions) {
);
$misc->printTable($indexes, $columns, $actions, $lang['strnoindexes'], 'indPre');
-
- echo "<p><a class=\"navlink\" href=\"indexes.php?action=create_index&amp;{$misc->href}&amp;table=",
- urlencode($_REQUEST['table']), "\">{$lang['strcreateindex']}</a></p>\n";
+
+ $navlinks = array (
+ array (
+ 'attr'=> array ('href' => "indexes.php?action=create_index&amp;{$misc->href}&amp;table=".urlencode($_REQUEST['table'])),
+ 'content' => $lang['strcreateindex']
+ )
+ );
+ $misc->printNavLinks($navlinks);
}
function doTree() {
View
8 operators.php
@@ -64,7 +64,13 @@ function doProperties($msg = '') {
}
echo "</table>\n";
- echo "<p><a class=\"navlink\" href=\"operators.php?{$misc->href}\">{$lang['strshowalloperators']}</a></p>\n";
+ $navlinks = array (
+ array (
+ 'attr'=> array ('href' => "operators.php?{$misc->href}"),
+ 'content' => $lang['strshowalloperators']
+ )
+ );
+ $misc->printNavLinks($navlinks);
}
else
doDefault($lang['strinvalidparam']);
View
7 plugins/Example/lang/english.php
@@ -5,6 +5,13 @@
* for new translations.
*/
+ // Language and character set
+ $lang['applang'] = 'English';
+ $lang['appcharset'] = 'ISO-8859-1';
+ $lang['applocale'] = 'en_US';
+ $lang['appdbencoding'] = 'LATIN1';
+ $lang['applangdir'] = 'ltr';
+
//Plugin data
$plugin_lang['strdescription'] = 'Plugin Example';
View
19 plugins/Example/lang/portuguese-br.php
@@ -5,18 +5,25 @@
* for new translations.
*/
+ // Language and character set
+ $lang['applang'] = 'Português-Brasileiro';
+ $lang['appcharset'] = 'ISO-8859-1';
+ $lang['applocale'] = 'pt_BR';
+ $lang['appdbencoding'] = 'LATIN1';
+ $lang['applangdir'] = 'ltr';
+
//Dados do plugin
$plugin_lang['strdescription'] = 'Plugin Exemplo';
//Links
$plugin_lang['strlinktoplevel'] = 'Exemplo';
- $plugin_lang['strlinklevel2'] = 'Nível 2';
- $plugin_lang['strlinklevel3'] = 'Nível 3';
- $plugin_lang['strlinklevel4'] = 'Nível 4';
+ $plugin_lang['strlinklevel2'] = 'Nível 2';
+ $plugin_lang['strlinklevel3'] = 'Nível 3';
+ $plugin_lang['strlinklevel4'] = 'Nível 4';
//Paginas
- $plugin_lang['strdesclevel2'] = 'Este é o nível 2';
- $plugin_lang['strdesclevel3'] = 'Este é o nível 3';
- $plugin_lang['strdesclevel4'] = 'Este é o nível 4';
+ $plugin_lang['strdesclevel2'] = 'Este é o nível 2';
+ $plugin_lang['strdesclevel3'] = 'Este é o nível 3';
+ $plugin_lang['strdesclevel4'] = 'Este é o nível 4';
?>
View
7 plugins/Example/lang/recoded/english.php
@@ -5,6 +5,13 @@
* for new translations.
*/
+ // Language and character set
+ $lang['applang'] = 'English';
+ $lang['appcharset'] = 'ISO-8859-1';
+ $lang['applocale'] = 'en_US';
+ $lang['appdbencoding'] = 'LATIN1';
+ $lang['applangdir'] = 'ltr';
+
//Plugin data
$plugin_lang['strdescription'] = 'Plugin Example';
View
7 plugins/Example/lang/recoded/portuguese-br.php
@@ -5,6 +5,13 @@
* for new translations.
*/
+ // Language and character set
+ $lang['applang'] = 'Portugu&#234;s-Brasileiro';
+ $lang['appcharset'] = 'ISO-8859-1';
+ $lang['applocale'] = 'pt_BR';
+ $lang['appdbencoding'] = 'LATIN1';
+ $lang['applangdir'] = 'ltr';
+
//Dados do plugin
$plugin_lang['strdescription'] = 'Plugin Exemplo';
View
14 plugins/Example/plugin.php
@@ -135,14 +135,12 @@ function add_plugin_trail(&$plugin_functions_parameters) {
}
if (in_array($subject, array('show_page', 'show_level_2', 'show_level_3'))) {
- if (!$done) {
- $trail['show_page'] = array(
- 'title' => $this->lang['strlinktoplevel'],
- 'text' => $this->lang['strlinktoplevel'],
- 'url' => "plugin.php?".$misc->href."&plugin=".urlencode($this->name)."&action=show_page&subject=server",
- 'icon' => array('plugin' => 'Example', 'image' => 'Hook')
- );
- }
+ $trail['show_page'] = array(
+ 'title' => $this->lang['strlinktoplevel'],
+ 'text' => $this->lang['strlinktoplevel'],
+ 'url' => "plugin.php?".$misc->href."&plugin=".urlencode($this->name)."&action=show_page&subject=server",
+ 'icon' => array('plugin' => 'Example', 'image' => 'Hook')
+ );
if ($subject == 'show_page') $done = true;
View
26 privileges.php
@@ -259,13 +259,25 @@ function doDefault($msg = '') {
else {
$alterurl = "privileges.php?action=alter&amp;{$misc->href}&amp;{$subject}={$object}&amp;subject={$subject}&amp;mode=";
}
-
- echo "<ul class=\"navlink\">\n\t<li><a href=\"{$alterurl}grant\">{$lang['strgrant']}</a></li>\n";
- echo "\t<li><a href=\"{$alterurl}revoke\">{$lang['strrevoke']}</a></li>\n";
- if (isset($allurl))
- echo "\t<li><a href=\"{$allurl}?{$misc->href}\">{$alltxt}</a></li>\n";
-
- echo "</ul>\n";
+
+ $navlinks = array (
+ array (
+ 'attr'=> array ('href' => "{$alterurl}grant"),
+ 'content' => $lang['strgrant']
+ ), array (
+ 'attr'=> array ('href' => "{$alterurl}revoke"),
+ 'content' => $lang['strrevoke']
+ )
+ );
+
+ if (isset($allurl)) {
+ $navlinks[] = array (
+ 'attr'=> array ('href' => "{$allurl}?{$misc->href}"),
+ 'content' => $alltxt
+ );
+ }
+
+ $misc->printNavLinks($navlinks);
}
$misc->printHeader($lang['strprivileges']);
View
12 reports.php
@@ -121,8 +121,16 @@ function doProperties($msg = '') {
}
else echo "<p>{$lang['strinvalidparam']}</p>\n";
- echo "<ul class=\"navlink\">\n\t<li><a href=\"reports.php?{$misc->href}\">{$lang['strshowallreports']}</a></li>\n";
- echo "\t<li><a href=\"reports.php?action=edit&amp;{$misc->href}&amp;report_id={$report->fields['report_id']}\">{$lang['stredit']}</a></li>\n</ul>\n";
+ $navlinks = array (
+ array (
+ 'attr'=> array ('href' => "reports.php?{$misc->href}"),
+ 'content' => $lang['strshowallreports']
+ ), array (
+ 'attr'=> array ('href' => "reports.php?action=edit&amp;{$misc->href}&amp;report_id={$report->fields['report_id']}"),
+ 'content' => $lang['stredit']
+ )
+ );
+ $misc->printNavLinks($navlinks);
}
/**
View
37 roles.php
@@ -425,11 +425,20 @@ function doProperties($msg = '') {
}
else echo "<p>{$lang['strnodata']}</p>\n";
- echo "<ul class=\"navlink\">\n\t<li><a href=\"roles.php?{$misc->href}\">{$lang['strshowallroles']}</a></li>\n";
- echo "\t<li><a href=\"roles.php?action=alter&amp;{$misc->href}&amp;rolename=",
- urlencode($_REQUEST['rolename']), "\">{$lang['stralter']}</a></li>\n";
- echo "\t<li><a href=\"roles.php?action=confirm_drop&amp;{$misc->href}&amp;rolename=",
- urlencode($_REQUEST['rolename']), "\">{$lang['strdrop']}</li>\n</ul>\n";
+ $navlinks = array (
+ array (
+ 'attr'=> array ('href' => "roles.php?{$misc->href}"),
+ 'content' => $lang['strshowallroles']
+ ), array (
+ 'attr'=> array ('href' => "roles.php?action=alter&amp;{$misc->href}&amp;rolename=".urlencode($_REQUEST['rolename'])),
+ 'content' => $lang['stralter']
+ ), array (
+ 'attr'=> array ('href' => "roles.php?action=confirm_drop&amp;{$misc->href}&amp;rolename=".urlencode($_REQUEST['rolename'])),
+ 'content' => $lang['strdrop']
+ )
+ );
+
+ $misc->printNavLinks($navlinks);
}
/**
@@ -477,8 +486,14 @@ function doAccount($msg = '') {
echo "\t</tr>\n</table>\n";
}
else echo "<p>{$lang['strnodata']}</p>\n";
-
- echo "<p><a class=\"navlink\" href=\"roles.php?action=confchangepassword&amp;{$misc->href}\">{$lang['strchangepassword']}</a></p>\n";
+
+ $navlinks = array (
+ array (
+ 'attr'=> array ('href' => "roles.php?action=confchangepassword&amp;{$misc->href}"),
+ 'content' => $lang['strchangepassword']
+ )
+ );
+ $misc->printNavLinks($navlinks);
}
/**
@@ -618,7 +633,13 @@ function renderRoleExpires($val) {
$misc->printTable($roles, $columns, $actions, $lang['strnoroles']);
- echo "<p><a class=\"navlink\" href=\"roles.php?action=create&amp;{$misc->href}\">{$lang['strcreaterole']}</a></p>\n";
+ $navlinks = array (
+ array (
+ 'attr'=> array ('href' => "roles.php?action=create&amp;{$misc->href}"),
+ 'content' => $lang['strcreaterole']
+ )
+ );
+ $misc->printNavLinks($navlinks);
}
View
8 rules.php
@@ -157,7 +157,13 @@ function doDefault($msg = '') {
$misc->printTable($rules, $columns, $actions, $lang['strnorules']);
- echo "<p><a class=\"navlink\" href=\"rules.php?action=create_rule&amp;{$misc->href}&amp;{$subject}={$object}&amp;subject={$subject}\">{$lang['strcreaterule']}</a></p>\n";
+ $navlinks = array (
+ array (
+ 'attr'=> array ('href' => "rules.php?action=create_rule&amp;{$misc->href}&amp;{$subject}={$object}&amp;subject={$subject}"),
+ 'content' => $lang['strcreaterule']
+ )
+ );
+ $misc->printNavLinks($navlinks);
}
function doTree() {
View
8 schemas.php
@@ -73,7 +73,13 @@ function doDefault($msg = '') {
$misc->printTable($schemas, $columns, $actions, $lang['strnoschemas']);
- echo "<p><a class=\"navlink\" href=\"schemas.php?action=create&amp;{$misc->href}\">{$lang['strcreateschema']}</a></p>\n";
+ $navlinks = array (
+ array (
+ 'attr'=> array ('href' => "schemas.php?action=create&amp;{$misc->href}"),
+ 'content' => $lang['strcreateschema']
+ )
+ );
+ $misc->printNavLinks($navlinks);
}
/**
View
40 sequences.php
@@ -71,7 +71,13 @@ function doDefault($msg = '') {
$misc->printTable($sequences, $columns, $actions, $lang['strnosequences']);
- echo "<p><a class=\"navlink\" href=\"sequences.php?action=create&amp;{$misc->href}\">{$lang['strcreatesequence']}</a></p>\n";
+ $navlinks = array (
+ array (
+ 'attr'=> array ('href' => "sequences.php?action=create&amp;{$misc->href}"),
+ 'content' => $lang['strcreatesequence']
+ )
+ );
+ $misc->printNavLinks($navlinks);
}
/**
@@ -152,15 +158,33 @@ function doProperties($msg = '') {
echo "</tr>";
echo "</table>";
- echo "<ul class=\"navlink\">\n";
- echo "\t<li><a href=\"sequences.php?action=confirm_alter&amp;{$misc->href}&amp;sequence=", urlencode($sequence->fields['seqname']), "\">{$lang['stralter']}</a></li>\n";
- echo "\t<li><a href=\"sequences.php?action=confirm_setval&amp;{$misc->href}&amp;sequence=", urlencode($sequence->fields['seqname']), "\">{$lang['strsetval']}</a></li>\n";
- echo "\t<li><a href=\"sequences.php?action=nextval&amp;{$misc->href}&amp;sequence=", urlencode($sequence->fields['seqname']), "\">{$lang['strnextval']}</a></li>\n";
+ $navlinks = array (
+ array (
+ 'attr'=> array ('href' => "sequences.php?action=confirm_alter&amp;{$misc->href}&amp;sequence=".urlencode($sequence->fields['seqname'])),
+ 'content' => $lang['stralter']
+ ), array (
+ 'attr'=> array ('href' => "sequences.php?action=confirm_setval&amp;{$misc->href}&amp;sequence=".urlencode($sequence->fields['seqname'])),
+ 'content' => $lang['strsetval']
+ ), array (
+ 'attr'=> array ('href' => "sequences.php?action=nextval&amp;{$misc->href}&amp;sequence=".urlencode($sequence->fields['seqname'])),
+ 'content' => $lang['strnextval']
+ )
+ );
+ $misc->printNavLinks($navlinks);
if ($data->hasAlterSequenceStart()) {
- echo "\t<li><a href=\"sequences.php?action=restart&amp;{$misc->href}&amp;sequence=", urlencode($sequence->fields['seqname']), "\">{$lang['strrestart']}</a></li>\n";
+ $navlinks[] = array (
+ 'attr'=> array ('href' => "sequences.php?action=restart&amp;{$misc->href}&amp;sequence=", urlencode($sequence->fields['seqname'])),
+ 'content' => $lang['strrestart']
+ );
}
- echo "\t<li><a href=\"sequences.php?action=reset&amp;{$misc->href}&amp;sequence=", urlencode($sequence->fields['seqname']), "\">{$lang['strreset']}</a></li>\n";
- echo "\t<li><a href=\"sequences.php?{$misc->href}\">{$lang['strshowallsequences']}</a></li>\n</ul>\n";
+ $navlinks[] = array (
+ 'attr'=> array ('href' => "sequences.php?action=reset&amp;{$misc->href}&amp;sequence=".urlencode($sequence->fields['seqname'])),
+ 'content' => $lang['strreset']
+ );
+ $navlinks[] = array (
+ 'attr'=> array ('href' => "sequences.php?{$misc->href}"),
+ 'content' => $lang['strshowallsequences']
+ );
}
else echo "<p>{$lang['strnodata']}</p>\n";
}
View
16 servers.php
@@ -82,12 +82,20 @@ function svPre(&$rowdata, $actions) {
$misc->printTable($servers, $columns, $actions, $lang['strnoobjects'], 'svPre');
if (isset($conf['srv_groups'])) {
- echo "<br /><ul class=\"navlink\">\n";
- echo "\t<li><a href=\"servers.php\">{$lang['strallservers']}</a></li>\n";
+ $navlinks = array (
+ array (
+ 'attr'=> array ('href' => "servers.php"),
+ 'content' => $lang['strallservers']
+ )
+ );
+
foreach ($conf['srv_groups'] as $id => $grp) {
- echo "\t<li><a href=\"servers.php?group={$id}\">", htmlentities($grp['desc']), "</a></li>\n";
+ $navlinks[] = array (
+ 'attr'=> array ('href' => "servers.php?group={$id}"),
+ 'content' => htmlentities($grp['desc'])
+ );
}
- echo "</ul>\n";
+ $misc->printNavLinks($navlinks);
}
}
View
47 sql.php
@@ -190,35 +190,48 @@ function sqlCallback($query, $rs, $lineno) {
}
echo "<p>{$lang['strsqlexecuted']}</p>\n";
-
- echo "<ul class=\"navlink\">\n";
-
+
+ $navlinks = array();
+
// Return
if (isset($_REQUEST['return_url']) && isset($_REQUEST['return_desc']))
- echo "\t<li><a href=\"{$_REQUEST['return_url']}\">{$_REQUEST['return_desc']}</a></li>\n";
+ $navlinks[] = array (
+ 'attr'=> array ('href' => $_REQUEST['return_url']),
+ 'content' => $_REQUEST['return_desc']
+ );
// Edit
- echo "\t<li><a href=\"database.php?database=", urlencode($_REQUEST['database']),
- "&amp;server=", urlencode($_REQUEST['server']), "&amp;action=sql\">{$lang['streditsql']}</a></li>\n";
-
+ $navlinks[] = array (
+ 'attr'=> array ('href' => "database.php?database=".urlencode($_REQUEST['database'])."&amp;server=".urlencode($_REQUEST['server'])."&amp;action=sql"),
+ 'content' => $lang['streditsql']
+ );
+
// Create report
if (($subject !== 'report') && $conf['show_reports'] && isset($rs) && is_object($rs) && $rs->recordCount() > 0)
- echo "\t<li><a href=\"reports.php?{$misc->href}&amp;action=create&amp;report_sql=",
- urlencode($_SESSION['sqlquery']), "\">{$lang['strcreatereport']}</a></li>\n";
-
+ $navlinks[] = array (
+ 'attr'=> array ('href' => "reports.php?{$misc->href}&amp;action=create&amp;report_sql=".urlencode($_SESSION['sqlquery'])),
+ 'content' => $lang['strcreatereport']
+ );
+
// Create view and download
if (isset($_SESSION['sqlquery']) && isset($rs) && is_object($rs) && $rs->recordCount() > 0) {
// Report views don't set a schema, so we need to disable create view in that case
if (isset($_REQUEST['schema']))
- echo "\t<li><a href=\"views.php?action=create&amp;formDefinition=",
- urlencode($_SESSION['sqlquery']), "&amp;{$misc->href}\">{$lang['strcreateview']}</a></li>\n";
- echo "\t<li><a href=\"dataexport.php?query=", urlencode($_SESSION['sqlquery']);
+ $navlinks[] = array (
+ 'attr'=> array ('href' => "views.php?action=create&amp;formDefinition=".urlencode($_SESSION['sqlquery'])."&amp;{$misc->href}"),
+ 'content' => $lang['strcreateview']
+ );
+
+ $url = "dataexport.php?query=".urlencode($_SESSION['sqlquery']);
if (isset($_REQUEST['search_path']))
- echo "&amp;search_path=", urlencode($_REQUEST['search_path']);
- echo "&amp;{$misc->href}\">{$lang['strdownload']}</a></li>\n";
+ $url .= "&amp;search_path=".urlencode($_REQUEST['search_path']);
+ $url .= "&amp;{$misc->href}";
+ $navlinks[] = array (
+ 'attr'=> array ('href' => $url),
+ 'content' => $lang['strdownload']
+ );
}
+ $misc->printNavLinks($navlinks);
- echo "</ul>\n";
-
$misc->printFooter();
?>
View
18 tables.php
@@ -827,10 +827,20 @@ function doDefault($msg = '') {
$misc->printTable($tables, $columns, $actions, $lang['strnotables']);
- echo "<ul class=\"navlink\">\n\t<li><a href=\"tables.php?action=create&amp;{$misc->href}\">{$lang['strcreatetable']}</a></li>\n";
- if (($tables->recordCount() > 0) && $data->hasCreateTableLike())
- echo "\t<li><a href=\"tables.php?action=createlike&amp;{$misc->href}\">{$lang['strcreatetablelike']}</a></li>\n";
- echo "</ul>\n";
+ $navlinks = array (
+ array (
+ 'attr'=> array ('href' => "tables.php?action=create&amp;{$misc->href}"),
+ 'content' => $lang['strcreatetable']
+ )
+ );
+ if (($tables->recordCount() > 0) && $data->hasCreateTableLike()) {
+ $navlinks[] = array (
+ 'attr'=> array ('href' => "tables.php?action=createlike&amp;{$misc->href}"),
+ 'content' => $lang['strcreatetablelike']
+ );
+ }
+
+ $misc->printNavLinks($navlinks);
}
require('./admin.php');
View
10 tablespaces.php
@@ -255,8 +255,14 @@ function doDefault($msg = '') {
);
$misc->printTable($tablespaces, $columns, $actions, $lang['strnotablespaces']);
-
- echo "<p><a class=\"navlink\" href=\"tablespaces.php?action=create&amp;{$misc->href}\">{$lang['strcreatetablespace']}</a></p>\n";
+
+ $navlinks = array (
+ array (
+ 'attr'=> array ('href' => "tablespaces.php?action=create&amp;{$misc->href}"),
+ 'content' => $lang['strcreatetablespace']
+ )
+ );
+ $misc->printNavLinks($navlinks);
}
View
35 tblproperties.php
@@ -567,16 +567,31 @@ function cstrRender($s, $p) {
$misc->printTable($attrs, $columns, $actions, null, 'attPre');
- echo "<ul class=\"navlink\">\n";
- echo "\t<li><a href=\"display.php?{$misc->href}&amp;table=", urlencode($_REQUEST['table']), "&amp;subject=table&amp;return_url={$return_url}&amp;return_desc=",
- urlencode($lang['strback']), "\">{$lang['strbrowse']}</a></li>\n";
- echo "\t<li><a href=\"tables.php?action=confselectrows&amp;{$misc->href}&amp;table=", urlencode($_REQUEST['table']),"\">{$lang['strselect']}</a></li>\n";
- echo "\t<li><a href=\"tables.php?action=confinsertrow&amp;{$misc->href}&amp;table=", urlencode($_REQUEST['table']),"\">{$lang['strinsert']}</a></li>\n";
- echo "\t<li><a href=\"tables.php?action=confirm_empty&amp;{$misc->href}&amp;table=", urlencode($_REQUEST['table']),"\">{$lang['strempty']}</a></li>\n";
- echo "\t<li><a href=\"tables.php?action=confirm_drop&amp;{$misc->href}&amp;table=", urlencode($_REQUEST['table']),"\">{$lang['strdrop']}</a></li>\n";
- echo "\t<li><a href=\"tblproperties.php?action=add_column&amp;{$misc->href}&amp;table=", urlencode($_REQUEST['table']),"\">{$lang['straddcolumn']}</a></li>\n";
- echo "\t<li><a href=\"tblproperties.php?action=confirm_alter&amp;{$misc->href}&amp;table=", urlencode($_REQUEST['table']),"\">{$lang['stralter']}</a></li>\n";
- echo "</ul>\n";
+ $navlinks = array (
+ array (
+ 'attr'=> array ('href' => "display.php?{$misc->href}&amp;table=".urlencode($_REQUEST['table'])."&amp;subject=table&amp;return_url={$return_url}&amp;return_desc=".urlencode($lang['strback'])),
+ 'content' => $lang['strbrowse']
+ ), array (
+ 'attr'=> array ('href' => "tables.php?action=confselectrows&amp;{$misc->href}&amp;table=".urlencode($_REQUEST['table'])),
+ 'content' => $lang['strselect']
+ ), array (
+ 'attr'=> array ('href' => "tables.php?action=confinsertrow&amp;{$misc->href}&amp;table=".urlencode($_REQUEST['table'])),
+ 'content' => $lang['strinsert']
+ ), array (
+ 'attr'=> array ('href' => "tables.php?action=confirm_empty&amp;{$misc->href}&amp;table=".urlencode($_REQUEST['table'])),
+ 'content' => $lang['strempty']
+ ), array (
+ 'attr'=> array ('href' => "tables.php?action=confirm_drop&amp;{$misc->href}&amp;table=".urlencode($_REQUEST['table'])),
+ 'content' => $lang['strdrop']
+ ), array (
+ 'attr'=> array ('href' => "tblproperties.php?action=add_column&amp;{$misc->href}&amp;table=".urlencode($_REQUEST['table'])),
+ 'content' => $lang['straddcolumn']
+ ), array (
+ 'attr'=> array ('href' => "tblproperties.php?action=confirm_alter&amp;{$misc->href}&amp;table=".urlencode($_REQUEST['table'])),
+ 'content' => $lang['stralter']
+ )
+ );
+ $misc->printNavLinks($navlinks);
}
$misc->printHeader($lang['strtables'] . ' - ' . $_REQUEST['table']);
View
10 triggers.php
@@ -330,8 +330,14 @@ function tgPre(&$rowdata,$actions) {
}
$misc->printTable($triggers, $columns, $actions, $lang['strnotriggers'], 'tgPre');
-
- echo "<p><a class=\"navlink\" href=\"triggers.php?action=create&amp;{$misc->href}&amp;table=", urlencode($_REQUEST['table']), "\">{$lang['strcreatetrigger']}</a></p>\n";
+
+ $navlinks = array (
+ array (
+ 'attr'=> array ('href' => "triggers.php?action=create&amp;{$misc->href}&amp;table=".urlencode($_REQUEST['table'])),
+ 'content' => $lang['strcreatetrigger']
+ )
+ );
+ $misc->printNavLinks($navlinks);
}
function doTree() {
View
30 types.php
@@ -85,7 +85,13 @@ function attPre(&$rowdata) {
echo "</table>\n";
}
- echo "<p><a class=\"navlink\" href=\"types.php?{$misc->href}\">{$lang['strshowalltypes']}</a></p>\n";
+ $navlinks = array (
+ array (
+ 'attr'=> array ('href' => "types.php?{$misc->href}"),
+ 'content' => $lang['strshowalltypes']
+ )
+ );
+ $misc->printNavLinks($navlinks);
} else
doDefault($lang['strinvalidparam']);
}
@@ -575,11 +581,23 @@ function doDefault($msg = '') {
$misc->printTable($types, $columns, $actions, $lang['strnotypes']);
- echo "<ul class=\"navlink\">\n\t<li><a href=\"types.php?action=create&amp;{$misc->href}\">{$lang['strcreatetype']}</a></li>\n";
- echo "\t<li><a href=\"types.php?action=create_comp&amp;{$misc->href}\">{$lang['strcreatecomptype']}</a></li>\n";
- if ($data->hasEnumTypes())
- echo "\t<li><a href=\"types.php?action=create_enum&amp;{$misc->href}\">{$lang['strcreateenumtype']}</a></li>\n";
- echo "</ul>\n";
+ $navlinks = array (
+ array (
+ 'attr'=> array ('href' => "types.php?action=create&amp;{$misc->href}"),
+ 'content' => $lang['strcreatetype']
+ ), array (
+ 'attr'=> array ('href' => "types.php?action=create_comp&amp;{$misc->href}"),
+ 'content' => $lang['strcreatecomptype']
+ )
+ );
+
+ if ($data->hasEnumTypes()) {
+ $navlinks[] = array (
+ 'attr'=> array ('href' => "types.php?action=create_enum&amp;{$misc->href}"),
+ 'content' => $lang['strcreateenumtype']
+ );
+ }
+ $misc->printNavLinks($navlinks);
}
/**
View
18 users.php
@@ -46,8 +46,14 @@ function doAccount($msg = '') {
echo "</tr>\n</table>\n";
}
else echo "<p>{$lang['strnodata']}</p>\n";
-
- echo "<p><a class=\"navlink\" href=\"users.php?action=confchangepassword&amp;{$misc->href}\">{$lang['strchangepassword']}</a></p>\n";
+
+ $navlinks = array (
+ array (
+ 'attr'=> array ('href' => "users.php?action=confchangepassword&amp;{$misc->href}"),
+ 'content' => $lang['strchangepassword']
+ )
+ );
+ $misc->printNavLinks($navlinks);
}
/**
@@ -330,7 +336,13 @@ function renderUseExpires($val) {
$misc->printTable($users, $columns, $actions, $lang['strnousers']);
- echo "<p><a class=\"navlink\" href=\"users.php?action=create&amp;{$misc->href}\">{$lang['strcreateuser']}</a></p>\n";
+ $navlinks = array (
+ array (
+ 'attr'=> array ('href' => "users.php?action=create&amp;{$misc->href}"),
+ 'content' => $lang['strcreateuser']
+ )
+ );
+ $misc->printNavLinks($navlinks);
}
View
36 viewproperties.php
@@ -149,9 +149,14 @@ function doDefinition($msg = '') {
echo "</table>\n";
}
else echo "<p>{$lang['strnodata']}</p>\n";
-
- echo "<p><a class=\"navlink\" href=\"viewproperties.php?action=edit&amp;{$misc->href}&amp;view=",
- urlencode($_REQUEST['view']), "\">{$lang['stralter']}</a></p>\n";
+
+ $navlinks = array (
+ array (
+ 'attr'=> array ('href' => "viewproperties.php?action=edit&amp;{$misc->href}&amp;view=".urlencode($_REQUEST['view'])),
+ 'content' => $lang['stralter']
+ )
+ );
+ $misc->printNavLinks($navlinks);
}
/**
@@ -429,14 +434,23 @@ function attPre(&$rowdata) {
echo "<br />\n";
- echo "<ul class=\"navlink\">\n";
- $return_url = urlencode("viewproperties.php?{$misc->href}&amp;view=" . urlencode($_REQUEST['view']));
- echo "\t<li><a href=\"display.php?{$misc->href}&amp;view=", urlencode($_REQUEST['view']), "&amp;subject=view&amp;return_url={$return_url}&amp;return_desc=",
- urlencode($lang['strback']), "\">{$lang['strbrowse']}</a></li>\n";
- echo "\t<li><a href=\"views.php?action=confselectrows&amp;{$misc->href}&amp;view=", urlencode($_REQUEST['view']),"\">{$lang['strselect']}</a></li>\n";
- echo "\t<li><a href=\"views.php?action=confirm_drop&amp;{$misc->href}&amp;view=", urlencode($_REQUEST['view']),"\">{$lang['strdrop']}</a></li>\n";
- echo "\t<li><a href=\"viewproperties.php?action=confirm_alter&amp;{$misc->href}&amp;view=", urlencode($_REQUEST['view']),"\">{$lang['stralter']}</a></li>\n";
- echo "</ul>\n";
+ $return_url = urlencode("viewproperties.php?{$misc->href}&amp;view=".urlencode($_REQUEST['view']));
+ $navlinks = array (
+ array (
+ 'attr'=> array ('href' => "display.php?{$misc->href}&amp;view=".urlencode($_REQUEST['view'])."&amp;subject=view&amp;return_url={$return_url}&amp;return_desc=".urlencode($lang['strback'])),
+ 'content' => $lang['strbrowse']
+ ), array (
+ 'attr'=> array ('href' => "views.php?action=confselectrows&amp;{$misc->href}&amp;view=".urlencode($_REQUEST['view'])),
+ 'content' => $lang['strselect']
+ ), array (
+ 'attr'=> array ('href' => "views.php?action=confirm_drop&amp;{$misc->href}&amp;view=".urlencode($_REQUEST['view'])),
+ 'content' => $lang['strdrop']
+ ), array (
+ 'attr'=> array ('href' => "viewproperties.php?action=confirm_alter&amp;{$misc->href}&amp;view=".urlencode($_REQUEST['view'])),
+ 'content' => $lang['stralter']
+ )
+ );
+ $misc->printNavLinks($navlinks);
}
$misc->printHeader($lang['strviews'] . ' - ' . $_REQUEST['view']);
View
13 views.php
@@ -618,10 +618,17 @@ function doDefault($msg = '') {
);
$misc->printTable($views, $columns, $actions, $lang['strnoviews']);
-
- echo "<ul class=\"navlink\">\n\t<li><a href=\"views.php?action=create&amp;{$misc->href}\">{$lang['strcreateview']}</a></li>\n";
- echo "\t<li><a href=\"views.php?action=wiz_create&amp;{$misc->href}\">{$lang['strcreateviewwiz']}</a></li>\n</ul>\n";
+ $navlinks = array (
+ array (
+ 'attr'=> array ('href' => "views.php?action=create&amp;{$misc->href}"),
+ 'content' => $lang['strcreateview']
+ ), array (
+ 'attr'=> array ('href' => "views.php?action=wiz_create&amp;{$misc->href}"),
+ 'content' => $lang['strcreateviewwiz']
+ )
+ );
+ $misc->printNavLinks($navlinks);
}
/**

No commit comments for this range

Something went wrong with that request. Please try again.