From d24a3edef4bea5eb7bc1cb0c4209799c72bf3f71 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?F=C3=A1ndly=20Gerg=C5=91?= Date: Sat, 10 Aug 2019 15:30:59 +0300 Subject: [PATCH] Fixes --- .htaccess | 2 +- config/lang/en_US.ini | 4 ++ config/lang/hu_HU.ini | 6 +- subs/parts/userarea.php | 1 + subs/parts/userarea/projects.php | 106 +++++++++++++++++++++++++++++++ subs/parts/userarea_backend.php | 4 +- 6 files changed, 119 insertions(+), 4 deletions(-) create mode 100644 subs/parts/userarea/projects.php diff --git a/.htaccess b/.htaccess index 8203692..8b77547 100644 --- a/.htaccess +++ b/.htaccess @@ -1,4 +1,4 @@ RewriteEngine on -RewriteRule ^([a-zA-Z_]+)\/((config|proj|res|script|style|subs|uploads|websvn)\/?([a-zA-Z_.\/]+)?)$ /$2 [L,R] +RewriteRule ^([a-zA-Z_]+)\/((config|proj|res|script|style|subs|uploads)\/([a-zA-Z_.\/]+)?)$ /$2 [L,R] RewriteRule ^(config|mailer|proj|res|script|style|subs|uploads|websvn)\/?(.)+?$ - [L] RewriteRule ^([a-zA-Z_]+)(\/([a-zA-Z0-9_:]+))?\/?$ index.php?view=$1&sub=$3 [L,QSA] diff --git a/config/lang/en_US.ini b/config/lang/en_US.ini index 4f13e38..c5bd0ef 100644 --- a/config/lang/en_US.ini +++ b/config/lang/en_US.ini @@ -110,6 +110,10 @@ unlimited="Unlimited" finish="Finalize!" send_message="Send message" smessage="Message" +projectlist="Project list" +description="Description" +path="Path" +repository="Repository" ;Errors error[1]="Wrong username or password!" diff --git a/config/lang/hu_HU.ini b/config/lang/hu_HU.ini index 6933d2b..afdcf91 100644 --- a/config/lang/hu_HU.ini +++ b/config/lang/hu_HU.ini @@ -3,7 +3,7 @@ cookie_message="Ez a weboldal sütiket használ, hogy a legjobb felhasználói cookie_dismiss="Értettem!" cookie_link="Tudj meg többet" index="Kezdőlap" -projects="Projekter" +projects="Projektek" repos="Repók" blog="Blog" about="Rólunk" @@ -110,6 +110,10 @@ unlimited="Végtelen" finish="Véglegesítés!" send_message="Üzenet küldése" smessage="Üzenet" +projectlist="Projekt lista" +description="Leírás" +path="Útvonal" +repository="Repó" ;Errors error[1]="Hibás felhasználónév vagy jelszó!" diff --git a/subs/parts/userarea.php b/subs/parts/userarea.php index 7219670..ec90224 100644 --- a/subs/parts/userarea.php +++ b/subs/parts/userarea.php @@ -99,6 +99,7 @@ $lm->loginPrepare(); =1): ?> =2): ?> + =3): ?> diff --git a/subs/parts/userarea/projects.php b/subs/parts/userarea/projects.php new file mode 100644 index 0000000..930a72c --- /dev/null +++ b/subs/parts/userarea/projects.php @@ -0,0 +1,106 @@ +. + **/ +?> + +
+

+ + + + + + + + + + + + + + + prepare("SELECT p.id, p.name, p.description, u.fullname AS owner, p.path, p.repo, p.status FROM projects AS p INNER JOIN users AS u ON (u.id=p.owner) ORDER BY p.name ASC"); + $sql->execute(); + while($row=$sql->fetch(PDO::FETCH_ASSOC)){ + echo " + + + + + + + + + + + "; + } + ?> + +
".$row['id']."".$row['name']."".$row['description']."".$row['owner']."".$row['path']."".$row['repo']."".$row['status']." + + +
+
+ +
+ \ No newline at end of file diff --git a/subs/parts/userarea_backend.php b/subs/parts/userarea_backend.php index 05cad4d..c4d9a49 100644 --- a/subs/parts/userarea_backend.php +++ b/subs/parts/userarea_backend.php @@ -41,7 +41,7 @@ else{ } if($sub!=""){ - if($sub!="fileshare" && $sub!="blog" && $sub!="orders" && $sub!="messages" && $sub!="news" && $sub!="admin" && $sub!="profile"){ + if($sub!="fileshare" && $sub!="blog" && $sub!="projects" && $sub!="orders" && $sub!="messages" && $sub!="news" && $sub!="admin" && $sub!="profile"){ functions::setError(500); header("Location: /userarea"); } @@ -49,7 +49,7 @@ else{ functions::setError(500); header("Location: /userarea"); } - if(($sub=="orders" || $sub=="messages") && $_SESSION['accesslevel']<2){ + if(($sub=="projects" || $sub=="orders" || $sub=="messages") && $_SESSION['accesslevel']<2){ functions::setError(500); header("Location: /userarea"); }