SELECT DEFAULT_CHARACTER_SET_NAME, DEFAULT_COLLATION_NAME FROM
information_schema.SCHEMATA S
WHERE schema_name = 'your_database_name'
AND
(DEFAULT_CHARACTER_SET_NAME != 'utf8'
OR
DEFAULT_COLLATION_NAME not like 'utf8%');
ALTER DATABASE databasename CHARACTER SET utf8 COLLATE utf8_unicode_ci;
SELECT CONCAT(
'ALTER TABLE ', table_name, ' CHARACTER SET utf8 COLLATE utf8_general_ci; ',
'ALTER TABLE ', table_name, ' CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci; ')
FROM information_schema.TABLES AS T, information_schema.`COLLATION_CHARACTER_SET_APPLICABILITY` AS C
WHERE C.collation_name = T.table_collation
AND T.table_schema = 'your_database_name'
AND
(C.CHARACTER_SET_NAME != 'utf8'
OR
C.COLLATION_NAME not like 'utf8%')
ALTER TABLE rma CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE rma CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;
ALTER TABLE rma_history CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE rma_history CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;
ALTER TABLE rma_products CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE rma_products CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;
ALTER TABLE rma_report_period CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE rma_report_period CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;
ALTER TABLE rma_reservation CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE rma_reservation CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;
ALTER TABLE rma_supplier_return CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE rma_supplier_return CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;
ALTER TABLE rma_supplier_return_history CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE rma_supplier_return_history CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;
ALTER TABLE rma_supplier_return_product CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE rma_supplier_return_product CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;
//DISPLAY NFO BLOCK
if($row["nfo"]== "yes"){
$nfofilelocation = "$nfo_dir/$row[id].nfo";
$filegetcontents = file_get_contents($nfofilelocation);
$nfo = htmlspecialchars($filegetcontents);
if ($nfo) {
$nfo = my_nfo_translate($nfo);
echo "<br /><center><b>NFO ↴</b></center><br />";
print("<center><textarea class='nfo' style='width:99%;height:100%;' rows='20' cols='20' readonly='readonly'>".stripslashes($nfo)."</textarea></center>");
}else{
print(T_("ERROR")." reading .nfo file!");
}
}
//DISPLAY NFO BLOCK
if($row["nfo"]== "yes"){
$nfofilelocation = "$nfo_dir/$row[id].nfo";
$filegetcontents = file_get_contents($nfofilelocation);
$nfo = htmlspecialchars($filegetcontents);
if ($nfo) {
$nfo = my_nfo_translate($nfo);
if (get_user_class() >= 4) {
echo "<a class='stylebouton' href='nfo-view.php?id=".$row["id"]."' target='_blank'>".T_("VIEW_CURRENT_NFO")."</a>";
}
echo "<meta http-equiv='Content-Type' content='text/html; charset=utf-8' /><br /><center><b>NFO ↴</b><br />";
print("<textarea class='nfo collapsible' style='width:96%;height:100%;' rows='20' cols='20' readonly='readonly'>".stripslashes($filegetcontents)."</textarea></center><br/>");
}else{
print(T_("ERROR")." Reading the .nfo file is not good! make sure that the encoding is in UTF-8 and that the file has the extension .nfo ");
}
}
if ($nfo) {
$nfo = my_nfo_translate($nfo);
if($CURUSER["edit_torrents"]=="yes")
begin_frame(T_("NFO_FILE_FOR").": <a href='".$site_config["SITEURL"]."/torrents-details.php?id=$id'>$shortname</a> - <a href='nfo-edit.php?id=$id'>".T_("NFO_EDIT")."</a>");
else
begin_frame(T_("NFO_FILE_FOR").": $shortname");
print("<textarea class='nfo' style=\"width:98%;height:100%;\" rows='50' cols='20' readonly='readonly'>".stripslashes($nfo)."</textarea>");
end_frame();
}
}//has nfo
if ($nfo) {
$nfo = my_nfo_translate($nfo);
if($CURUSER["edit_torrents"]=="yes")
begin_frame("<a href='".$site_config["SITEURL"]."/torrents-details.php?id=$id'><font size='3'>".$shortname."</font></a>");
else
begin_frame("$shortname");
// .stripslashes($nfo)." // < souvegarde plus valide pour la v3
print('<textarea class="nfo" name="content" cols="210" rows="40">'.$filegetcontents.'</textarea><br />');
print("<br/><center><a class='stylebouton' href='nfo-edit.php?id=$id'>".T_("NFO_EDIT")."</a></center>");
end_frame();
}
}//has nfo
No users online
Torrents
Members
Online