r106328 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r106327‎ | r106328 | r106329 >
Date:14:34, 15 December 2011
Author:reedy
Status:ok
Tags:
Comment:
Add settings file
Modified paths:
  • /trunk/tools/rotatebot/login.php (modified) (history)
  • /trunk/tools/rotatebot/rotbot.php (modified) (history)
  • /trunk/tools/rotatebot/settings.php (added) (history)

Diff [purge]

Index: trunk/tools/rotatebot/rotbot.php
@@ -54,11 +54,11 @@
5555
5656
5757 logfile("Verbinde zur Datenbank!");
58 -include("/home/luxo/public_html/contributions/logindata.php");
59 -$myslink = mysql_connect($databanknames2, $userloginname, $databasepw) or suicide ("Can't connect to MySQL");
 58+include("settings.php");
 59+$myslink = mysql_connect($databanknames, $userloginname, $databasepw) or suicide ("Can't connect to MySQL");
6060 $database = "commonswiki_p";
6161 mysql_select_db($database, $myslink)
62 - or suicide ("Konnte $databas nicht öffnen: ".mysql_error());
 62+ or suicide ("Konnte $database nicht öffnen: ".mysql_error());
6363 //Datenbank verbunden
6464
6565 $wrongfiles = array();
@@ -609,7 +609,6 @@
610610 include("upload.php");
611611 include("login.php");
612612
613 -
614613 foreach($catcontent2 as $filename => $arraycontent)
615614 {
616615 //upload summary
@@ -762,7 +761,7 @@
763762 $logfilew .= "<br style=\"clear:both;\" clear=\"all\" />";
764763 }
765764
766 -if($somanyrot > 0 OR count($wrongfiles) > 0)
 765+if($somanyrot > 0 || count($wrongfiles) > 0)
767766 {
768767 logfile("write logfile. ($somanyrot pictures)");
769768
Index: trunk/tools/rotatebot/settings.php
@@ -0,0 +1,7 @@
 2+<?php
 3+
 4+$databanknames = "";
 5+
 6+$userloginname = "";
 7+$databasepw = "";
 8+
Property changes on: trunk/tools/rotatebot/settings.php
___________________________________________________________________
Added: svn:eol-style
19 + native
Index: trunk/tools/rotatebot/login.php
@@ -244,8 +244,6 @@
245245
246246 function wikilogin($username,$password,$project,$useragent)
247247 {
248 - global $cookies;
249 -
250248 $getrequest = (substr($project,-1) == "/") ? "w/api.php?action=login" : "/w/api.php?action=login";
251249 $project = (substr($project,0,7) == "http://") ? $project : "http://".$project;
252250

Status & tagging log