@@ -18,14 +18,14 @@ discard block |
||
| 18 | 18 | require "../../config/admin.php"; |
| 19 | 19 | |
| 20 | 20 | if (isset($action)) { |
| 21 | - if ($action=='delete_comment') { |
|
| 21 | + if ($action == 'delete_comment') { |
|
| 22 | 22 | create_log_entry('Interviews', $comment_id, 'Comment', $comment_id, 'Delete', $_SESSION['user_id']); |
| 23 | 23 | |
| 24 | 24 | $sql = $mysqli->query("DELETE FROM interview_user_comments WHERE comment_id = '$comment_id'") |
| 25 | 25 | or die("couldn't delete game_comment quote"); |
| 26 | 26 | $sql = $mysqli->query("DELETE FROM comments WHERE comments_id = '$comment_id'") |
| 27 | 27 | or die("couldn't delete comment quote"); |
| 28 | - } elseif ($action=="save_comment") { |
|
| 28 | + } elseif ($action == "save_comment") { |
|
| 29 | 29 | //$data = $_POST['data']; |
| 30 | 30 | $data = $mysqli->real_escape_string($data); |
| 31 | 31 | |
@@ -79,7 +79,7 @@ discard block |
||
| 79 | 79 | //(instead of a post with pure HTML) The translation of the 'enter' breaks is different in JS, so in JS I do |
| 80 | 80 | //a conversion to a <br>. However, when we edit a comment, this <br> should not be |
| 81 | 81 | //visible to the user, hence again, now this conversion in php |
| 82 | - $breaks = array("<br />","<br>","<br/>"); |
|
| 82 | + $breaks = array("<br />", "<br>", "<br/>"); |
|
| 83 | 83 | $comment = str_ireplace($breaks, "\r\n", $comment); |
| 84 | 84 | |
| 85 | 85 | $date = date("d/m/y", $query_comment['timestamp']); |
@@ -106,5 +106,5 @@ discard block |
||
| 106 | 106 | $smarty->assign('selected_interview_id', $interview_id); |
| 107 | 107 | |
| 108 | 108 | //Send all smarty variables to the templates |
| 109 | - $smarty->display("file:" . $mainsite_template_folder . "interviews/ajax_interviews_detail_comments.html"); |
|
| 109 | + $smarty->display("file:".$mainsite_template_folder."interviews/ajax_interviews_detail_comments.html"); |
|
| 110 | 110 | } |
@@ -190,7 +190,7 @@ discard block |
||
| 190 | 190 | //However, when we edit a comment, this <br> should not be visible to the user, hence again, |
| 191 | 191 | //now this conversion in php |
| 192 | 192 | |
| 193 | - $breaks = array( |
|
| 193 | + $breaks = array( |
|
| 194 | 194 | "<br />", |
| 195 | 195 | "<br>", |
| 196 | 196 | "<br/>" |
@@ -218,7 +218,7 @@ discard block |
||
| 218 | 218 | } |
| 219 | 219 | |
| 220 | 220 | //Send all smarty variables to the templates |
| 221 | -$smarty->display("file:" . $mainsite_template_folder . "interviews/interviews_detail.html"); |
|
| 221 | +$smarty->display("file:".$mainsite_template_folder."interviews/interviews_detail.html"); |
|
| 222 | 222 | |
| 223 | 223 | //close the connection |
| 224 | 224 | mysqli_close($mysqli); |
@@ -40,7 +40,7 @@ discard block |
||
| 40 | 40 | LEFT JOIN users on (interview_main.user_id = users.user_id) |
| 41 | 41 | LEFT JOIN individuals on (interview_main.ind_id = individuals.ind_id) |
| 42 | 42 | LEFT JOIN individual_text on (interview_main.ind_id = individual_text.ind_id) |
| 43 | - ORDER BY interview_text.interview_date DESC LIMIT " . $v_counter . ", 5" |
|
| 43 | + ORDER BY interview_text.interview_date DESC LIMIT " . $v_counter.", 5" |
|
| 44 | 44 | ) |
| 45 | 45 | or die("Error - Couldn't query interview data"); |
| 46 | 46 | |
@@ -100,13 +100,13 @@ discard block |
||
| 100 | 100 | //Check if back arrow is needed |
| 101 | 101 | if ($v_counter > 0) { |
| 102 | 102 | // Build the link |
| 103 | - $v_linkback = ('?v_counter=' . ($v_counter - 5)); |
|
| 103 | + $v_linkback = ('?v_counter='.($v_counter - 5)); |
|
| 104 | 104 | } |
| 105 | 105 | |
| 106 | 106 | //Check if we need to place a next arrow |
| 107 | 107 | if ($v_rows > ($v_counter + 5)) { |
| 108 | 108 | //Build the link |
| 109 | - $v_linknext = ('?v_counter=' . ($v_counter + 5)); |
|
| 109 | + $v_linknext = ('?v_counter='.($v_counter + 5)); |
|
| 110 | 110 | } |
| 111 | 111 | |
| 112 | 112 | if (empty($c_counter)) { |
@@ -129,7 +129,7 @@ discard block |
||
| 129 | 129 | ); |
| 130 | 130 | |
| 131 | 131 | //Send all smarty variables to the templates |
| 132 | -$smarty->display("file:" . $mainsite_template_folder . "interviews/interviews_main.html"); |
|
| 132 | +$smarty->display("file:".$mainsite_template_folder."interviews/interviews_main.html"); |
|
| 133 | 133 | |
| 134 | 134 | //close the connection |
| 135 | 135 | mysqli_close($mysqli); |
@@ -49,7 +49,7 @@ |
||
| 49 | 49 | $smarty->assign('action', 'andreas'); |
| 50 | 50 | } |
| 51 | 51 | |
| 52 | -$smarty->display("file:" . $mainsite_template_folder . "about/about.html"); |
|
| 52 | +$smarty->display("file:".$mainsite_template_folder."about/about.html"); |
|
| 53 | 53 | |
| 54 | 54 | //close the connection |
| 55 | 55 | mysqli_close($mysqli); |
@@ -128,7 +128,7 @@ discard block |
||
| 128 | 128 | //However, when we edit a comment, this <br> should not be visible to the user, hence again, |
| 129 | 129 | //now this conversion in php |
| 130 | 130 | |
| 131 | - $breaks = array( |
|
| 131 | + $breaks = array( |
|
| 132 | 132 | "<br />", |
| 133 | 133 | "<br>", |
| 134 | 134 | "<br/>" |
@@ -182,7 +182,7 @@ discard block |
||
| 182 | 182 | $smarty->assign('nr_articles_author', $count); |
| 183 | 183 | |
| 184 | 184 | //Send all smarty variables to the templates |
| 185 | -$smarty->display("file:" . $mainsite_template_folder . "articles/articles_detail.html"); |
|
| 185 | +$smarty->display("file:".$mainsite_template_folder."articles/articles_detail.html"); |
|
| 186 | 186 | |
| 187 | 187 | //close the connection |
| 188 | 188 | mysqli_close($mysqli); |
@@ -18,14 +18,14 @@ discard block |
||
| 18 | 18 | require "../../config/admin.php"; |
| 19 | 19 | |
| 20 | 20 | if (isset($action)) { |
| 21 | - if ($action=='delete_comment') { |
|
| 21 | + if ($action == 'delete_comment') { |
|
| 22 | 22 | create_log_entry('Articles', $article_id, 'Comment', $comment_id, 'Delete', $_SESSION['user_id']); |
| 23 | 23 | |
| 24 | 24 | $sql = $mysqli->query("DELETE FROM article_user_comments WHERE comments_id = '$comment_id'") |
| 25 | 25 | or die("couldn't delete article_comment quote"); |
| 26 | 26 | $sql = $mysqli->query("DELETE FROM comments WHERE comments_id = '$comment_id'") |
| 27 | 27 | or die("couldn't delete comment quote"); |
| 28 | - } elseif ($action=="save_comment") { |
|
| 28 | + } elseif ($action == "save_comment") { |
|
| 29 | 29 | //$data = $_POST['data']; |
| 30 | 30 | $data = $mysqli->real_escape_string($data); |
| 31 | 31 | |
@@ -79,7 +79,7 @@ discard block |
||
| 79 | 79 | //The translation of the 'enter' breaks is different in JS, so in JS I |
| 80 | 80 | //do a conversion to a <br>. However, when we edit a comment, this <br> should not be |
| 81 | 81 | //visible to the user, hence again, now this conversion in php |
| 82 | - $breaks = array("<br />","<br>","<br/>"); |
|
| 82 | + $breaks = array("<br />", "<br>", "<br/>"); |
|
| 83 | 83 | $comment = str_ireplace($breaks, "\r\n", $comment); |
| 84 | 84 | |
| 85 | 85 | $date = date("d/m/y", $query_comment['timestamp']); |
@@ -106,5 +106,5 @@ discard block |
||
| 106 | 106 | $smarty->assign('article_id', $article_id); |
| 107 | 107 | |
| 108 | 108 | //Send all smarty variables to the templates |
| 109 | - $smarty->display("file:" . $mainsite_template_folder . "articles/ajax_articles_detail_comments.html"); |
|
| 109 | + $smarty->display("file:".$mainsite_template_folder."articles/ajax_articles_detail_comments.html"); |
|
| 110 | 110 | } |
@@ -35,7 +35,7 @@ discard block |
||
| 35 | 35 | LEFT JOIN article_text on (article_main.article_id = article_text.article_id) |
| 36 | 36 | LEFT JOIN article_type on (article_main.article_type_id = article_type.article_type_id) |
| 37 | 37 | LEFT JOIN users on ( article_main.user_id = users.user_id ) |
| 38 | - ORDER BY article_text.article_date DESC LIMIT " . $v_counter . ", 5" |
|
| 38 | + ORDER BY article_text.article_date DESC LIMIT " . $v_counter.", 5" |
|
| 39 | 39 | ) or die("Couldn't query database for articles"); |
| 40 | 40 | |
| 41 | 41 | while ($article = $sql_articles->fetch_array(MYSQLI_BOTH)) { |
@@ -84,13 +84,13 @@ discard block |
||
| 84 | 84 | //Check if back arrow is needed |
| 85 | 85 | if ($v_counter > 0) { |
| 86 | 86 | // Build the link |
| 87 | - $v_linkback = ('?v_counter=' . ($v_counter - 5)); |
|
| 87 | + $v_linkback = ('?v_counter='.($v_counter - 5)); |
|
| 88 | 88 | } |
| 89 | 89 | |
| 90 | 90 | //Check if we need to place a next arrow |
| 91 | 91 | if ($v_rows > ($v_counter + 5)) { |
| 92 | 92 | //Build the link |
| 93 | - $v_linknext = ('?v_counter=' . ($v_counter + 5)); |
|
| 93 | + $v_linknext = ('?v_counter='.($v_counter + 5)); |
|
| 94 | 94 | } |
| 95 | 95 | |
| 96 | 96 | if (empty($c_counter)) { |
@@ -113,7 +113,7 @@ discard block |
||
| 113 | 113 | ); |
| 114 | 114 | |
| 115 | 115 | //Send all smarty variables to the templates |
| 116 | -$smarty->display("file:" . $mainsite_template_folder . "articles/articles_main.html"); |
|
| 116 | +$smarty->display("file:".$mainsite_template_folder."articles/articles_main.html"); |
|
| 117 | 117 | |
| 118 | 118 | //close the connection |
| 119 | 119 | mysqli_close($mysqli); |
@@ -10,10 +10,10 @@ |
||
| 10 | 10 | |
| 11 | 11 | //Include this file if you want a page to require admin permission level |
| 12 | 12 | //I'm using this file to check if the user has the rights to update the DB (only used in CPANEL) |
| 13 | -if ($_SESSION['permission']==1 or $_SESSION['permission']=='1') { |
|
| 13 | +if ($_SESSION['permission'] == 1 or $_SESSION['permission'] == '1') { |
|
| 14 | 14 | } else { |
| 15 | 15 | $_SESSION['edit_message'] = "You do not have the necessary authorizations to perform this action"; |
| 16 | 16 | //header("Location: ../administration/statistics.php"); |
| 17 | - header('Location: ' . $_SERVER['HTTP_REFERER']); |
|
| 17 | + header('Location: '.$_SERVER['HTTP_REFERER']); |
|
| 18 | 18 | die(''); |
| 19 | 19 | } |
@@ -55,7 +55,7 @@ discard block |
||
| 55 | 55 | define("CAN_REGISTER", "any"); |
| 56 | 56 | define("DEFAULT_ROLE", "member"); |
| 57 | 57 | |
| 58 | -define("SECURE", false); // FOR DEVELOPMENT ONLY!!!! |
|
| 58 | +define("SECURE", false); // FOR DEVELOPMENT ONLY!!!! |
|
| 59 | 59 | |
| 60 | 60 | //*************************************************************** |
| 61 | 61 | // Mail server variables -- change these is we change server! |
@@ -73,81 +73,81 @@ discard block |
||
| 73 | 73 | //*************************************************************** |
| 74 | 74 | |
| 75 | 75 | // database dumps |
| 76 | -$database_dumps_path="../../data/database-dumps/"; |
|
| 76 | +$database_dumps_path = "../../data/database-dumps/"; |
|
| 77 | 77 | |
| 78 | 78 | //articles |
| 79 | -$article_screenshot_path="../../data/images/article_screenshots/"; |
|
| 80 | -$article_screenshot_save_path="../../../data/images/article_screenshots/"; |
|
| 79 | +$article_screenshot_path = "../../data/images/article_screenshots/"; |
|
| 80 | +$article_screenshot_save_path = "../../../data/images/article_screenshots/"; |
|
| 81 | 81 | |
| 82 | 82 | //company |
| 83 | -$company_screenshot_path="../../data/images/company_logos/"; |
|
| 84 | -$company_screenshot_save_path="../../../data/images/company_logos/"; |
|
| 85 | -$individual_screenshot_path="../../data/images/individual_screenshots/"; |
|
| 86 | -$individual_screenshot_save_path="../../../data/images/individual_screenshots/"; |
|
| 83 | +$company_screenshot_path = "../../data/images/company_logos/"; |
|
| 84 | +$company_screenshot_save_path = "../../../data/images/company_logos/"; |
|
| 85 | +$individual_screenshot_path = "../../data/images/individual_screenshots/"; |
|
| 86 | +$individual_screenshot_save_path = "../../../data/images/individual_screenshots/"; |
|
| 87 | 87 | |
| 88 | 88 | //games |
| 89 | -$game_boxscan_path="../../data/images/game_boxscans/"; |
|
| 90 | -$game_boxscan_save_path="../../../data/images/game_boxscans/"; |
|
| 91 | -$game_file_path="../../../data/zips/games/"; |
|
| 92 | -$game_file_temp_path="../../../data/zips/temp/"; |
|
| 93 | -$game_gallery_path="../../data/images/game_gallery/"; |
|
| 94 | -$game_screenshot_path="../../data/images/game_screenshots/"; |
|
| 95 | -$game_screenshot_save_path="../../../data/images/game_screenshots/"; |
|
| 96 | -$game_submit_screenshot_path="../../data/images/game_submit_screenshots/"; |
|
| 97 | -$game_submit_screenshot_save_path="../../../data/images/game_submit_screenshots/"; |
|
| 98 | -$game_fact_screenshot_path="../../data/images/game_fact_screenshots/"; |
|
| 99 | -$game_fact_screenshot_save_path="../../../data/images/game_fact_screenshots/"; |
|
| 100 | -$music_game_path="../../data/music/games/"; |
|
| 101 | -$music_game_save_path="../../../data/music/games/"; |
|
| 89 | +$game_boxscan_path = "../../data/images/game_boxscans/"; |
|
| 90 | +$game_boxscan_save_path = "../../../data/images/game_boxscans/"; |
|
| 91 | +$game_file_path = "../../../data/zips/games/"; |
|
| 92 | +$game_file_temp_path = "../../../data/zips/temp/"; |
|
| 93 | +$game_gallery_path = "../../data/images/game_gallery/"; |
|
| 94 | +$game_screenshot_path = "../../data/images/game_screenshots/"; |
|
| 95 | +$game_screenshot_save_path = "../../../data/images/game_screenshots/"; |
|
| 96 | +$game_submit_screenshot_path = "../../data/images/game_submit_screenshots/"; |
|
| 97 | +$game_submit_screenshot_save_path = "../../../data/images/game_submit_screenshots/"; |
|
| 98 | +$game_fact_screenshot_path = "../../data/images/game_fact_screenshots/"; |
|
| 99 | +$game_fact_screenshot_save_path = "../../../data/images/game_fact_screenshots/"; |
|
| 100 | +$music_game_path = "../../data/music/games/"; |
|
| 101 | +$music_game_save_path = "../../../data/music/games/"; |
|
| 102 | 102 | |
| 103 | 103 | //releases |
| 104 | -$game_release_scan_path="../../data/images/game_release_scans/"; |
|
| 105 | -$game_release_scan_save_path="../../../data/images/game_release_scans/"; |
|
| 104 | +$game_release_scan_path = "../../data/images/game_release_scans/"; |
|
| 105 | +$game_release_scan_save_path = "../../../data/images/game_release_scans/"; |
|
| 106 | 106 | |
| 107 | 107 | //interview |
| 108 | -$interview_screenshot_path="../../data/images/interview_screenshots/"; |
|
| 109 | -$interview_screenshot_save_path="../../../data/images/interview_screenshots/"; |
|
| 108 | +$interview_screenshot_path = "../../data/images/interview_screenshots/"; |
|
| 109 | +$interview_screenshot_save_path = "../../../data/images/interview_screenshots/"; |
|
| 110 | 110 | |
| 111 | 111 | //menu |
| 112 | -$menu_screenshot_path="../../data/images/menu_screenshots/"; |
|
| 113 | -$menu_screenshot_save_path="../../../data/images/menu_screenshots/"; |
|
| 114 | -$menu_file_path="../../../data/zips/menus/"; |
|
| 115 | -$menu_file_temp_path="../../../data/zips/temp/"; |
|
| 112 | +$menu_screenshot_path = "../../data/images/menu_screenshots/"; |
|
| 113 | +$menu_screenshot_save_path = "../../../data/images/menu_screenshots/"; |
|
| 114 | +$menu_file_path = "../../../data/zips/menus/"; |
|
| 115 | +$menu_file_temp_path = "../../../data/zips/temp/"; |
|
| 116 | 116 | |
| 117 | 117 | //news |
| 118 | -$news_images_path="../../data/images/news_images/"; |
|
| 119 | -$news_images_save_path="../../../data/images/news_images/"; |
|
| 118 | +$news_images_path = "../../data/images/news_images/"; |
|
| 119 | +$news_images_save_path = "../../../data/images/news_images/"; |
|
| 120 | 120 | |
| 121 | 121 | //links |
| 122 | -$website_image_path="../../data/images/website_images/"; |
|
| 123 | -$website_image_path="../../data/images/website_images/"; |
|
| 124 | -$website_image_save_path="../../../data/images/website_images/"; |
|
| 122 | +$website_image_path = "../../data/images/website_images/"; |
|
| 123 | +$website_image_path = "../../data/images/website_images/"; |
|
| 124 | +$website_image_save_path = "../../../data/images/website_images/"; |
|
| 125 | 125 | |
| 126 | 126 | //trivia |
| 127 | -$trivia_screenshot_path="../../data/images/trivia_screens/"; |
|
| 128 | -$spotlight_screenshot_path="../../data/images/spotlight_screens/"; |
|
| 129 | -$spotlight_screenshot_save_path="../../../data/images/spotlight_screens/"; |
|
| 127 | +$trivia_screenshot_path = "../../data/images/trivia_screens/"; |
|
| 128 | +$spotlight_screenshot_path = "../../data/images/spotlight_screens/"; |
|
| 129 | +$spotlight_screenshot_save_path = "../../../data/images/spotlight_screens/"; |
|
| 130 | 130 | |
| 131 | 131 | //demos |
| 132 | -$demo_screenshot_path="../../data/images/demo_screenshots/"; |
|
| 133 | -$demo_file_path="../../data/zips/demos/"; |
|
| 134 | -$demo_file_temp_path="../../data/zips/temp/"; |
|
| 135 | -$music_demo_path="../../data/music/demos/"; |
|
| 132 | +$demo_screenshot_path = "../../data/images/demo_screenshots/"; |
|
| 133 | +$demo_file_path = "../../data/zips/demos/"; |
|
| 134 | +$demo_file_temp_path = "../../data/zips/temp/"; |
|
| 135 | +$music_demo_path = "../../data/music/demos/"; |
|
| 136 | 136 | |
| 137 | 137 | //Crews |
| 138 | -$crew_logo_path="../../data/images/crew_logos/"; |
|
| 139 | -$crew_logo_save_path="../../../data/images/crew_logos/"; |
|
| 138 | +$crew_logo_path = "../../data/images/crew_logos/"; |
|
| 139 | +$crew_logo_save_path = "../../../data/images/crew_logos/"; |
|
| 140 | 140 | |
| 141 | 141 | //magazine |
| 142 | -$magazine_scan_path="../../data/images/magazine_scans/"; |
|
| 142 | +$magazine_scan_path = "../../data/images/magazine_scans/"; |
|
| 143 | 143 | |
| 144 | 144 | //users |
| 145 | -$user_avatar_path="../../data/images/user_avatars/"; |
|
| 146 | -$user_avatar_save_path="../../../data/images/user_avatars/"; |
|
| 145 | +$user_avatar_path = "../../data/images/user_avatars/"; |
|
| 146 | +$user_avatar_save_path = "../../../data/images/user_avatars/"; |
|
| 147 | 147 | |
| 148 | 148 | //Dump |
| 149 | -$media_scan_path="../../data/images/media_scans/"; |
|
| 150 | -$media_scan_save_path="../../../data/images/media_scans/"; |
|
| 149 | +$media_scan_path = "../../data/images/media_scans/"; |
|
| 150 | +$media_scan_save_path = "../../../data/images/media_scans/"; |
|
| 151 | 151 | |
| 152 | 152 | // Include environment-specific settings |
| 153 | 153 | require('local_settings.php'); |