Major cleanups

* Structures static file locations
* Moves index.php to /
* Updates paths all over
* Hides menu items of unused features
* Hides menu items of legacy features
* Adds README
This commit is contained in:
nikolark committed 2012-04-20 23:45:21 +02:00
1 parent 408bcb1859
commit 52cc657538
102 files changed
+167 -91

No files matched your search

+2 -2
View File
@@ -1,8 +1,8 @@
credentials.php
inside/credentials.php
inside/tmp
.htaccess
inside/migration/config.php
migration.log
error_log
*.swp
.htaccess
payex_defines.php
+11
View File
@@ -0,0 +1,11 @@
== Konfigurasjon ==
Du må endre instillinger for database, migrering (key og server) og payex betaling.
$ cp inside/credentials-sample php inside/credentials.php
$ cp inside/migration/config.example php inside/migration/config.php
$ cp includes/payex2/payex_defines.example.php includes/payex2/payex_defines.php
Du trenger kanskje å endre ting i includes/Ldap_defines.php også.
== Installasjon ==
Legg inn Apache, MySQL og PHP. Du trenger også noen utvidelser til PHP.
$ sudo apt-get install php5-mysql php5-ldap
File renamed without changes.
File renamed without changes.

Before

Width:  |  Height:  |  Size: 180 B

After

Width:  |  Height:  |  Size: 180 B

File renamed without changes.

Before

Width:  |  Height:  |  Size: 178 B

After

Width:  |  Height:  |  Size: 178 B

File renamed without changes.

Before

Width:  |  Height:  |  Size: 120 B

After

Width:  |  Height:  |  Size: 120 B

File renamed without changes.

Before

Width:  |  Height:  |  Size: 105 B

After

Width:  |  Height:  |  Size: 105 B

File renamed without changes.

Before

Width:  |  Height:  |  Size: 111 B

After

Width:  |  Height:  |  Size: 111 B

File renamed without changes.

Before

Width:  |  Height:  |  Size: 110 B

After

Width:  |  Height:  |  Size: 110 B

File renamed without changes.

Before

Width:  |  Height:  |  Size: 119 B

After

Width:  |  Height:  |  Size: 119 B

File renamed without changes.

Before

Width:  |  Height:  |  Size: 101 B

After

Width:  |  Height:  |  Size: 101 B

File renamed without changes.

Before

Width:  |  Height:  |  Size: 5.2 KiB

After

Width:  |  Height:  |  Size: 5.2 KiB

File renamed without changes.

Before

Width:  |  Height:  |  Size: 4.3 KiB

After

Width:  |  Height:  |  Size: 4.3 KiB

File renamed without changes.

Before

Width:  |  Height:  |  Size: 4.3 KiB

After

Width:  |  Height:  |  Size: 4.3 KiB

File renamed without changes.

Before

Width:  |  Height:  |  Size: 4.3 KiB

After

Width:  |  Height:  |  Size: 4.3 KiB

File renamed without changes.

Before

Width:  |  Height:  |  Size: 4.3 KiB

After

Width:  |  Height:  |  Size: 4.3 KiB

+3 -3
View File
@@ -107,7 +107,7 @@ a.skip-nav {
}
a.contact {
background: url("../inside/graphics/user_go.png") no-repeat right;
background: url("../user_go.png") no-repeat right;
padding-right: 20px;
}
/* =lists
@@ -406,7 +406,7 @@ h4 {
}
li.menulist {
background: url(../inside/graphics/minus.png) no-repeat 3px 0.3em;
background: url(../graphics/minus.png) no-repeat 3px 0.3em;
line-height: 1.2em;
list-style: none outside;
margin: 0px 0 10px;
@@ -415,7 +415,7 @@ li.menulist {
}
.jsenabled li.menulist {
background: url(../inside/graphics/plus.png) no-repeat 3px 0.3em;
background: url(../graphics/plus.png) no-repeat 3px 0.3em;
}
.jsenabled .menu, .jsenabled .submenu {
+2 -2
View File
@@ -80,7 +80,7 @@ body.dns {
}
/*body.dns */
#header {
background:#191919 url('../inside/graphics/header-210x.png') repeat-x bottom;
background:#191919 url('../graphics/header-210x.png') repeat-x bottom;
}
#header {
height:110px;
@@ -92,7 +92,7 @@ body.dns {
z-index:999
}
.site-title a {
background: url('../inside/graphics/bannerindex-400.png') no-repeat -20px 0;
background: url('../graphics/bannerindex-400.png') no-repeat -20px 0;
display:block;
height:63px;
margin-top:20px;
File renamed without changes.

Before

Width:  |  Height:  |  Size: 22 KiB

After

Width:  |  Height:  |  Size: 22 KiB

File renamed without changes.

Before

Width:  |  Height:  |  Size: 185 B

After

Width:  |  Height:  |  Size: 185 B

File renamed without changes.

Before

Width:  |  Height:  |  Size: 788 B

After

Width:  |  Height:  |  Size: 788 B

File renamed without changes.

Before

Width:  |  Height:  |  Size: 655 B

After

Width:  |  Height:  |  Size: 655 B

File renamed without changes.

Before

Width:  |  Height:  |  Size: 901 B

After

Width:  |  Height:  |  Size: 901 B

File renamed without changes.

Before

Width:  |  Height:  |  Size: 601 B

After

Width:  |  Height:  |  Size: 601 B

File renamed without changes.

Before

Width:  |  Height:  |  Size: 984 B

After

Width:  |  Height:  |  Size: 984 B

File renamed without changes.

Before

Width:  |  Height:  |  Size: 2.5 KiB

After

Width:  |  Height:  |  Size: 2.5 KiB

File renamed without changes.

Before

Width:  |  Height:  |  Size: 174 B

After

Width:  |  Height:  |  Size: 174 B

File renamed without changes.

Before

Width:  |  Height:  |  Size: 1.6 KiB

After

Width:  |  Height:  |  Size: 1.6 KiB

File renamed without changes.

Before

Width:  |  Height:  |  Size: 177 B

After

Width:  |  Height:  |  Size: 177 B

File renamed without changes.

Before

Width:  |  Height:  |  Size: 269 B

After

Width:  |  Height:  |  Size: 269 B

File renamed without changes.

Before

Width:  |  Height:  |  Size: 537 B

After

Width:  |  Height:  |  Size: 537 B

File renamed without changes.

Before

Width:  |  Height:  |  Size: 915 B

After

Width:  |  Height:  |  Size: 915 B

+1
View File
@@ -39,6 +39,7 @@ define("RADIUS_MYSQL_HOST", "snes.neuf.no");
define("RADIUS_MYSQL_USER", apache_getenv("RADIUS_MYSQL_USER"));
define("RADIUS_MYSQL_PASS", apache_getenv("RADIUS_MYSQL_PASS"));
define("LDAP_ENABLED", false);
define("LDAP_SERVER", "macgyver.neuf.no");
$api_keys = array();
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
+68
View File
@@ -0,0 +1,68 @@
<?php
error_reporting(0);
define('PAYEX_CLIENTTYPE_NOTHING', 0);
define('PAYEX_CLIENTTYPE_ACCOUNT', 1);
define('PAYEX_CLIENTTYPE_EMAIL', 2);
define('PAYEX_CLIENTTYPE_GSM', 3);
define('PAYEX_CLIENTTYPE_EXTERNALREF', 4);
define('PAYEX_CLIENTINFO_CLIENTACCOUNT', 1);
define('PAYEX_CLIENTINFO_EMAIL', 2);
define('PAYEX_CLIENTINFO_GSM', 4);
define('PAYEX_CLIENTINFO_USERNAME', 8);
define('PAYEX_CLIENTINFO_ADDRESS', 16);
define('PAYEX_CLIENTINFO_BALANCE_CLIENT', 32);
define('PAYEX_CLIENTINFO_BALANCE_MERCHANT', 64);
define('PAYEX_USERTYPE_NOTHING', 0);
define('PAYEX_USERTYPE_ACCOUNT', 1);
define('PAYEX_USERTYPE_EMAIL', 2);
define('PAYEX_USERTYPE_GSM', 3);
define('PAYEX_USERTYPE_EXTERNALREF', 4);
define('PAYEX_EXPIREDATETYPE_DISABLED', 0);
define('PAYEX_EXPIREDATETYPE_PERIODS', 1);
define('PAYEX_EXPIREDATETYPE_DATE', 2);
define('PAYEX_EXPIREDATETYPE_SECONDS', 3);
define('PAYEX_TRANSACTIONSTATUS_SALE', 0);
define('PAYEX_TRANSACTIONSTATUS_INITIALIZE', 1);
define('PAYEX_TRANSACTIONSTATUS_CREDIT', 2);
define('PAYEX_TRANSACTIONSTATUS_AUTHORIZE', 3);
define('PAYEX_TRANSACTIONSTATUS_CANCEL', 4);
define('PAYEX_TRANSACTIONSTATUS_FAILURE', 5);
define('PAYEX_TRANSACTIONSTATUS_CAPTURE', 6);
define('PAYEX_SUBSCRIPTIONSTATUS_ACTIVE_RENEWABLE', 0);
define('PAYEX_SUBSCRIPTIONSTATUS_ACTIVE_NOTRENEWABLE', 1);
define('PAYEX_SUBSCRIPTIONSTATUS_NOTACTIVE_RENEWABLE', 2);
define('PAYEX_SUBSCRIPTIONSTATUS_STOPPED', 3);
define('PAYEX_SUBSCRIPTIONSTATUS_CANCELLED', 4);
define('PAYEX_SUBSCRIPTIONSTATUS_NOTACTIVE_NOTRENEWABLE', 5);
define('PAYEX_SUBSCRIPTIONSTATUS_NOTACTIVE_STOPPED', 6);
define('PAYEX_SUBSCRIPTIONSTATUS_NOTACTIVE_EXPIRED', 7);
define('PAYEX_CREATEDSTATUS_ERROR', 0);
define('PAYEX_CREATEDSTATUS_ALREADYEXISTS', 1);
define('PAYEX_CREATEDSTATUS_SUCCESS', 2);
define('PAYEX_ORDERSTATUS_COMPLETED', 0);
define('PAYEX_ORDERSTATUS_PROCESSING', 1);
define('PAYEX_ORDERSTATUS_NOTFOUND', 2);
//From setupexample
define("PAYEX_PXPARTNER_WSDL", 'https://external.payex.com/pxorder/pxpartner.asmx?WSDL');
define('PAYEX_PXPRINT_WSDL', 'https://external.payex.com/pxorder/pxprint.asmx?WSDL');
define('PAYEX_PXDEPOSIT_WSDL', 'https://external.payex.com/pxorder/pxdeposit.asmx?WSDL');
define('PAYEX_PXACCOUNT_WSDL', 'https://external.payex.com/pxorder/pxaccount.asmx?WSDL');
define('PAYEX_PXORDER_WSDL', 'https://external.payex.com/pxorder/pxorder.asmx?WSDL');
define('PAYEX_PXCLIENT_WSDL', 'https://external.payex.com/pxclient/pxclient.asmx?WSDL');
define('PAYEX_PXMERCHANT_WSDL', 'https://external.payex.com/pxmerchant/pxmerchant.asmx?WSDL');
define('PAYEX_PXSUBSCRIPTION_WSDL', 'https://external.payex.com/pxsubscription/pxsubscription.asmx?WSDL');
define('PAYEX_PXAGREEMENT_WSDL', 'https://external.payex.com/pxagreement/pxagreement.asmx?WSDL');
define('PAYEX_PXORDER_URL', 'https://account.payex.com/pxorder.asp'); // url to redirect user to
define('PAYEX_ACCOUNTNUMBER', 0); // payex merchant account number
define('PAYEX_ENCRYPTIONKEY', ''); // payex encryption key
?>
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
View File
File renamed without changes.
+13
View File
@@ -0,0 +1,13 @@
<?php
$time_start = microtime(true);
require_once "./inside/includes.php";
$ap = new ActionParser();
$ap->performAction();
$p = new Page();
$p->display();
?>
+3 -3
View File
@@ -64,7 +64,7 @@ class Documents {
<?php
while ($row =& $result->fetchRow(DB_FETCHMODE_OBJECT)){?>
<tr>
<td><a href="file.php?id=<?php print $row->id; ?>"><?php print $row->name; ?></a></td>
<td><a href="inside/file.php?id=<?php print $row->id; ?>"><?php print $row->name; ?></a></td>
<td><?php print $row->category; ?></td>
<td><?php print $this->_tags_to_links($row->tags); ?></td>
<td><?php print formatDate($row->date, "td"); ?></td>
@@ -113,7 +113,7 @@ class Documents {
<?php
while ($row =& $result->fetchRow(DB_FETCHMODE_OBJECT)){?>
<tr>
<td><a href="file.php?id=<?php print $row->id; ?>"><?php print $row->name; ?></a></td>
<td><a href="inside/file.php?id=<?php print $row->id; ?>"><?php print $row->name; ?></a></td>
<td><?php print $row->category; ?></td>
<td><?php print $this->_tags_to_links($row->tags); ?></td>
<td><?php print formatDate($row->date, "td"); ?></td>
@@ -146,4 +146,4 @@ class Documents {
}
?>
?>
+22 -27
View File
@@ -26,7 +26,8 @@ class Navigation {
</li>
<?php }?>
<?php
if(checkAuth("view-menu-messages")){
/* Note: This menu item is hidden because the feature is not used anymore */
/*if(checkAuth("view-menu-messages")){
?>
<li class="menulist">
<a href="#" id="messagesSwitch" class="switch">Meldinger</a>
@@ -36,7 +37,7 @@ class Navigation {
<li>Ny melding</li>
</ul>
</li>
<?php }?>
<?php }*/?>
<?php
if(checkAuth("view-menu-jobs")){
?>
@@ -52,7 +53,8 @@ class Navigation {
</li>
<?php }?>
<?php
if(checkAuth("view-menu-barshifts")){
/* Note: This menu item is hidden because the feature is not used anymore */
/*if(checkAuth("view-menu-barshifts")){
?>
<li class="menulist">
<a href="#" id="barshiftsSwitch" class="switch">Tappetårnets vaktliste</a>
@@ -64,9 +66,10 @@ class Navigation {
<?php } ?>
</ul>
</li>
<?php }?>
<?php }*/?>
<?php
if(checkAuth("view-menu-events")){
/* Note: This menu item is hidden because the feature is not used anymore */
/*if(checkAuth("view-menu-events")){
?>
<li class="menulist">
<a href="#" id="eventsSwitch" class="switch">Møter/kurs/internfester</a>
@@ -79,9 +82,10 @@ class Navigation {
?> <li><a href="index.php?page=display-all-calendar">Kombolender</a></li>
</ul>
</li>
<?php }?>
<?php }*/?>
<?php
if(checkAuth("view-menu-concerts")){
/* Note: This menu item is disabled because it is replaced by the publishing features of Wordpress */
/*if(checkAuth("view-menu-concerts")){
?>
<li class="menulist">
<a href="#" id="concertsSwitch" class="switch">Konserter/program</a>
@@ -97,7 +101,7 @@ class Navigation {
<?php }?>
</ul>
</li>
<?php }?>
<?php }*/?>
<?php
if(checkAuth("view-menu-divisions")){
?>
@@ -194,7 +198,8 @@ class Navigation {
<?php }?>
<?php
if(checkAuth("view-menu-webpages")){
/* Note: This menu item is disabled because it is replaced by the publishing features of Wordpress */
/*if(checkAuth("view-menu-webpages")){
?>
<li class="menulist">
<a href="#" id="webpagesSwitch" class="switch">Nyheter</a>
@@ -203,15 +208,15 @@ class Navigation {
<li><a href="index.php?page=register-article">Skriv nyhet</a></li>
</ul>
</li>
<?php }?>
<?php }*/?>
<?php
if(checkAuth("view-menu-settings")){
?>
<li class="menulist">
<a href="#" id="settingsSwitch" class="switch">Innstillinger</a>
<ul id="settingsMenu" class="menu">
<li><a href="index.php?action=switch-formtype&amp;section=settings">Bytt skjemastil</a></li>
<li><a href="index.php?action=switch-tinymce-theme&amp;section=settings">Bytt RT-editor</a></li>
<!--<li><a href="index.php?action=switch-formtype&amp;section=settings">Bytt skjemastil</a></li>
<li><a href="index.php?action=switch-tinymce-theme&amp;section=settings">Bytt RT-editor</a></li>-->
<li><a href="index.php?page=register-documentcategory">Dokumenttyper</a></li>
<li><a href="index.php?page=register-eventcategory">Aktitivitetstyper</a></li>
<li><a href="index.php?page=register-jobcategory">Stillingstyper</a></li>
@@ -230,8 +235,8 @@ class Navigation {
</li>
<?php
}
if(isAdmin()){
/* Note: This menu item is hidden because the feature is not used anymore */
/*if(isAdmin()){
?>
<li class="menulist">
<a href="#" id="samarbeidspartnereSwitch" class="switch">Samarbeidspartnere</a>
@@ -244,6 +249,7 @@ class Navigation {
</li>
<?php
}
*/
if(checkAuth("view-menu-webshop")){
?>
@@ -259,23 +265,12 @@ class Navigation {
</li>
<?php
}
if (loggedIn()){
if (loggedIn() && isActive()) {
?>
<li class="menulist">
<a href="#" id="linksSwitch" class="switch">Andre sider</a>
<ul id="linksMenu" class="menu">
<li><a href="http://www.studentersamfundet.no/index.php">Studentersamfundet.no</a></li>
<li><a href="http://www.studentersamfundet.no/forum/index.php">Forum</a></li>
<?php
if (isActive()) {
?>
<li><a href="http://www.studentersamfundet.no/coppermine/index.php">Bildegalleri</a></li>
<li><a href="http://www.studentersamfundet.no/info/index.php">Infovræl</a></li>
<li><a href="http://booking.studentersamfundet.no/">Bookingsystemet</a></li>
<?php
}
?>
<li><a href="http://booking.studentersamfundet.no/">Bookingsystemet</a></li>
</ul>
</li>
<?php
+20 -20
View File
@@ -484,16 +484,16 @@ class Page {
<link rel="stylesheet" type="text/css" href="../css/handheld.css" media="handheld" />
<link rel="stylesheet" type="text/css" href="../css/print.css" media="print" />
<link rel="shortcut icon" href="favicon.ico" />
<script type="text/javascript" src="functions.js"></script>
<script type="text/javascript" src="ajax.js"></script>
<script type="text/javascript" src="../includes/zXml/zxml.js"></script>
<script type="text/javascript" src="finder.js"></script>
<script type="text/javascript" src="sorttable.js"></script>
<script type="text/javascript" src="menuExpandable3.js"></script>
<script type="text/javascript" src="XMLRequest.js"></script>
<script type="text/javascript" src="XMLZipRequest.js"></script>
<script type="text/javascript" src="XMLCatRequest.js"></script>
<script type="text/javascript" src="XMLUsernameRequest.js"></script>
<script type="text/javascript" src="<?php echo $GLOBALS['static_path'];?>js/functions.js"></script>
<script type="text/javascript" src="<?php echo $GLOBALS['static_path'];?>js/ajax.js"></script>
<script type="text/javascript" src="<?php print $GLOBALS['include_path'];?>zXml/zxml.js"></script>
<script type="text/javascript" src="<?php echo $GLOBALS['static_path'];?>js/finder.js"></script>
<script type="text/javascript" src="<?php echo $GLOBALS['static_path'];?>js/sorttable.js"></script>
<script type="text/javascript" src="<?php echo $GLOBALS['static_path'];?>js/menuExpandable3.js"></script>
<script type="text/javascript" src="<?php echo $GLOBALS['static_path'];?>js/XMLRequest.js"></script>
<script type="text/javascript" src="<?php echo $GLOBALS['static_path'];?>js/XMLZipRequest.js"></script>
<script type="text/javascript" src="<?php echo $GLOBALS['static_path'];?>js/XMLCatRequest.js"></script>
<script type="text/javascript" src="<?php echo $GLOBALS['static_path'];?>js/XMLUsernameRequest.js"></script>
<script type="text/javascript" src="<?php print $GLOBALS['include_path'];?>tiny_mce/tiny_mce.js"></script>
<script type="text/javascript">
tinyMCE.init({
@@ -544,13 +544,13 @@ class Page {
}
</script>
<!-- Migration (nikolark) -->
<link type="text/css" href="./migration/css/smoothness/jquery-ui-1.8.14.custom.css" rel="stylesheet" />
<link type="text/css" href="./migration/css/nikolark.css" rel="stylesheet" />
<script type="text/javascript" src="./migration/js/jquery-1.5.1.min.js"></script>
<script type="text/javascript" src="./migration/js/jquery-ui-1.8.14.custom.min.js"></script>
<script type="text/javascript" src="./migration/js/jquery.validate.min.js"></script>
<script type="text/javascript" src="./migration/js/custom_validators.js"></script>
<script type="text/javascript" src="./migration/js/byebye_inside.js"></script>
<link type="text/css" href="<?php echo $GLOBALS['static_path'];?>css/migration/smoothness/jquery-ui-1.8.14.custom.css" rel="stylesheet" />
<link type="text/css" href="<?php echo $GLOBALS['static_path'];?>css/migration/nikolark.css" rel="stylesheet" />
<script type="text/javascript" src="<?php echo $GLOBALS['static_path'];?>js/migration/jquery-1.5.1.min.js"></script>
<script type="text/javascript" src="<?php echo $GLOBALS['static_path'];?>js/migration/jquery-ui-1.8.14.custom.min.js"></script>
<script type="text/javascript" src="<?php echo $GLOBALS['static_path'];?>js/migration/jquery.validate.min.js"></script>
<script type="text/javascript" src="<?php echo $GLOBALS['static_path'];?>js/migration/custom_validators.js"></script>
<script type="text/javascript" src="<?php echo $GLOBALS['static_path'];?>js/migration/byebye_inside.js"></script>
<title><?php print $this->page_title; ?></title>
</head>
@@ -664,8 +664,8 @@ class Page {
<?php } ?>
<li><a href="index.php?page=display-jobs">Se på ledige stillinger</a>
(<?php print getUnreadCount('job', 'expires'); ?> nye ikke utgåtte)</li>
<li><a href="index.php?page=display-events-calendar">Se på aktivitetskalenderen</a>
(<?php print getUnreadCount('event', 'time'); ?> nye kommende)</li>
<!--<li><a href="index.php?page=display-events-calendar">Se på aktivitetskalenderen</a>
(<?php print getUnreadCount('event', 'time'); ?> nye kommende)</li>-->
<li><a href="index.php?page=display-documents">Lese dokumenter</a></li>
<li><a href="index.php?page=display-divisions">Finne kontaktinfo til en forening</a></li>
<li><a href="index.php?page=display-current-user">Oppdatere min brukerinformasjon</a></li>
@@ -2977,7 +2977,7 @@ Om dere lager en facebook side til arrangementet, ikke glem &aring; putte inn le
"attributes" => Array("name" => "transactionid", "size" => 12, "maxlength" => 20,
"value" => $trans_id));
if ($value == NULL) {
if ($product != NULL){
if (@$product != NULL){
$fields[] = Array("label" => "beløp", "type" => "text",
"attributes" => Array("name" => "amount", "size" => 5, "maxlength" => 5,
"value" => $product->price, "readonly" => "readonly"));
+1 -1
View File
@@ -16,7 +16,7 @@ class Payment {
}
private function initPayex() {
require_once ('../payex2/payex_pxorder.php'); // Include the Payex PxOrder implementation
require_once ('payex_pxorder.php'); // Include the Payex PxOrder implementation
$this->payex = new PayexPxOrder(); // Make an instance of the PayexPxOrder class
$this->user_email = false;
+2 -2
View File
@@ -204,7 +204,7 @@ class Product {
<?php
if ($this->picture != 0){
print('<div class="product_images">');
print('<img src="imageResize.php?pic=images/products/'.$this->picture.'&amp;maxwidth=200" alt="" />');
print('<img src="inside/imageResize.php?pic=images/products/'.$this->picture.'&amp;maxwidth=200" alt="" />');
print('</div>');
}
?>
@@ -242,7 +242,7 @@ class Product {
<?php
if ($this->picture != 0){
print('<div class="product_images">');
print('<img src="imageResize.php?pic=images/products/'.$this->picture.'&amp;maxheight=100" alt="" />');
print('<img src="inside/imageResize.php?pic=images/products/'.$this->picture.'&amp;maxheight=100" alt="" />');
print('</div>');
}
?>
+4 -4
View File
@@ -420,9 +420,9 @@ function new_file($file, $dir) {
if ($f) {
if ($dir == 'products') {
$dir = 'images/products/';
$dir = 'inside/images/products/';
}else {
$dir = "../../public_html/bilder/$dir/";
$dir = "inside/images/uploads/$dir/";
}
$upFile = $dir.$newFile_name;
@@ -450,9 +450,9 @@ function new_file($file, $dir) {
function rename_file($old_name, $id, $dir, $report = true) {
if ($dir == 'products')
$dir = 'images/products/';
$dir = 'inside/images/products/';
else
$dir = "../../public_html/bilder/$dir/";
$dir = "inside/images/uploads/$dir/";
$ext = strtolower( pathinfo($old_name, PATHINFO_EXTENSION) );
$old_name = $dir . $old_name;
File renamed without changes.

Before

Width:  |  Height:  |  Size: 4.9 KiB

After

Width:  |  Height:  |  Size: 4.9 KiB

File renamed without changes.

Before

Width:  |  Height:  |  Size: 4.8 KiB

After

Width:  |  Height:  |  Size: 4.8 KiB

View File
Whitespace-only changes.
+4 -2
View File
@@ -16,9 +16,11 @@ require_once "language.php";
//Migration (nikolark)
require_once "migration/ldap_api_functions.php";
set_include_path("../includes");
$path = "./includes".PATH_SEPARATOR."./includes/payex2".PATH_SEPARATOR."../includes";
set_include_path(get_include_path() . PATH_SEPARATOR . $path);
$include_path = "../includes/";
$include_path = "./includes/";
$static_path = "/";
//PEAR-class
require_once "DB.php";
-17
View File
@@ -1,19 +1,2 @@
<?php
#if(!isset($_SERVER['HTTPS']) || $_SERVER['HTTPS'] != 'on')
#{
# header("Location: https://www.studentersamfundet.no{$_SERVER['REQUEST_URI']}");
# die;
#}
$time_start = microtime(true);
require_once "includes.php";
$ap = new ActionParser();
$ap->performAction();
$p = new Page();
$p->display();
?>
+7 -2
View File
@@ -1,11 +1,16 @@
<?php
function new_login($username_or_email, $password) {
$db = new Ldap(LDAP_SERVER);
if(trim($username_or_email) == "" || trim($password) == "") {
return false;
}
if( !LDAP_ENABLED ) {
return legacy_login($username_or_email, $password);
}
$db = new Ldap(LDAP_SERVER);
/* sanitize input */
// TODO how?
+1 -3
View File
@@ -6,10 +6,8 @@ setlocale(LC_TIME, $locale);
//Extras
require_once("../functions.php");
require_once("../language.php");
set_include_path("../../includes");
$include_path = "../../includes/";
//PEAR-class
require_once($include_path."DB.php");
require_once("DB.php");
require_once("../User.php");
function update_user($username, $password) {
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
View File
File renamed without changes.
View File
File renamed without changes.
File renamed without changes.
@@ -17,11 +17,11 @@ function initializeMenu(menuId, actuatorId) {
return;
}
actuator.parentNode.style.backgroundImage = "url(../inside/graphics/plus.png)";
actuator.parentNode.style.backgroundImage = "url(../graphics/plus.png)";
actuator.onclick = function() {
var display = menu.style.display;
this.parentNode.style.backgroundImage =
(display == "block") ? "url(../inside/graphics/plus.png)" : "url(../inside/graphics/minus.png)";
(display == "block") ? "url(../graphics/plus.png)" : "url(../graphics/minus.png)";
menu.style.display = (display == "block") ? "none" : "block";
return false;
@@ -33,7 +33,7 @@ function menuExpandCurrentSection(menuId){
if (menu == null){
return;
}
menu.parentNode.style.backgroundImage = "url(../inside/graphics/minus.png)";
menu.parentNode.style.backgroundImage = "url(../graphics/minus.png)";
menu.style.display = "block";
}
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Loaded 100 of 102 files, more files were not shown because too many files have changed in this diff. Show more