Menu

[r16]: / html / screen.php  Maximize  Restore  History

Download this file

173 lines (172 with data), 5.6 kB

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
<?php
session_start();
$user_ID=$_SESSION[user_ID];
if (!$user_ID || $user_ID=='0')
{
header('location: index.php');
die('Login failed');
}
require("util.php");
$sql = new MySQL_class;
$sql->Create("generator");
$esql = new MySQL_class;
$esql->Create("generator");
if ($_GET[screen]) { $_SESSION[var_screen] = $_GET[screen]; }
if ($_GET[DatabaseID]) { $_SESSION[var_DatabaseID] = $_GET[DatabaseID]; }
if ($_GET[part]) { $_SESSION[var_part] = $_GET[part]; }
$screen=$_SESSION[var_screen];
$DatabaseID=$_SESSION[var_DatabaseID];
$part=$_SESSION[var_part];
?>
<html>
<head>
<link href="list.css" type="text/css" rel=stylesheet>
<meta content="text/css" http-equiv="Content-Style-Type">
<title>Screen generator Scherm: Screen</title>
</head>
<script type="text/javascript" src="handlers.js" language="JavaScript">
alert ("no code");
</script>
<body>
<?php
include 'menu.php';
include 'makemenu.php';
makeMenu(0, 2, '');
?>
<div id="content">
<?php
$sql->QueryItem("SELECT screen.name as F446, screen.title as F447, screen.class as F511, T732.title as F732_1, screen.helpfile as F769 FROM `screen`
LEFT JOIN `screen` AS T732 ON screen.parent=T732.screen
WHERE `screen`.`screen` = '$screen'
ORDER BY `screen`.`title` ASC LIMIT 1");
$name = $sql->data['F446'];
$stitle = $sql->data['F447'];
$class = $sql->data['F511'];
$title_732=$sql->data[F732_1];
$parent = "$title_732";
$helpfile = $sql->data['F769'];
echo ('<table class=record>');
echo ("<tr><th>Name</th>
<td>$name</td>");
echo ("</tr>");
echo ("<tr><th>Title</th>
<td>$stitle</td>");
echo ("</tr>");
echo ("<tr><th>Class</th>
<td>$class</td>");
echo ("</tr>");
echo ("<tr><th>Parent</th>
<td>$parent</td>");
echo ("</tr>");
echo ("<tr><th>Help file</th>
<td>$helpfile</td>");
echo ("</tr>");
echo ('</table>');
?>
<p><input type=button value="Edit Screen" onClick="javascript: window.open('editscreen.php?screen=<?php echo $screen; ?>','','width=500,height=270,location=no,menubar=no,scrollbars=yes,status=no,resizable=yes'); return false;">
<?php
$lastorder=$_SESSION[last_62];
$lastfilter62=$_SESSION[filter62];
$_SESSION[last_62]='';
if ($_GET[filter62]) { $filter62 =$_GET[filter62]; } else { $filter62=$_POST[filter62];}
if ($_GET[page62]) { $page=$_GET[page62]; } else { $page=$_POST[page62]; }
if ($filter62!=$lastfilter62) {
$_SESSION[filter62]=$filter62;
$page=0;
}
if ($filter62!='')
{
$qfilter62 = quote('%'.$filter62.'%');
$query = ("
FROM `part`
LEFT JOIN `tables` AS T453 ON part.table=T453.TableID
LEFT JOIN `screen` AS T454 ON part.link=T454.screen
WHERE (T453.Subject LIKE $qfilter62
OR T454.name LIKE $qfilter62
OR part.`title` LIKE $qfilter62
) AND `part`.`screen`='$screen'
");
}
else
{
$query = ("
FROM `part`
LEFT JOIN `tables` AS T453 ON part.table=T453.TableID
LEFT JOIN `screen` AS T454 ON part.link=T454.screen
WHERE 1 AND `part`.`screen`='$screen'
");
}
$lastrec=-1;
$sql->QueryItem("SELECT COUNT(*) AS records$query");
$records=$sql->data[records];
if ($lastorder=='') {$fromrec=20*$page;} else {
$sql->QueryItem("SELECT COUNT(*) AS fromrec$query AND `part`.`order` < $lastorder");
$fromrec=$sql->data[fromrec]-10;
if($fromrec<0) {$fromrec=0; }
$lastrec=$sql->data[fromrec]-$fromrec;
}
$sql->Query("SELECT part.part as F495, part.screen as F450, part.type as F452, T453.Subject as F453_1, T454.name as F454_1, part.title as F456, part.code as F457, part.order as F515$query
ORDER BY `part`.`order` ASC
LIMIT $fromrec, 20");
if (($part_rights['18/nofilter']==0)) {
echo "<form action=\"\" method=get name=Filter>";
echo "<p class=filter>";
echo "Records: $records ";
$maxpage=(int) (($records+19)/20);
if ($maxpage>1) {
echo "Page: ";
echo "<select name=\"page62\" OnChange=\"Filter.target=''; Filter.action = ''; Filter.submit();\">\n";
for ($i = 0; $i < $maxpage; $i++)
{
$nr=$i+1;
if ($i==$page) {$sel=" selected";} else {$sel="";}
echo "<option value=$i$sel>$nr van $maxpage</option>\n";
}
echo "</select>\n";
}
echo "<input type=text name=\"filter62\" size=25 value=\"$filter62\">";
echo "<input type=submit value=\"Search\">";
echo "<input type=button value=\"Add Part\" onClick=\"javascript: window.open('addpart.php?part=$part&screen=$screen','','width=500,height=500,location=no,menubar=no,scrollbars=yes,status=no,resizable=yes'); return false;\">";
echo "</p>";
echo "</form>";
}
?>
<table class=list>
<tr>
<th></th>
<th width=210px>Type</th>
<th width=210px>Table</th>
<th width=210px>Link</th>
<th width=210px>Title</th>
<th width=210px>Code</th>
<th width=35px>Order</th>
</tr>
<?php
for ($i = 0; $i < $sql->rows; $i++)
{
$sql->Fetch($i);
$part = $sql->data['F495'];
$type = htmlspecialchars($sql->data['F452']);
$Subject_453=$sql->data[F453_1];
$table_lup = "$Subject_453";
$name_454=$sql->data[F454_1];
$link_lup = "$name_454";
$title = htmlspecialchars($sql->data['F456']);
$code = htmlspecialchars($sql->data['F457']);
$order = htmlspecialchars($sql->data['F515']);
if ($lastrec==$i) {$color="style=\"background-color: #aaaaff;\"";} else {$color="";}
echo ("
<tr $color onMouseOver=\"ChangeColor(this)\" onMouseOut=\"ChangeColorBack(this)\" onClick=\"window.open('editpart.php?part=$part&screen=$screen','wijzigen','width=500,height=500,location=no,menubar=no,scrollbars=yes,status=no,resizable=yes')\">
<td onClick=\"window.open('addpart.php?order=$order','add','width=500,height=500,location=no,menubar=no,scrollbars=yes,status=no,resizable=yes'); no_bubble(event);\"><b>Add</b></td>
<td>$type</td>
<td>$table_lup</td>
<td>$link_lup</td>
<td>$title</td>
<td>$code</td>
<td>$order</td>
</tr>");
}
?>
</table>
</div></body>
</html>
Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.