*

Recent

Author Topic: Error Message in Admin Panel  (Read 4002 times)

CorzacGames

  • Newbie
  • *
  • Posts: 4
  • Force: +0/-0
    • Corzac Games
Error Message in Admin Panel
« on: November 17, 2014, 12:23:21 AM »
Hi, I am getting the following message in Settings -> Themes -> Inactive Themes, in the admin panel.

Fatal error: Call to a member function read() on a non-object in /home/jacoby2003/public_html/corzac-games.com/arcadegames/pages/admin/themes.php on line 78

The code is below. and line 78 is in red.

$path = $directorypath."templates";
   $directory = dir($path);
   while (false !== ($item = $directory->read())) {
      if ($item !== "." && $item !== "..") {
         $query = mysql_query("SELECT COUNT(*) FROM fas_themes WHERE template='$item'");
         $total = mysql_fetch_array($query);
         $total = $total[0];
         if($total == 0){
         echo'<tr>
            <td width="855px">'.$item.'</td>
            <td><a href="'.$domain.'/index.php?action=admin&case=themes&cmd=install&name='.$item.'">install</a></td>
         </tr>';

Thank you in advance for your help. Any suggestions on how to fix the error?

Dillon

  • Developer
  • Sr. Member
  • ******
  • Posts: 340
  • Force: +3/-0
    • Arcade Freak
Re: Error Message in Admin Panel
« Reply #1 on: November 17, 2014, 06:51:58 AM »
Go into your database and where it has the directory path add a / to the very end of it and it will solve that issue.

CorzacGames

  • Newbie
  • *
  • Posts: 4
  • Force: +0/-0
    • Corzac Games
Re: Error Message in Admin Panel
« Reply #2 on: November 17, 2014, 05:43:25 PM »
Thank you for your help, but I checked and the / is already there. It is not causing any issues, so I am not too concerned. :)

am-fs

  • Owner
  • Developer
  • Full Member
  • ******
  • Posts: 228
  • Force: +1/-0
    • Great Flash Games
Re: Error Message in Admin Panel
« Reply #3 on: November 17, 2014, 06:11:12 PM »
most likely the path is incorrect.

download the path.php to your root of your arcade

run => yoursite.com/path.php

make sure it is what your have in the admin and on the config file

CorzacGames

  • Newbie
  • *
  • Posts: 4
  • Force: +0/-0
    • Corzac Games
Re: Error Message in Admin Panel
« Reply #4 on: November 17, 2014, 09:05:40 PM »
Thank you so much. All fixed now. It was the config file that had an error. I looked at it earlier and just didn't see it, but a second look on your recommendation, and I saw the problem. thanks again!