Jump to content

Strider

Members
  • Posts

    1816
  • Joined

  • Last visited

  • Days Won

    51

Posts posted by Strider

  1. I have added this to StatsData.class and had to make a small change but not major:

    In StatsData.class.php:

       public function getTotalPassengersPilot($pilotid)
       {
           $query = "SELECT SUM(`load`) AS passengers FROM ".TABLE_PREFIX."pireps WHERE pilotid = $pilotid AND accepted = 1";
           $result = DB::get_row($query);
           if (!$result) return 0;
           return ($result->passengers == '') ? 0 : $result->passengers;
       }
    
    

    In your pilots_list or pilot_public_profile.tpl:

    <?php echo StatsData::getTotalPassengersPilot($userinfo->pilotid);?>
    
    

  2. In the schedule_briefing.tpl for the button where it says onclick and to put your full web address put this code:

    <?php echo SITE_URL?>/index.php/Simbrief

    It means you dont have to go in to make that change, it will already be there.

  3. I found the problem, and have fixed it.

    From line 30 to 46 in the CodeShareData.class.php file replace the code with the following:

    public function save_new_codeshare($schedid, $airline, $image)
    {
    	$query = "INSERT INTO phpvms_codeshares (schedid, airline, image)
    VALUES ('$schedid', '$airline', '$image')";
    
    	DB::query($query);
    }
     public function save_edit_codeshare($schedid, $airline, $image, $id)
    {
    	$query = "UPDATE phpvms_codeshares SET
    schedid='$schedid',
    airline='$airline',
    image= '$image',
    WHERE id='$id'";
    
    	DB::query($query);
    }
    
    

  4. If you are worried about an OOM error, then you have two options. First delete some files such as your fleet files and host them else where and link them to your fleet page. Or you could upgrade your hosting package, to increase the space.

×
×
  • Create New...