| Install Mod Help | |
Posted: 06/07/2006 10:01 PM |
|
|
|
|
Hawk |
Posts |
178 |
Word Cnt. |
4,784 |
BDay |
Mar 26 |
Sign |
Aries |
Sex |
|
|
|
|
Joined: Oct 28, 2005
Local time: 12:55 PM
Location: New Zealand
|
|
|
|
|
|
I am getting this error in Easymod
Code:
|
FIND FAILED: In file [common.php] could not find:
$sql = "SELECT *
FROM " . CONFIG_TABLE;
if( !($result = $db->sql_query($sql)) )
{
message_die(CRITICAL_ERROR, "Could not query config information", "", __LINE__, __FILE__, $sql);
}
while ( $row = $db->sql_fetchrow($result) )
{
$board_config[$row['config_name']] = $row['config_value'];
}
|
Now i know why i'm getting this error, Nightrider taught me it's because the FIND is too long, i need to shorten it, BUT i can't remember HOW to shorten it... someone able to help? |
|
|
|
|
Back to Top |
|
|
| Re: Install Mod Help | |
Posted: 06/07/2006 10:17 PM |
|
|
|
|
Site Admin |
Posts |
30756 |
Word Cnt. |
2,628,678 |
BDay |
Jul 28 |
Sign |
Leo |
Sex |
|
|
|
|
Joined: Sep 25, 2004
Local time: 7:55 PM
Location: St Pete, FL
|
|
|
|
|
|
What MOD are you trying to install???
|
|
|
|
|
Back to Top |
|
|
| Re: Install Mod Help | |
Posted: 06/12/2006 8:42 PM |
|
|
|
|
Hawk |
Posts |
178 |
Word Cnt. |
4,784 |
BDay |
Mar 26 |
Sign |
Aries |
Sex |
|
|
|
|
Joined: Oct 28, 2005
Local time: 12:55 PM
Location: New Zealand
|
|
|
|
|
|
That's actually irrelevent in this question. I know that the FIND is too long, as that section above is EXACTLY the find that is there that i need to find. But i know it can't find it because the find is too long, as you taught me. I know i need to edit the find to make it shorter, but i can't remember, do i just delete the end of each line? |
|
|
|
|
Back to Top |
|
|
| Re: Install Mod Help | |
Posted: 06/13/2006 5:37 AM |
|
|
|
|
Site Admin |
Posts |
30756 |
Word Cnt. |
2,628,678 |
BDay |
Jul 28 |
Sign |
Leo |
Sex |
|
|
|
|
Joined: Sep 25, 2004
Local time: 7:55 PM
Location: St Pete, FL
|
|
|
|
|
|
The command that follows the FIND statement should be used to determine what to do with the FIND statement. That's why it was important to see the MOD script that you are attempting to install. If the following command is an AFTER, ADD or BEFORE, ADD, then shortening the FIND statement is the best option. But if the next command is a REPLACE WITH, then you might have to adjust it too...
|
|
|
|
|
Back to Top |
|
|
| Re: Install Mod Help | |
Posted: 06/24/2006 2:37 AM |
|
|
|
|
Hawk |
Posts |
178 |
Word Cnt. |
4,784 |
BDay |
Mar 26 |
Sign |
Aries |
Sex |
|
|
|
|
Joined: Oct 28, 2005
Local time: 12:55 PM
Location: New Zealand
|
|
|
|
|
|
It is a replace with, here it is here
Code:
|
#
#-----[ FIND ]------------------------------------------
#
$sql = "SELECT *
FROM " . CONFIG_TABLE;
if( !($result = $db->sql_query($sql)) )
{
message_die(CRITICAL_ERROR, "Could not query config information", "", __LINE__, __FILE__, $sql);
}
while ( $row = $db->sql_fetchrow($result) )
{
$board_config[$row['config_name']] = $row['config_value'];
}
#
#-----[ REPLACE WITH ]------------------------------------------
#
$sql = "SELECT *
FROM " . CONFIG_TABLE;
if( !($result = $db->sql_query($sql)) )
{
message_die(CRITICAL_ERROR, "Could not query config information", "", __LINE__, __FILE__, $sql);
}
while ( $row = $db->sql_fetchrow($result) )
{
if(!isset($board_config[$row['config_name']])) {
$board_config[$row['config_name']] = $row['config_value'];
}
}
|
|
|
|
|
|
Back to Top |
|
|
| Re: Install Mod Help | |
Posted: 06/24/2006 12:03 PM |
|
|
|
|
Site Admin |
Posts |
30756 |
Word Cnt. |
2,628,678 |
BDay |
Jul 28 |
Sign |
Leo |
Sex |
|
|
|
|
Joined: Sep 25, 2004
Local time: 7:55 PM
Location: St Pete, FL
|
|
|
|
|
|
Yep, the MOD author provided far too much information in the FIND statement and he was trying to modify far more than is necessary...
Ok, do this:
OPEN
Your MOD file
FIND
Code:
|
#
#-----[ FIND ]------------------------------------------
#
$sql = "SELECT *
FROM " . CONFIG_TABLE;
if( !($result = $db->sql_query($sql)) )
{
message_die(CRITICAL_ERROR, "Could not query config information", "", __LINE__, __FILE__, $sql);
}
while ( $row = $db->sql_fetchrow($result) )
{
$board_config[$row['config_name']] = $row['config_value'];
}
#
#-----[ REPLACE WITH ]------------------------------------------
#
$sql = "SELECT *
FROM " . CONFIG_TABLE;
if( !($result = $db->sql_query($sql)) )
{
message_die(CRITICAL_ERROR, "Could not query config information", "", __LINE__, __FILE__, $sql);
}
while ( $row = $db->sql_fetchrow($result) )
{
if(!isset($board_config[$row['config_name']])) {
$board_config[$row['config_name']] = $row['config_value'];
}
}
|
REPLACE WITH
Code:
|
#
#-----[ FIND ]------------------------------------------
#
$board_config[$row['config_name']]
#
#-----[ REPLACE WITH ]------------------------------------------
#
if(!isset($board_config[$row['config_name']])) {
$board_config[$row['config_name']] = $row['config_value'];
}
|
Save, upload, and try again using EM...
|
|
|
|
|
Back to Top |
|
|
|
| Information | |
|