Author: frik85
Date: Sun Sep 23 17:04:13 2007
New Revision: 29157
URL:
http://svn.reactos.org/svn/reactos?rev=29157&view=rev
Log:
RosCMS update:
* automatic page generation fixed
* user page got several new search options
* maintain page improved
Modified:
trunk/web/reactos.org/htdocs/roscms/inc/data_edit.php
trunk/web/reactos.org/htdocs/roscms/inc/data_export_page.php
trunk/web/reactos.org/htdocs/roscms/inc/data_maintain.php
trunk/web/reactos.org/htdocs/roscms/inc/data_user.php
trunk/web/reactos.org/htdocs/roscms/inc/data_user_out.php
Modified:
trunk/web/reactos.org/htdocs/roscms/inc/data_edit.php
URL:
http://svn.reactos.org/svn/reactos/trunk/web/reactos.org/htdocs/roscms/inc/…
==============================================================================
---
trunk/web/reactos.org/htdocs/roscms/inc/data_edit.php (original)
+++
trunk/web/reactos.org/htdocs/roscms/inc/data_edit.php Sun Sep 23 17:04:13 2007
@@ -1401,7 +1401,7 @@
if ($RosCMS_GET_debug) echo "<p>!
generate_page_output_update(".$result_rev_data['data_id'].",
".$tmp_lang.", ".$temp_dynamic.")</p>";
- //echo generate_page_output_update($result_entry['data_id'], $tmp_lang,
$temp_dynamic);
+ echo generate_page_output_update($result_entry['data_id'], $tmp_lang,
$temp_dynamic);
echo "Page generation process finished";
}
else {
Modified:
trunk/web/reactos.org/htdocs/roscms/inc/data_export_page.php
URL:
http://svn.reactos.org/svn/reactos/trunk/web/reactos.org/htdocs/roscms/inc/…
==============================================================================
---
trunk/web/reactos.org/htdocs/roscms/inc/data_export_page.php (original)
+++
trunk/web/reactos.org/htdocs/roscms/inc/data_export_page.php Sun Sep 23 17:04:13 2007
@@ -281,7 +281,7 @@
$fp = fopen($RosCMS_current_page_out_file, "w");
flock($fp,2);
fputs($fp,$RosCMS_current_page_content); // write content
- fputs($fp,"\n\n<!-- Generated with ".$roscms_extern_brand."
".$roscms_extern_version." (".$roscms_extern_version_detail.") -
".date("Y-m-d H:i:s")." [#RosCMS_v3] -->");
+ fputs($fp,"\n\n<!-- Generated with ".$roscms_extern_brand."
".$roscms_extern_version." (".$roscms_extern_version_detail.") -
".date("Y-m-d H:i:s")." [RosCMS_v3] -->");
flock($fp,3);
fclose($fp);
Modified:
trunk/web/reactos.org/htdocs/roscms/inc/data_maintain.php
URL:
http://svn.reactos.org/svn/reactos/trunk/web/reactos.org/htdocs/roscms/inc/…
==============================================================================
---
trunk/web/reactos.org/htdocs/roscms/inc/data_maintain.php (original)
+++
trunk/web/reactos.org/htdocs/roscms/inc/data_maintain.php Sun Sep 23 17:04:13 2007
@@ -64,7 +64,6 @@
?>
<p><a href="javascript:optimizedb()">Optimize Database
Tables</a></p>
- <p><a href="javascript:analyzedb()">Analyze Database
Tables</a></p>
<p> </p>
<p><a href="javascript:ppreview()">Page
Preview</a></p>
<div><label for="textfield">Entry-Name:</label> <input
name="textfield" type="text" id="textfield"
size="20" maxlength="100" />
@@ -174,7 +173,9 @@
function makeRequest(url, action, objid) {
var http_request = false;
+
document.getElementById('ajaxloading').style.display = 'block';
+ document.getElementById(objid).innerHTML = '';
if (window.XMLHttpRequest) { // Mozilla, Safari,...
Modified:
trunk/web/reactos.org/htdocs/roscms/inc/data_user.php
URL:
http://svn.reactos.org/svn/reactos/trunk/web/reactos.org/htdocs/roscms/inc/…
==============================================================================
---
trunk/web/reactos.org/htdocs/roscms/inc/data_user.php (original)
+++
trunk/web/reactos.org/htdocs/roscms/inc/data_user.php Sun Sep 23 17:04:13 2007
@@ -52,14 +52,26 @@
}
if (roscms_security_grp_member("transmaint")
||roscms_security_grp_member("ros_admin") ||
roscms_security_grp_member("ros_sadmin")) {
-
- echo '<div><label for="textfield">Username:
</label><input type="text" name="textfield"
id="textfield" onkeyup="getuser(this.value)" /> <img
id="ajaxloading" style="display:none;"
src="images/ajax_loading.gif" width="13" height="13"
/></div>';
- echo '<div id="userarea"></div>';
+?>
+<div><label for="textfield">Username: </label><input
type="text" name="textfield" id="textfield"
onkeyup="getuser()" /> <br />
+ <input name="searchopt" type="radio" id="searchopt1"
value="accountname" checked="checked" onclick="getuser()"
/>
+ <label>account name</label>
+ <input name="searchopt" type="radio" id="searchopt2"
value="fullname" onclick="getuser()" />
+ <label>full name </label>
+ <input name="searchopt" type="radio" id="searchopt3"
value="email" onclick="getuser()" />
+ <label>email address</label>
+ <input name="searchopt" type="radio" id="searchopt4"
value="website" onclick="getuser()" />
+ <label>website</label>
+ <input name="searchopt" type="radio" id="searchopt5"
value="language" onclick="getuser()" />
+ <label>language</label>
+ <img id="ajaxloading" style="display:none;"
src="images/ajax_loading.gif" width="13" height="13"
/><br /><br />
+</div>
+<div id="userarea"></div>
- echo "<br />";
- echo "<br />";
+<br />
+<br />
-
+<?php
echo "<h4>Translators</h4>";
echo "<ul>";
@@ -80,16 +92,24 @@
echo "<br />";
+/*
if (roscms_security_grp_member("transmaint")) {
echo get_content("log_website_en_2007-30", "system",
"en", "content", "text", "archive");
}
+*/
}
?>
<script type="text/javascript" language="javascript">
<!--
- function getuser(username) {
- makeRequest('?page=data_out&d_f=user&d_u=usrtbl&d_fl=list&d_val='+encodeURIComponent(username),
'usrtbl', 'userarea');
+ function getuser() {
+ var soptckd = '';
+ if (document.getElementById('searchopt1').checked) soptckd =
'accountname';
+ if (document.getElementById('searchopt2').checked) soptckd =
'fullname';
+ if (document.getElementById('searchopt3').checked) soptckd =
'email';
+ if (document.getElementById('searchopt4').checked) soptckd =
'website';
+ if (document.getElementById('searchopt5').checked) soptckd =
'language';
+ makeRequest('?page=data_out&d_f=user&d_u=usrtbl&d_fl=list&d_val='+encodeURIComponent(document.getElementById('textfield').value)+'&d_val2='+encodeURIComponent(soptckd),
'usrtbl', 'userarea');
}
function getuserdetails(userid) {
Modified:
trunk/web/reactos.org/htdocs/roscms/inc/data_user_out.php
URL:
http://svn.reactos.org/svn/reactos/trunk/web/reactos.org/htdocs/roscms/inc/…
==============================================================================
---
trunk/web/reactos.org/htdocs/roscms/inc/data_user_out.php (original)
+++
trunk/web/reactos.org/htdocs/roscms/inc/data_user_out.php Sun Sep 23 17:04:13 2007
@@ -86,14 +86,36 @@
}
if ($RosCMS_GET_d_flag == "list") {
- echo "<fieldset><legend>Results</legend>";
if (strlen($RosCMS_GET_d_value) > 2) {
+ echo "<fieldset><legend>Results</legend>";
echo "<ul>";
$tmp_counter = 0;
+
+ switch ($RosCMS_GET_d_value2) {
+ default:
+ case "accountname":
+ $tmp_sql_search_opt = "u.user_name";
+ break;
+ case "fullname":
+ $tmp_sql_search_opt = "u.user_fullname";
+ break;
+ case "email":
+ $tmp_sql_search_opt = "u.user_email";
+ break;
+ case "website":
+ $tmp_sql_search_opt = "u.user_website";
+ break;
+ case "language":
+ $tmp_sql_search_opt = "u.user_language";
+ break;
+ }
+
+ echo "<p>OPT: ".$RosCMS_GET_d_value2."</p>";
+
$query_user_list = mysql_query("SELECT u.user_id, u.user_name, u.user_fullname,
u.user_language
FROM users u
- WHERE u.user_name LIKE
'".mysql_real_escape_string($RosCMS_GET_d_value)."%'
+ WHERE ". $tmp_sql_search_opt ." LIKE
'".mysql_real_escape_string($RosCMS_GET_d_value)."%'
ORDER BY u.user_name ASC
LIMIT 25;");
while ($result_user_list = mysql_fetch_array($query_user_list)) {
@@ -106,11 +128,12 @@
if ($tmp_counter >= 25) {
echo "<p>... more than 25 users</p>";
}
+
+ echo "</fieldset><br />";
}
else if (strlen($RosCMS_GET_d_value) > 0) {
echo "<p>more than 2 characters requiered</p>";
}
- echo "</fieldset><br />";
}
else if ($RosCMS_GET_d_flag == "detail") {
$query_user_detail = mysql_query("SELECT user_id, user_name,
user_timestamp_touch2 as 'visit', user_login_counter 'visitcount',
user_register, user_fullname, user_email, user_language