Permalink
Browse files

removed php end tags ?> to fix whitespace problem for some users

  • Loading branch information...
nimda562 nimda562
nimda562 authored and nimda562 committed Jul 16, 2013
1 parent 2a11e25 commit f1110752dc1fc55ff0696826f09ad1278dd67e07
Showing with 103 additions and 132 deletions.
  1. +0 −1 handler.php
  2. +0 −1 header.php
  3. +17 −17 index.php
  4. +42 −42 lib/class_arraytojs.php
  5. +1 −1 lib/class_coach.php
  6. +1 −1 lib/class_coach_htmlout.php
  7. +0 −1 lib/class_htmlout.php
  8. +24 −23 lib/class_image.php
  9. +1 −0 lib/class_league.php
  10. +0 −1 lib/class_match.php
  11. +0 −1 lib/class_match_htmlout.php
  12. +0 −1 lib/class_module.php
  13. +1 −1 lib/class_objevent.php
  14. +0 −1 lib/class_player.php
  15. +1 −1 lib/class_player_htmlout.php
  16. +1 −1 lib/class_race.php
  17. +0 −1 lib/class_race_htmlout.php
  18. +1 −1 lib/class_rrobin.php
  19. +0 −1 lib/class_sqlcore.php
  20. +0 −1 lib/class_sqltriggers.php
  21. +0 −1 lib/class_starmerc.php
  22. +1 −1 lib/class_starmerc_htmlout.php
  23. +0 −1 lib/class_stats.php
  24. +1 −1 lib/class_tablehandler.php
  25. +1 −1 lib/class_team.php
  26. +1 −0 lib/class_team_htmlout.php
  27. +0 −1 lib/class_text.php
  28. +0 −1 lib/class_tournament.php
  29. +1 −1 lib/class_translations.php
  30. +0 −1 lib/game_data.php
  31. +0 −1 lib/game_data_apesofwrath.php
  32. +0 −1 lib/game_data_brettonia.php
  33. +0 −1 lib/game_data_daemonsofkhorne.php
  34. +0 −1 lib/game_data_lrb6.php
  35. +0 −1 lib/game_data_lrb6x.php
  36. +0 −1 lib/misc_functions.php
  37. +0 −1 lib/mysql.php
  38. +1 −1 lib/mysql_upgrade_queries.php
  39. +0 −2 lib/settings_default.php
  40. +0 −1 lib/settings_modules_default.php
  41. +0 −1 localsettings/settings_1.php
  42. +0 −1 localsettings/settings_none.php
  43. +1 −1 modules/example/class_module_example.php
  44. +1 −1 modules/modsheader.php
  45. +1 −1 modules/pdf/bb_pdf_class.php
  46. +0 −1 modules/pdf/fpdf.php
  47. +0 −1 modules/pdf/pdf_roster.php
  48. +0 −1 modules/pdfmatchreport/class_pdfmatchreport.php
  49. +1 −1 modules/rss/class_rss.php
  50. +0 −1 modules/statsgraph/class_statsgraph.php
  51. +1 −1 modules/statsgraph/header.php
  52. +1 −1 sections.php
  53. +1 −1 settings.php
  54. +0 −1 settings_modules.php
View
@@ -258,4 +258,3 @@
mysql_close($conn);
?>
View
@@ -157,4 +157,3 @@
setupGlobalVars(T_SETUP_GLOBAL_VARS__POST_LOAD_MODULES);
}
?>
View
@@ -20,11 +20,11 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*
*/
$time_start = microtime(true); # Used by MTS().
/*
Includes, constants, error_reporting() level, session_start(), OBBLM run requirements, MySQL connection, language load.
$time_start = microtime(true); # Used by MTS().
/*
Includes, constants, error_reporting() level, session_start(), OBBLM run requirements, MySQL connection, language load.
*/
require('header.php');
@@ -37,7 +37,7 @@
$_GET['section'] = 'main';
}
// Login?
// Login?
$_VISSTATE['COOCKIE'] = Coach::cookieLogin(); # If not already logged in then check for login-cookie and try to log in using the stored credentials.
if ($_VISSTATE['POST_IN'] = isset($_POST['login'])) {
if (get_magic_quotes_gpc()) {
@@ -46,29 +46,29 @@
}
if (!Coach::login($_POST['coach'], $_POST['passwd'], isset($_POST['remember']))) {
$_GET['section'] = 'login';
}
}
}
// Logout?
if ($_VISSTATE['POST_OUT'] = isset($_GET['logout'])) {
$_GET['section'] = 'main'; # Redirect logged out users to the main page.
Coach::logout();
}
if ($_VISSTATE['COOCKIE'] || $_VISSTATE['POST_IN'] || $_VISSTATE['POST_OUT']) {
setupGlobalVars(T_SETUP_GLOBAL_VARS__POST_COACH_LOGINOUT);
Coach::logout();
}
HTMLOUT::frame_begin(isset($_SESSION['logged_in']) ? $coach->settings['theme'] : $settings['stylesheet']); # Make page frame, banner and menu.
if ($_VISSTATE['COOCKIE'] || $_VISSTATE['POST_IN'] || $_VISSTATE['POST_OUT']) {
setupGlobalVars(T_SETUP_GLOBAL_VARS__POST_COACH_LOGINOUT);
}
HTMLOUT::frame_begin(isset($_SESSION['logged_in']) ? $coach->settings['theme'] : $settings['stylesheet']); # Make page frame, banner and menu.
MTS('Header loaded, login auth, html frame generated');
// Check if a menu-link was picked, and execute section code from sections.php accordingly.
switch ($_GET['section'])
{
case 'login': sec_login(); break;
case 'admin': sec_admin(); break;
case 'teamlist': sec_teamlist(); break;
case 'coachlist': sec_coachlist(); break;
case 'teamlist': sec_teamlist(); break;
case 'coachlist': sec_coachlist(); break;
case 'rules': sec_rules(); break;
case 'about': sec_about(); break;
case 'matches': sec_matcheshandler(); break; // Tournaments, matches, match reports, recent matches, upcoming matches etc.
@@ -79,4 +79,4 @@
HTMLOUT::frame_end(); // Spit out all the end-tags.
mysql_close($conn);
MTS('END OF SCRIPT');
?>
View
@@ -4,45 +4,45 @@
* By Jan Paepke @ http://www.phpclasses.org/browse/package/3365.html.
* Released under GPL.
*/
class array_to_js {
var $js_arrays;
function error ($message, $stop = true) {
echo "<b>array_to_js</b> - FATAL ERROR: ".$message;
if ($stop) exit;
}
function add_array($myarray, $outputvarname, $level = 0) {
if (isset($this->js_arrays[$outputvarname]))
$this->error('This Array has been added more than once: "'.$outputvarname.'"');
for ($i=0; $i<$level; $i++) $pre .= ' ';
$this->js_arrays[$outputvarname] .= $pre.$outputvarname.' = new Object();'."\n";
foreach ($myarray as $key => $value) {
if (!is_int($key))
$key = '"'.addslashes($key).'"';
if (is_array($value))
$this->add_array($value, $outputvarname.'['.$key.']', $level+1);
else {
$this->js_arrays[$outputvarname] .= $pre.' '.$outputvarname.'['.$key.']'.' = ';
if (is_int($value) or is_float($value))
$this->js_arrays[$outputvarname] .= $value;
elseif (is_bool($value))
$this->js_arrays[$outputvarname] .= $value ? "true" : "false";
elseif (is_string($value))
$this->js_arrays[$outputvarname] .= '"'.addslashes($value).'"';
else
$this->error('Unknown Datatype for "'.$outputvarname.'['.$key.']"');
$this->js_arrays[$outputvarname] .= ";\n";
}
}
}
function output_all($scripttag = true) {
if ($scripttag) $outputstring = '<script language="JavaScript" type="text/javascript">'."\n";
foreach ($this->js_arrays as $array)
$outputstring .= $array;
if ($scripttag) $outputstring .= '</script>'."\n";
return $outputstring;
}
}
?>
class array_to_js {
var $js_arrays;
function error ($message, $stop = true) {
echo "<b>array_to_js</b> - FATAL ERROR: ".$message;
if ($stop) exit;
}
function add_array($myarray, $outputvarname, $level = 0) {
if (isset($this->js_arrays[$outputvarname]))
$this->error('This Array has been added more than once: "'.$outputvarname.'"');
for ($i=0; $i<$level; $i++) $pre .= ' ';
$this->js_arrays[$outputvarname] .= $pre.$outputvarname.' = new Object();'."\n";
foreach ($myarray as $key => $value) {
if (!is_int($key))
$key = '"'.addslashes($key).'"';
if (is_array($value))
$this->add_array($value, $outputvarname.'['.$key.']', $level+1);
else {
$this->js_arrays[$outputvarname] .= $pre.' '.$outputvarname.'['.$key.']'.' = ';
if (is_int($value) or is_float($value))
$this->js_arrays[$outputvarname] .= $value;
elseif (is_bool($value))
$this->js_arrays[$outputvarname] .= $value ? "true" : "false";
elseif (is_string($value))
$this->js_arrays[$outputvarname] .= '"'.addslashes($value).'"';
else
$this->error('Unknown Datatype for "'.$outputvarname.'['.$key.']"');
$this->js_arrays[$outputvarname] .= ";\n";
}
}
}
function output_all($scripttag = true) {
if ($scripttag) $outputstring = '<script language="JavaScript" type="text/javascript">'."\n";
foreach ($this->js_arrays as $array)
$outputstring .= $array;
if ($scripttag) $outputstring .= '</script>'."\n";
return $outputstring;
}
}
View
@@ -561,4 +561,4 @@ public static function create(array $input) {
return $status ? $cid : false;
}
}
?>
@@ -564,4 +564,4 @@ private function _recentGames()
}
}
?>
View
@@ -1332,4 +1332,3 @@ public static function dnt()
}
?>
View
@@ -114,15 +114,15 @@ public function save($file_name = false)
}
// Create parent dir if non existing.
if (!is_dir(self::$typeToPathMappings[$this->obj])) {
mkdir(self::$typeToPathMappings[$this->obj]);
if (!is_dir(self::$typeToPathMappings[$this->obj])) {
mkdir(self::$typeToPathMappings[$this->obj]);
}
// Delete all other possible existing files.
// Delete all other possible existing files.
foreach (self::$supportedExtensions as $mimeType => $exts) {
foreach ($exts as $ext) {
@unlink(self::$typeToPathMappings[$this->obj].'/'.$this->obj_id.'.'.$ext);
}
foreach ($exts as $ext) {
@unlink(self::$typeToPathMappings[$this->obj].'/'.$this->obj_id.'.'.$ext);
}
}
// Move file away from temp location.
@@ -139,34 +139,35 @@ public function delete()
return true;
}
@unlink($fpath);
return true;
return true;
}
public static function makeBox($obj, $obj_id, $showUploadForm = false, $suffix = false)
{
global $lng;
global $lng;
// Prints a nice picture box.
$height = $width = 250; # Picture dimensions.
$img = new self($obj, $obj_id);
?>
<img alt="Image" height="<?php echo $height;?>" width="<?php echo $width;?>" src="<?php echo $img->getPath()?>">
<br><br>
<?php
if ($showUploadForm) {
?>
<form method='POST' enctype="multipart/form-data">
?>
<img alt="Image" height="<?php echo $height;?>" width="<?php echo $width;?>" src="<?php echo $img->getPath()?>">
<br><br>
<?php
if ($showUploadForm) {
?>
<form method='POST' enctype="multipart/form-data">
<input type="hidden" name="type" value="pic">
<input type="hidden" name="add_del" id="_pic_add_del__<?php echo (($suffix) ? $suffix : '');?>" value="add">
<input type="hidden" name="pic_obj" value="<?php echo $obj;?>">
<?php echo $lng->getTrn('common/uploadnew');?> (<?php echo "${width}x${height}";?>): <br>
<input name="<?php echo self::$defaultHTMLUploadName.(($suffix) ? $suffix : '')?>" type="file"><br>
<input type="hidden" name="pic_obj" value="<?php echo $obj;?>">
<?php echo $lng->getTrn('common/uploadnew');?> (<?php echo "${width}x${height}";?>): <br>
<input name="<?php echo self::$defaultHTMLUploadName.(($suffix) ? $suffix : '')?>" type="file"><br>
<input type="submit" name="pic_upload" value="<?php echo $lng->getTrn('common/upload');?>">
|
<input type="submit" name="pic_delete" value="<?php echo $lng->getTrn('common/delete');?>" onClick="document.getElementById('_pic_add_del__<?php echo (($suffix) ? $suffix : '');?>').value='del';">
</form>
<?php
}
}
<input type="submit" name="pic_delete" value="<?php echo $lng->getTrn('common/delete');?>" onClick="document.getElementById('_pic_add_del__<?php echo (($suffix) ? $suffix : '');?>').value='del';">
</form>
<?php
}
}
}
View
@@ -117,3 +117,4 @@ public function getUrl() {
return getLeagueUrl($this->lid, $this->name);
}
}
View
@@ -631,4 +631,3 @@ public static function create(array $input) {
}
}
?>
@@ -1028,4 +1028,3 @@ public static function userSched() {
}
?>
View
@@ -170,4 +170,3 @@ public static function isTriggerRegistered($name)
Module::registerTrigger($name);
}
?>
View
@@ -79,4 +79,4 @@ public static function getRecentEvents($event, $node, $node_id, $N)
return $events;
}
}
?>
View
@@ -865,4 +865,3 @@ public static function create(array $input, array $opts) {
}
}
?>
@@ -525,4 +525,4 @@ private function _ES()
}
}
?>
View
@@ -78,4 +78,4 @@ public static function exists($id)
}
}
?>
@@ -84,4 +84,3 @@ public static function standings()
}
?>
View
@@ -94,4 +94,4 @@ private function rotate() {
$this->rot_out = array_shift($this->lower);
}
}
?>
View
@@ -1393,4 +1393,3 @@ public static function reviseEStables()
}
?>
@@ -142,4 +142,3 @@ protected static function _match($T_SQLTRIG, array $argv)
}
}
?>
View
@@ -259,4 +259,3 @@ public static function getMercsHiredByTeam($team_id, $f_match_id = false)
}
}
?>
@@ -119,4 +119,4 @@ public static function starHireHistory($obj, $obj_id, $node, $node_id, $star_id
}
}
?>
View
@@ -345,4 +345,3 @@ private static function buildCrossRefQueryComponents($obj, $obj_id, $node, $node
}
?>
@@ -38,4 +38,4 @@ public static function createTableIfNotExists($name, $tblStruct) {
return mysql_query($query);
}
}
?>
View
@@ -588,4 +588,4 @@ public static function create(array $input) {
return array(self::T_CREATE_SUCCESS, $tid);
}
}
?>
@@ -1797,3 +1797,4 @@ private function _games()
}
}
View
@@ -413,4 +413,3 @@ public static function getNews($tid = false, $n = false, $lid = false)
}
}
?>
View
@@ -331,4 +331,3 @@ public function getUrl() {
}
?>
@@ -65,4 +65,4 @@ public function getTrn($key, $doc = false) {
}
}
?>
View
@@ -2094,4 +2094,3 @@
$rules['value_reduction_ag'] = 0; // Default is 0.
$rules['value_reduction_st'] = 0; // Default is 0.
?>
@@ -98,4 +98,3 @@
)
);
?>
@@ -79,4 +79,3 @@
array_push($stars[$s]['races'], T_RACE_BRETTONIA);
}
?>
@@ -88,4 +88,3 @@
array_push($stars['Grashnak Blackhoof']['races'], T_RACE_DKHORNE);
array_push($stars['Morg \'n\' Thorg']['races'], T_RACE_DKHORNE);
?>
View
@@ -49,4 +49,3 @@
$inducements['Halfling Master Chef']['reduced_cost'] = 100000; # Old LRB5 value.
?>
Oops, something went wrong.

0 comments on commit f111075

Please sign in to comment.