Menu

[2eb2a2]: / index.php  Maximize  Restore  History

Download this file

310 lines (271 with data), 9.9 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
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
<?php session_start(); ?>
<html>
<head>
<title>deltasql - Database Evolution under Control</title>
<link rel="stylesheet" type="text/css" href="deltasql.css">
<link rel="shortcut icon" href="pictures/favicon.ico" />
</head>
<body>
<?php
include("utils/constants.inc.php");
include("utils/utils.inc.php");
include("utils/timing.inc.php");
include("patch/patchlevel.inc.php");
if (file_exists($configurationfile)) {
include("conf/config.inc.php");
} else {
include("head-main.inc.php");
echo "<h2><a href=\"install.php\">$installmessage</a></h2>";
echo "<h2>deltasql Server $deltasql_version</h2>";
exit();
}
include("head.inc.php");
$startwatch = start_watch();
if (!isset($disable_clients_table_on_main_page)) $disable_clients_table_on_main_page= false;
if (!isset($disable_topten_submitters)) $disable_topten_submitters=true;
if (!isset($enable_server_stats)) $enable_server_stats=true;
if (!isset($dns_name)) $dns_name="";
if (!isset($db_integrity_check)) $db_integrity_check=true;
if(isset($_SESSION['userid'])) {
$rights = $_SESSION["rights"];
$user = $_SESSION["username"];
} else {
$rights=0; $user="";
}
?>
<p>
<?php
if (file_exists($configurationfile)) {
// showing date and hour of latest changes
mysql_connect($dbserver, $username, $password);
@mysql_select_db($database) or die("Unable to select database");
$query5="SELECT count(*) from tbscript;";
$result5=mysql_query($query5);
$nbscripts=mysql_result($result5,0,'count(*)');
$query6="SELECT count(*) from tbsyncstats;";
$result6=mysql_query($query6);
$nbsyncs=mysql_result($result6,0,'count(*)');
$query7="SELECT count(*) from tbproject;";
$result7=mysql_query($query7);
$nbprojects=mysql_result($result7,0,'count(*)');
$query8="SELECT count(*) from tbbranch;";
$result8=mysql_query($query8);
$nbbranches=mysql_result($result8,0,'count(*)');
$query55="SELECT count(*) from tbmodule;";
$result55=mysql_query($query55);
$nbmodules=mysql_result($result55,0,'count(*)');
$query3="SELECT create_dt FROM `tbbranch` where name='HEAD'";
$result3=mysql_query($query3);
$create_dt=mysql_result($result3,0,'create_dt');
show_user_level();
// checking if the database schema is uptodate
$query4="SELECT tagname FROM `tbsynchronize` where versionnr=(select max(versionnr) FROM tbsynchronize);";
$result4=mysql_query($query4);
$tagname=mysql_result($result4,0,'tagname');
if (($db_integrity_check) && ($tagname!="TAG_deltasql_$ds_schema_version")) {
if ($tagname=="") $tagname="TAG_deltasql_1.3.?";
echo "<p><b><font color=\"red\">Deltasql database schema needs to be upgraded! The database needs to be tagged with TAG_deltasql_$ds_schema_version.</b></font></p>";
echo "<p>Please visit the <a href=\"http://deltasql.sourceforge.net/deltasql/dbsync.php\">synchronization page on deltasql.sourceforge.net</a>, ";
echo " set as parameters <b>Project Name: deltasql-Server</b>, <b>From: $tagname</b>, <b>Update To: TAG_deltasql_$ds_schema_version</b>, leave the <b>Version Number:</b> field empty ";
echo " and hit the synchronization button at the bottom. Then execute the generated script into the deltasql schema to solve this issue. </p>";
echo "<p>If deltasql.sourceforge.net should be offline for whatever reason, use the script <tt>db/migration_path.sql</tt> instead and figure out what it does.</p>";
echo "<p>If you are developing deltasql or you patched it, you might want to disable this error by setting the <b>db_integrity_check</b> variable in ";
echo "<i>$configurationfile</i> to false.";
mysql_close();
die("<p><b><font color=\"red\">FATAL ERROR: datamodel mismatch for database '$database' on host '$dbserver'.</font></b></p>");
}
mysql_close();
echo "<h2>deltasql server ";
echo "<a href=\"docs/ChangeLog.txt\">$deltasql_version</a>";
if ($patchlevel!="") echo "-<a href=\"patch/description.txt\">$patchlevel</a>";
echo "</h2>";
}
?>
<table cellspacing="4" cellpadding="4">
<tr>
<td valign="top">
</p>
<h3>SQL Scripts</h3>
<ul>
<?php
if ($rights>0)
echo "<li><a href=\"submit_script.php\">Submit Script</a></li>";
echo "<li><a href=\"list_scripts.php\">List Scripts</a> <a href=\"get_rss_feed.php\"><img src=\"pictures/rss-icon.png\" border=0/></a></li>";
if ($rights>2)
echo "<br><li><a href=\"list_changelog_deleted.php\">View deleted</a></li>";
?>
</ul>
</td>
<td valign="top">
<h3>Modules</h3>
<ul>
<?php
if ($rights>1)
echo "<li><a href=\"create_module.php\">Create Module</a></li>";
?>
<li><a href="list_modules.php">List Modules</a></li>
</ul>
</td>
<td valign="top">
<h3>Projects</h3>
<ul>
<?php
if ($rights>1)
echo "<li><a href=\"create_project.php\">Create a Project</a></li>";
?>
<li><a href="list_projects.php">List Projects</a></li><br>
<?php
if ($rights>=2) {
echo "<li><a href=\"export_project.php\">Export Project</a></li>";
}
if ($enable_server_stats) echo "<br><li><a href=\"server_stats.php\">Statistics</a></li>";
?>
</ul>
</td>
<td valign="top">
<h3>Synchronization</h3>
<ul>
<li><a href="get_synchronization_table.php">Get Synchronization Table <img src="icons/history.png"> </a></li>
<li><a href="list_branches.php">List Branches and Tags <img src="icons/tree.png"></a></li>
<li><a href="dbsync.php">Synchronize database <img src="icons/show2.png"></a></li>
</ul>
</td>
<td valign="top">
<h3>Users</h3>
<ul>
<?php
if ($rights>2)
echo "<li><a href=\"insert_user.php\">Create User</a></li>";
if ($rights>1) {
echo "<li><a href=\"list_users.php\">List Users</a></li>";
echo "<br>";
}
?>
<?php
if ($rights==0)
echo "<li><a href=\"login.php\">Login <img src=\"icons/rights.png\"></a></li>";
if ($rights>0) {
echo "<li><a href=\"preferences.php\">Preferences <img src=\"icons/settings.png\"></a></li>";
echo "<li><a href=\"logout.php\">Logout <img src=\"icons/logout.png\"></a></li>";
}
if (!$disable_topten_submitters) {
echo "<br><li><a href=\"topten.php\">Top Ten</a></li><br>";
}
?>
</ul>
</td>
<td>
</td>
<td>
<h3>Utils</h3>
<ul>
<li><a href="clients.php">Clients</a></li>
<li><a href="tools.php">Toolbox</a></li>
<?php
if ($rights>0) {
echo "<li><a href='docs_listall.php'>Documents</a></li>";
}
?>
</ul>
</td>
<td>
<h3>Help</h3>
<ul>
<?php
if (isset($_SESSION['displayhelplinks'])) $displayhelp=$_SESSION['displayhelplinks']; else $displayhelp=$default_displayhelplinks;
if ($displayhelp==1) {
echo '<li><a href="manual.php#quickguide"><img src="icons/help.png"> Quick Guide</a></li>';
echo '<li><a href="faq.php#algo"><img src="icons/help.png"> Synchronization Overview</a></li>';
}
?>
<li><a href="manual.php">Manual</a></li>
<li><a href="faq.php">FAQ</a></li>
<br>
<?php
if ($enterprise_edition==false) {
echo "<li><a href=\"http://www.openhub.net/p/deltasql\" target=_blank>OpenHub metrics...</a></li>";
echo "<li><a href=\"http://sourceforge.net/projects/deltasql/\" target=_blank>Project Page...</a></li>";
} else {
echo "<li><a href=\"$enterprise_website\">$enterprise_name</a></li>";
}
echo "<li><a href=\"http://sourceforge.net/p/deltasql/discussion/\" target=blank_>Forum...</a></li>";
?>
<br>
<li><a href="http://deltasql.sourceforge.net" target=blank_>deltasql Website...</a></li>
<?php
if (file_exists($configurationfile)) {
echo "<li><a href=\"http://deltasql.sourceforge.net/deltasql/latest_changelog.php?version=$deltasql_version&scripts=$nbscripts&syncs=$nbsyncs&projs=$nbprojects&bras=$nbbranches&mod=$nbmodules\" target=blank_>Latest Changelog...</a></li>";
}
if (($rights>2) && ($dns_name!="http://deltasql.sourceforge.net/deltasql")) {
echo "<li><a href='phpinfo.php'>Environment</a></li> ";
}
?>
</ul>
</td>
</table>
<center>
<img src="docs/devel-with-deltasql.jpg" border="0"><br>
</center>
<br><br>
<center>
<?php
if (file_exists($configurationfile)) {
echo "<center>";
echo "Scripts: ";
echo "<b>$nbscripts</b> / ";
echo "Syncs: ";
echo "<b>$nbsyncs</b> / ";
echo "Projects: ";
echo "<b>$nbprojects</b> / ";
echo "Branches: ";
echo "<b>$nbbranches</b> / ";
echo "Modules: ";
echo "<b>$nbmodules</b> / ";
echo "Last Update: ";
echo "<b>$create_dt</b> ";
echo "</center>";
}
?>
<hr>
<h6>deltasql is Open Source under <a href="docs/GPL_license.txt">GPL</a> (source code <a href="http://sourceforge.net/projects/deltasql/">here</a>) and is developed
and mantained by the <a href="http://sourceforge.net/projects/deltasql/">deltasql Team</a>.
<?php
if (file_exists($configurationfile)) {
if ($enterprise_edition==false) {
echo " The deltasql logo was designed by <a href=\"patrizia.php\">Patrizia Pulice Cascio</a>. ";
} else {
echo " The deltasql logo was designed by Patrizia Pulice Cascio. ";
}
echo "The latest changelog is <a href=\"http://deltasql.sourceforge.net/deltasql/latest_changelog.php?version=$deltasql_version&scripts=$nbscripts&syncs=$nbsyncs&projs=$nbprojects&bras=$nbbranches&mod=$nbmodules\">here</a>. ";
if ($patchlevel!="") {
echo "A description of the applied patch is <a href=\"patch/description.txt\">here</a>. ";
}
}
stop_watch($startwatch);
echo "</h6>";
?>
<br>
<a href="http://www.sourceforge.net">
<img src="pictures/sourceforge-logo.gif" border="0" />
</a>
</center>
<?php
// Stats for Google Analytics
if ($dns_name=="http://deltasql.sourceforge.net/deltasql") {
echo '
<script type="text/javascript">
var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
document.write(unescape("%3Cscript src=\'" + gaJsHost + "google-analytics.com/ga.js\' type=\'text/javascript\'%3E%3C/script%3E"));
</script>
<script type="text/javascript">
try{
var pageTracker = _gat._getTracker("UA-22222509-1");
pageTracker._trackPageview();
} catch(err) {}
</script>
';
}
?>
</td></tr></table>
</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.