Advertisement:

Author Topic: Fatal error: Call to undefined function: db_query() in /home/nextgene/public_htm  (Read 7124 times)

Offline MegaV1

  • Jr. Member
  • **
  • Posts: 190
Fatal error: Call to undefined function: db_query() in /home/nextgene/public_html/forum/TopicSolvedPdb.php on line 37

i got that when i try to install
Topic Solved MOD

i have to install this mod manually, so what do i do now?

Offline kegobeer

  • SMF Friend
  • SMF Hero
  • *
  • Posts: 3,994
  • Gender: Male
  • I am ninja!
    • The Kazebeer Family Website
You post your question on that mod's thread instead of starting a new thread.
"The truth of the matter is that you always know the right thing to do. The hard part is doing it." - Norman Schwarzkopf
Posting and you (Click "WATCH THIS MOVIE")

Offline MegaV1

  • Jr. Member
  • **
  • Posts: 190
i get this error for most the the mods that need db changes

Offline MegaV1

  • Jr. Member
  • **
  • Posts: 190
Code: [Select]
$request = db_query("
SHOW COLUMNS
FROM {$db_prefix}messages
LIKE 'topicSolved'", __FILE__, __LINE__);
$need_add = mysql_num_rows($request) == 0;
if ($need_add)
db_query("
ALTER TABLE {$db_prefix}messages
ADD `topicSolved` TINYINT(4) DEFAULT '0' NOT NULL", __FILE__, __LINE__);

How do i perform this manually

Offline Oldiesmann

  • Lead Developer
  • SMF Super Hero
  • *
  • Posts: 24,114
  • Gender: Male
  • Ask me about the function DB :)
    • oldiesmann on Facebook
    • Oldiesmann on GitHub
    • http://www.linkedin.com/in/michaeleshom on LinkedIn
    • @oldiesmann on Twitter
    • Archie Comics Fan Forum
Add this to the top of the file (right after the <?php tag):

Code: [Select]
include_once('SSI.php');
That will let you run the script manually.

Offline MegaV1

  • Jr. Member
  • **
  • Posts: 190
well, i went to PHP MyAdmin and did it manually, now this is what i got
Code: [Select]
You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near 'AND ID_MSG != 2240' at line 3
File: /home/nextgene/public_html/forum/Sources/Post.php
Line: 2023

Note: It appears that your database may require an upgrade. Your forum files are currently at version SMF 1.0.7, whereas your database is at version SMF 1.0.2. It is recommended that you execute the latest version of upgrade.php.

i tired to fix it and this is what i got
Code: [Select]
2: Missing argument 2 for db_query()
File: /home/nextgene/public_html/forum/Sources/Subs.php
Line: 216

does anyone know how
Code: [Select]
, __FILE__, __LINE__means?

Offline MegaV1

  • Jr. Member
  • **
  • Posts: 190
on my who's online thingy, it says

25 4 Spiders, Guests, 0 Buddies, 9 Users

how can i change it to say

4 Spiders, 25 Guests, 0 Buddies, 9 Users

or

25 Guests, 4 Spiders, 0 Buddies, 9 Users