Browse code

attempt to fix national characters coding

Jimmi08 authored on 2020/01/15 12:04:08
Showing 3 changed files
... ...
@@ -38,7 +38,7 @@ if(get_magic_quotes_gpc()){
38 38
 }
39 39
 
40 40
 // Defines the character set for your language/location
41
-define ("_CHARSET", "UTF-8");
41
+define ("_CHARSET", "utf-8");
42 42
 
43 43
 // Prevent possible XSS attacks via $_GET.
44 44
 foreach ($_GET as $v) {
... ...
@@ -217,6 +217,7 @@ if($current == "viewuser" && isNumber($uid)) {
217 217
 	$titleinfo = "$sitename :: $penname";
218 218
 }
219 219
 echo _DOCTYPE."<html><head>";
220
+echo "<meta charset='utf-8' />";
220 221
 if(!isset($titleinfo)) $titleinfo = "$sitename :: $slogan";
221 222
 if(isset($metaDesc)) echo "<meta name='description' content='$metaDesc'>";
222 223
 echo "<title>$titleinfo</title>";
... ...
@@ -525,7 +525,7 @@ function charlist($characters) {
525 525
 // Most of the pages that list stories and series use this fuction.  This handles showing the series and stories and pagination of the two together when needed
526 526
 function search($storyquery, $countquery, $pagelink = "search.php?", $pagetitle = 0) {
527 527
 	global $tpl, $new, $ratingslist, $itemsperpage, $reviewsallowed, $output, $dateformat, $current, $featured, $favorites, $retired, $ageconsent, $classtypelist, $classlist, $offset, $recentdays;
528
-
528
+     
529 529
 	$count = dbquery($countquery);
530 530
 	list($numrows) = dbrow($count);
531 531
 	if($numrows) {
... ...
@@ -541,9 +541,9 @@ function search($storyquery, $countquery, $pagelink = "search.php?", $pagetitle
541 541
 		$tpl->gotoBlock("listings");
542 542
 		$tpl->assign("stories",  "<div class=\"sectionheader\">"._STORIES."</div>");
543 543
 		$storyquery .= " LIMIT $offset, $itemsperpage";
544
-		$result3 = dbquery($storyquery);
545
-		$count = 0;
546
-		while($stories = dbassoc($result3)) { 
544
+		$result3 = dbquery($storyquery);     
545
+		$count = 0;                     
546
+		while($stories = dbassoc($result3)) {       
547 547
 			$tpl->newBlock("storyblock");
548 548
 			include(_BASEDIR."includes/storyblock.php"); 
549 549
 		}
... ...
@@ -54,7 +54,7 @@ if(ini_get("magic_quotes_gpc")) {
54 54
 }
55 55
 
56 56
 define("_BASEDIR", "../");
57
-
57
+define("_CHARSET", "utf-8");
58 58
 Header('Cache-Control: private, no-cache, must-revalidate, max_age=0, post-check=0, pre-check=0');
59 59
 header ("Pragma: no-cache"); 
60 60
 header ("Expires: 0");