Jump to content

simpilot

Administrators
  • Posts

    2773
  • Joined

  • Last visited

  • Days Won

    3

Everything posted by simpilot

  1. Servetas makes a valid point as the url shows no sign of the "ivao" part of the string. I would also look over the documentation here -> http://forum.phpvms....and-add-ons-r25 - specifically the section about passing variables. I would guess you are not processing the GET data correctly within the controller if the "ivao" string is not the issue. -------------------------------------------------------------------------------------- Passing Variables Variables can be passed in several different ways. We'll use two different URLs and functions to demonstrate index.php/moduletest/pageone/apple/red index.php/moduletest/pagetwo?fruit=apple&color=red The code: class ModuleTest extends CodonModule { public function pageone($fruit='', $orange='') { echo "The fruit is an {$fruit} and the color is {$orange}"; } public function pagetwo() { echo "The fruit is an {$this->get->fruit} and the color is {$this->get->orange}"; } } As you can see, the "pageone" method is cleaner - the function parameters will be the variables after the function name in the URL, in the order they appear in the URL. The "pagetwo" method is the more "traditional" way of doing things, but they are essentially the same thing. To access the variables in the query string you use: $this->get->[variable name]
  2. Most desireable would be to do it in your controller and load the data into a new variable set and pass that to the template, but you can do it right in the template where you want it to display as well. It is not an actual database call at that point so the php functions being in the template is not a big deal at that point in my opinion.
  3. Are the flights in the database multiple times when thsi happens or just one row as the original poster? If they are only in the data table one time there must be something in the code that is loading the flights multiple times but I would think if that was the case it would display the same amount for each flight. If they are in the table multiple times I would look at timeout errors for ACARS users and/or the site. Have you enabled error logging to see if there is anything showing up there? How to get debug info -> http://forum.phpvms.net/page/index.html/_/getting-started/debugging-issues-r31
  4. You should have it in the /core/common/ folder, this base file is part of the standard phpVMS package.
  5. Looks like you are using the last PIREP for both flights. You will need to use the pilots bids, if there are any for the next flight, unless you are using some type of dispatch system. As Vangelis posted, you will also need to fill these variables, preferably in the controller, if you are not doing so already.
  6. Looks like the template is based on bootstrap and looking atthe code you have a lot of new rows ie <div class="row-fluid"> each time you start a new row it should clear everything prior and start after the previous content. I would look to see where all your rows start and end and make sure they are all closed properly for starters. If you are using an editor with a "Back" feature work your way backwards until the issues resolves itself and then look at the changes you made at that point.
  7. The database table is set up as a time field, so even if you submit a single number it is going to format it to the 00:00:00 format. The data is submitted in the SubmitPIREP function in the PIREPS.php module controller. You are starting to hack into core files that will be overwritten if you ever update though. I am assuming that you are trying to display only a number of hours and no minutes or seconds so possibly a better solution would be to just break up the data using an explode statement and then just displaying the hours piece. Something like; $hours = explode(':', $hoursvariable); echo $hours[0];
  8. It looks as though the question has been answered but just to confirm, as long as you only delete the charters within the schedules database there will be no change in your statistics. If you start deleting PIREPs created using charter flights the stats would be changed.
  9. http://forum.phpvms.net/topic/18860-i-have-a-xxxxxxtpl-file-not-found-error/
  10. I think it was the version conflict more than anything, it seems to be a common theme in the vanilla support forums.
  11. It is something that was built into the Entrance Exam module but was never adapted to the Exam Center module.
  12. You can remove $con=mysqli_connect("localhost","spiritc1","H0llsh3l@3","spiritc1_phpvms"); // Check connection if (mysqli_connect_errno()) { echo "Failed to connect to MySQL: " . mysqli_connect_error(); } and mysqli_close($con); When you load the codon config file it is already making the database connection so another is not necessary. The styling is coming from the template file that the list uses. frontpage_recentpilots.tpl
  13. Reading through the comment threads on the plugin page it looks like the current version of jsconnect (1.4.1) available here -> http://vanillaforums.org/addon/jsconnect-plugin is actually written for vanilla 2.2 which is currently unreleased. I would try downloading the 1.0.3b version here -> http://vanillaforums.org/addon/jsconnect-plugin-1.0.3b and try replacing everything with that and see if that clears things up.
  14. Your best bet is to connect to the codon.config.php file and then use the built in functions on your external page. Reading back through the posts I think it all boils down to not getting the connection set correctly. Use the absolute route to the file. Try creating a page and just connecting to the file and running a command like; <?php MainController::Run('Pilots', 'RecentFrontPage', 5); ?> do not add anything else to start, it should dump out the pilots list if you have the connection correct.
  15. Are you uploading the css file to your skin folder or the default folder? Is it the same folder that the url for the css file is pointed at in your skin?
  16. What is the URL of the forum? What is the URL that the site is running on?
  17. As it is an open source project it can be up to the community to update it. Nabeel has in the past merged updates and fixes through pull requests into the beta version on GitHub. Anyone can create a pull request with their changes. Unfortunately open source projects more often than not end up in this situation, life happens and priorities change.
  18. The OFC package is third party. I do not know when/if they will be updating it to work with newer versions of PHP. As far as phpVMS is concerned, it was written when php 5.3 was the latest greatest thing and has not been adapted to the newer versions of PHP. I do not know if it will ever be re-written in whole. There are a lot of folks that have contributed minor fixes on the version on the GitHub account that address certain issues with using it with later versions of PHP that you can download from there instead of the official download.
  19. Folder permissions for the folder that it is saved in maybe?
  20. My 2 cents -> http://forum.phpvms.net/topic/21032-phpvms-admin-panel-bug/page__st__20#entry113081
  21. I would guess that you are using a PHP version that the OFC script is not written for, ie PHP 5.4.x The OFC script is rather old and has not been updated recently and I have seen this error on many new installs that are using PHP 5.4.x versions. If this is not the case about the only thing I can suggest is starting through the error logs for the server and phpVMS. If you need to turn on error logging within phpVMS you can find that information here if you need it -> http://forum.phpvms.net/page/index.html/_/getting-started/debugging-issues-r31
  22. Try this, http://forum.phpvms.net/topic/18860-i-have-a-xxxxxxtpl-file-not-found-error/
  23. Where ever you have the code for your online list, you say it is on the home page so I would guess it is in the template for the homepage.
  24. Add this just prior to your loop $shown = array(); Add this to your loop for the users online. if(in_array($pilot->pilotid, $shown)) {continue;} else {$shown[] = $pilot->pilotid;} It should end up looking something like this <?php $shown = array(); foreach($usersonline as $pilot) { if(in_array($pilot->pilotid, $shown)) continue; else $shown[] = $pilot->pilotid; echo '<img src="'.Countries::getCountryImage($pilot->location).'" alt="'.Countries::getCountryName($pilot->location).'" />'; echo " {$pilot->firstname} {$pilot->lastname};} ?>
  25. You can add more permissions to the native permission set by manipulating the set in app.config.php. (You should move your edited permission set to your local.config.php file) Depending on how you do it you will most likely have to change the value for the "FULL_ADMIN" permission. The system the permission set is based on and how to use it is shown here http://www.litfuel.n...als/bitwise.htm
×
×
  • Create New...