projects
/
brisk.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
mop_flush modify
[brisk.git]
/
web
/
index.php
diff --git
a/web/index.php
b/web/index.php
index
0aa8592
..
f3b8229
100644
(file)
--- a/
web/index.php
+++ b/
web/index.php
@@
-2,7
+2,7
@@
/*
* brisk - index.php
*
/*
* brisk - index.php
*
- * Copyright (C) 2006-20
09
Matteo Nastasi
+ * Copyright (C) 2006-20
11
Matteo Nastasi
* mailto: nastasi@alternativeoutput.it
* matteo.nastasi@milug.org
* web: http://www.alternativeoutput.it
* mailto: nastasi@alternativeoutput.it
* matteo.nastasi@milug.org
* web: http://www.alternativeoutput.it
@@
-20,10
+20,10
@@
* not, write to the Free Software Foundation, Inc, 59 Temple Place -
* Suite 330, Boston, MA 02111-1307, USA.
*
* not, write to the Free Software Foundation, Inc, 59 Temple Place -
* Suite 330, Boston, MA 02111-1307, USA.
*
- * $Id: index.php,v 1.33.2.28 2009-12-12 08:42:19 nastasi Exp $
- *
*/
*/
+$G_base = "";
+
require_once("Obj/brisk.phh");
require_once("Obj/auth.phh");
require_once("Obj/proxyscan.phh");
require_once("Obj/brisk.phh");
require_once("Obj/auth.phh");
require_once("Obj/proxyscan.phh");
@@
-236,9
+236,12
@@
function main()
if (isset($BRISK_SHOWHTML) == FALSE) {
$is_table = FALSE;
if (isset($BRISK_SHOWHTML) == FALSE) {
$is_table = FALSE;
- $sem = Room::lock_data();
+ $sem = Room::lock_data(
TRUE
);
log_main("lock Room");
log_main("lock Room");
- $room = &Room::load_data();
+ if (($room = Room::load_data()) == FALSE) {
+ log_crit("load_data failed");
+ exit();
+ }
$curtime = time();
/* Actions */
$curtime = time();
/* Actions */
@@
-280,7
+283,7
@@
function main()
$room->garbage_manager(TRUE);
/* try login */
$room->garbage_manager(TRUE);
/* try login */
- if (($user =
&
$room->add_user(&$sess, &$idx, $name, $pass_private, $_SERVER['REMOTE_ADDR'])) != FALSE) {
+ if (($user = $room->add_user(&$sess, &$idx, $name, $pass_private, $_SERVER['REMOTE_ADDR'])) != FALSE) {
$ACTION = "room";
if ($idx < 0) {
$idx = -$idx - 1;
$ACTION = "room";
if ($idx < 0) {
$idx = -$idx - 1;
@@
-307,10
+310,10
@@
function main()
// setcookie ("sess", "", time() + 180);
$room->standup_update(&$user);
// setcookie ("sess", "", time() + 180);
$room->standup_update(&$user);
-
if (Room::save_data(&
$room) == FALSE) {
- echo "ERRORE SALVATAGGIO\n";
- exit;
- }
+
if (Room::save_data(
$room) == FALSE) {
+
echo "ERRORE SALVATAGGIO\n";
+
exit;
+
}
}
else {
/* Login Rendering */
}
else {
/* Login Rendering */
@@
-459,10
+462,11
@@
function main()
/* MLANG: "briscola chiamata in salsa ajax", */
mt_srand(make_seed());
/* MLANG: "briscola chiamata in salsa ajax", */
mt_srand(make_seed());
- $rn = rand(0, 1);
-
- if ($rn == 0) {
- $banner_top_left = '<script type="text/javascript"><!--
+ if (!$G_is_local) {
+ $rn = rand(0, 1);
+
+ if ($rn == 0) {
+ $banner_top_left = '<script type="text/javascript"><!--
google_ad_client = "pub-5246925322544303";
google_ad_width = 234;
google_ad_height = 60;
google_ad_client = "pub-5246925322544303";
google_ad_width = 234;
google_ad_height = 60;
@@
-479,11
+483,11
@@
google_color_url = "000000";
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script>';
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script>';
- $banner_top_right = carousel_top();
- }
- else {
- $banner_top_left = carousel_top();
- $banner_top_right = '<script type="text/javascript"><!--
+
$banner_top_right = carousel_top();
+
}
+
else {
+
$banner_top_left = carousel_top();
+
$banner_top_right = '<script type="text/javascript"><!--
google_ad_client = "pub-5246925322544303";
google_ad_width = 234;
google_ad_height = 60;
google_ad_client = "pub-5246925322544303";
google_ad_width = 234;
google_ad_height = 60;
@@
-500,13
+504,18
@@
google_color_url = "000000";
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script>';
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script>';
+ }
+ }
+ else { // !$G_is_local
+ $banner_top_left = carousel_top();
+ $banner_top_right = carousel_top();
}
$brisk_header_form = '<div class="container">
<!-- =========== header =========== -->
<div id="header" class="header">
<table width="100%%" border="0" cols="3"><tr>
}
$brisk_header_form = '<div class="container">
<!-- =========== header =========== -->
<div id="header" class="header">
<table width="100%%" border="0" cols="3"><tr>
-<td align="left"><div style="padding-left: 8px;">'.
($G_is_local ? '' : $banner_top_left )
.'</div></td>
+<td align="left"><div style="padding-left: 8px;">'.
$banner_top_left
.'</div></td>
<td align="center">'.(($G_with_topbanner || $G_with_donors) ? '<table><tr><td>' : '').'<div style="text-align: center;">
<img class="nobo" src="img/brisk_logo64.png">
'.$mlang_room['headline'][$G_lang].'<br>
<td align="center">'.(($G_with_topbanner || $G_with_donors) ? '<table><tr><td>' : '').'<div style="text-align: center;">
<img class="nobo" src="img/brisk_logo64.png">
'.$mlang_room['headline'][$G_lang].'<br>
@@
-514,7
+523,7
@@
google_color_url = "000000";
($G_with_topbanner ? $G_topbanner :
"<div style='background-color: #ffd780; border: 1px solid black; text-align: center;'><img class='nobo' src=\"donometer.php?c=".$G_donors_cur."&a=".$G_donors_all."\"><div style='padding: 1px; background-color: white;'><b>donatori</b></div></div>") ) : '').'</td>
<td align="right"><div style="padding-right: 8px;">
($G_with_topbanner ? $G_topbanner :
"<div style='background-color: #ffd780; border: 1px solid black; text-align: center;'><img class='nobo' src=\"donometer.php?c=".$G_donors_cur."&a=".$G_donors_all."\"><div style='padding: 1px; background-color: white;'><b>donatori</b></div></div>") ) : '').'</td>
<td align="right"><div style="padding-right: 8px;">
-'.
($G_is_local ? '' : $banner_top_right )
.'</div></td>
+'.
$banner_top_right
.'</div></td>
</td></table>
</div>';
</td></table>
</div>';
@@
-525,7
+534,7
@@
google_color_url = "000000";
<!-- <a target="_blank" href="/briskhome.php"></a> -->
<div class="webstart_hilite">
<!-- <a target="_blank" href="/briskhome.php"></a> -->
<div class="webstart_hilite">
-<img class="nobo" src="img/brisk_start.png" onmouseover="menu_hide(0,0); menu_show(\'menu_webstart\');">
+<img class="nobo" s
tyle="cursor: pointer;" s
rc="img/brisk_start.png" onmouseover="menu_hide(0,0); menu_show(\'menu_webstart\');">
<div class="webstart" id="menu_webstart" onmouseover="menu_over(1,this);" onmouseout="menu_over(-1,this);">
<a href="#" onmouseover="menu_hide(0,1);" title="'.$mlang_room['tit_help'][$G_lang].'" onclick="act_help();"
<div class="webstart" id="menu_webstart" onmouseover="menu_over(1,this);" onmouseout="menu_over(-1,this);">
<a href="#" onmouseover="menu_hide(0,1);" title="'.$mlang_room['tit_help'][$G_lang].'" onclick="act_help();"
@@
-626,7
+635,7
@@
google_color_url = "000000";
title="Torneo di Milano del 17/05/2008" >Milano 05/08</a><br>
</div>
title="Torneo di Milano del 17/05/2008" >Milano 05/08</a><br>
</div>
-</div>'. ($ACTION == "room" ? '<div style="padding: 0px; margin: 0px; witdh: 50px; height: 8px; font-size: 1px;"></div><img class="nobo" src="img/brisk_commands'.langtolng($G_lang).'.png" onmouseover="menu_hide(0,0); menu_show(\'menu_commands\');">
+</div>'. ($ACTION == "room" ? '<div style="padding: 0px; margin: 0px; witdh: 50px; height: 8px; font-size: 1px;"></div><img class="nobo" s
tyle="cursor: pointer;" s
rc="img/brisk_commands'.langtolng($G_lang).'.png" onmouseover="menu_hide(0,0); menu_show(\'menu_commands\');">
<div class="webstart" id="menu_commands" onmouseover="menu_over(1,this);" onmouseout="menu_over(-1,this);">
<div class="webstart" id="menu_commands" onmouseover="menu_over(1,this);" onmouseout="menu_over(-1,this);">
@@
-716,6
+725,13
@@
google_color_url = "000000";
.$mlang_room['st_baby_desc'][$G_lang].
' <img class="unbo" src="img/st_baby.png"></a><br>
.$mlang_room['st_baby_desc'][$G_lang].
' <img class="unbo" src="img/st_baby.png"></a><br>
+<a href="#"
+ onmouseover="menu_hide(0,2);"
+ title="" onclick="act_chatt(\'/st pulizie\'); menu_over(-1,this);">'
+ // MLANG
+ .$mlang_room['st_mop_desc'][$G_lang].
+' <img class="unbo" src="img/st_mop.png"></a><br>
+
<!--
<a href="#"
onmouseover="menu_hide(0,2);"
<!--
<a href="#"
onmouseover="menu_hide(0,2);"