mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-28 06:08:52 +00:00
Spot the mess ups
git-svn-id: file:///svn/phpbb/trunk@544 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
parent
fdfd3271d6
commit
168f0e5fd0
4 changed files with 17 additions and 15 deletions
|
@ -27,8 +27,8 @@
|
|||
//
|
||||
|
||||
// Debug Level
|
||||
//define(DEBUG, 1); // Debugging on
|
||||
define(DEBUG, 0); // Debugging off
|
||||
define(DEBUG, 1); // Debugging on
|
||||
//define(DEBUG, 0); // Debugging off
|
||||
|
||||
// User Levels <- Do not change the values of USER or ADMIN
|
||||
define(DELETED, -1);
|
||||
|
|
|
@ -86,42 +86,42 @@ function message_die($msg_code, $msg_text = "", $msg_title = "", $err_line = "",
|
|||
break;
|
||||
|
||||
case SQL_CONNECT:
|
||||
$msg_title = $lang['General_error'];
|
||||
$msg_title = $lang['General_Error'];
|
||||
$msg_text = $lang['Error_database_connect'];
|
||||
break;
|
||||
|
||||
case SQL_QUERY:
|
||||
if(!$msg_text)
|
||||
if($msg_text == "")
|
||||
{
|
||||
$msg_text = $lang['An_error_occured'];
|
||||
}
|
||||
if(!$msg_title)
|
||||
if($msg_title == "")
|
||||
{
|
||||
$msg_title = $lang['General_error'];
|
||||
$msg_title = $lang['General_Error'];
|
||||
}
|
||||
break;
|
||||
|
||||
case SESSION_CREATE:
|
||||
$msg_title = $lang['General_error'];
|
||||
$msg_title = $lang['General_Error'];
|
||||
$msg_text = $lang['Error_session'];
|
||||
break;
|
||||
|
||||
case GENERAL_ERROR:
|
||||
if(!$msg_text)
|
||||
if($msg_text == "")
|
||||
{
|
||||
$msg_text = $lang['An_error_occured'];
|
||||
}
|
||||
if(!$msg_title)
|
||||
if($msg_title == "")
|
||||
{
|
||||
$msg_title = $lang['General_error'];
|
||||
$msg_title = $lang['General_Error'];
|
||||
}
|
||||
break;
|
||||
}
|
||||
if(DEBUG)
|
||||
{
|
||||
if($line != "" && $file != "" && $msg_code != GENERAL_MESSAGE)
|
||||
if($err_line != "" && $err_file != "")
|
||||
{
|
||||
$msg_text .= "<br /><br /><u>DEBUG INFO</u></br /><br>Line: " . $err_line . "<br />File: " . $file;
|
||||
$msg_text .= "<br /><br /><u>DEBUG INFO</u></br /><br>Line : " . $err_line . "<br />File : " . $err_file;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -79,6 +79,7 @@ $lang['Next'] = "Next";
|
|||
$lang['Previous'] = "Previous";
|
||||
$lang['Goto_page'] = "Goto page";
|
||||
$lang['Page'] = "Page"; // Followed by the current page number then 'of x' where x is total pages
|
||||
$lang['Pages'] = "Pages";
|
||||
$lang['of'] = "of"; // See Page above
|
||||
$lang['Go'] = "Go";
|
||||
|
||||
|
@ -323,6 +324,7 @@ $lang['You_been_banned'] = "You have been banned from this forum<br>Please conta
|
|||
$lang['No_topics_post_one'] = "There are no posts in this forum<br>Click on the <b>Post New Topic</b> link on this page to post one";
|
||||
|
||||
$lang['General_Error'] = "General Error";
|
||||
$lang['An_error_occured'] = "An Error Occured";
|
||||
$lang['Error_database_connect'] = "Could not connect to database<br>Please check your configuration settings";
|
||||
$lang['Error_session'] = "Error creating session<br>Could not log you in, please go back and try again";
|
||||
$lang['Error_login'] = "Login Failed<br>You have specified an incorrect/inactive username or invalid password, please go back and try again";
|
||||
|
|
|
@ -154,11 +154,11 @@ if(!$result = $db->sql_query($sql))
|
|||
if(DEBUG)
|
||||
{
|
||||
$dberror = $db->sql_error();
|
||||
message_die(SQL_QUERY, "Couldn't obtain topic information.<br>Reason: ".$dberror['message']."<br>Query: $sql", "", __LINE__, __FILE__);
|
||||
message_die(SQL_QUERY, "Couldn't obtain topic information<br><br><b>DEBUG INFO</b><br><br>Reason : " . $dberror['message'] . "<br>Query : $sql<br>File : " . __FILE__ . "<br>Line : " . __LINE__ . "<br>", "");
|
||||
}
|
||||
else
|
||||
{
|
||||
message_die(GENERAL_MESSAGE, $lang['Topic_post_not_exist']);
|
||||
message_die(GENERAL_MESSAGE, $lang['Topic_post_not_exist']);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -178,7 +178,7 @@ if(!$total_rows = $db->sql_numrows($result))
|
|||
if(DEBUG)
|
||||
{
|
||||
$error = $db->sql_error();
|
||||
message_die(GENERAL_ERROR, "The forum/topic you selected does not exist.<br>Reason: ".$error['message']."<br>Query: $sql", "", __LINE__, __FILE__);
|
||||
message_die(GENERAL_ERROR, "The forum/topic you selected does not exist<br><br><b><u>DEBUG INFO</u></b><br><br>Reason : " . $error['message'] . "<br><br>Query : $sql<br><br>File : " . __FILE__ . "<br><br>Line : " . __LINE__ . "<br>", "");
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
Loading…
Add table
Reference in a new issue