merged with live
This commit is contained in:
commit
ed12767de0
3 files changed
+44
No files matched your search
+12
@@ -0,0 +1,12 @@
|
||||
<?php
|
||||
|
||||
require '../inside/credentials-sample.php';
|
||||
|
||||
$str = getDSN();
|
||||
|
||||
preg_match('|([^:]+)://([^:]+):([^@]+)@([^/]+)/(.+)|', $str, $output);
|
||||
|
||||
list($str, $driver, $user_name, $password, $host_name, $db_name) = $output;
|
||||
|
||||
if(!mysql_connect($host_name, $user_name, $password)) die("error connecting to db");
|
||||
if(!mysql_select_db($db_name)) die('error selecting databse');
|
||||
@@ -0,0 +1,31 @@
|
||||
<?php
|
||||
|
||||
require 'db.php';
|
||||
|
||||
|
||||
$res = mysql_query("SELECT * FROM `din_division` WHERE `updated` IS NULL or `updated` + INTERVAL 90 DAY < now()");
|
||||
|
||||
while($row = mysql_fetch_assoc($res))
|
||||
{
|
||||
$time = strtotime($row['updated']);
|
||||
$diff = $time - time();
|
||||
$diff /= 60 * 60 * 24;
|
||||
$diff = round($diff);
|
||||
var_dump($row);
|
||||
if($diff == 0)
|
||||
{
|
||||
|
||||
}
|
||||
else if($diff == 7)
|
||||
{
|
||||
|
||||
}
|
||||
else if($diff == 14)
|
||||
{
|
||||
|
||||
}
|
||||
else if($diff == 21)
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
@@ -764,6 +764,7 @@ private function logError($username, $error)
|
||||
}
|
||||
|
||||
public function _deleteEvent() {
|
||||
die('<html><body>Sletting av eventer er midlertidig avskrudd. Ta kontakt med komans@studentersamfundet.no eller edb@studentersamfundet.no for å få slettet ting.</body></html>');
|
||||
Event :: delete(scriptParam("eventid"));
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user