-
Posts
2773 -
Joined
-
Last visited
-
Days Won
3
Content Type
Profiles
Forums
phpVMS Resources
Downloads
Everything posted by simpilot
-
Can you post the entire file to pastebin so I can look at it, I dont see a second foreach call that would be line 44.
-
Been looking into it, was thinking some type of identifier for tour flights - a T or something. I just need to find a way to intergrate it without getting into the core files so it is not affected by an update of the core system.
-
Nice work guys!
-
This could get fairly detailed. I would to ask what would trigger the auto award? Hours, flights, miles, landing rate, screenshot contests, all of the above? You will have to figure out an identifier to catch in order to apply the award, probably a multi-function listener would be best but, I think I would add it to the maintenace operations that way it would not run on every PIREP submittial or the same time and memory issues will probably appear that we have had in the PIREP approval process for airlines with large databases.
-
You could just use the coding from the downloads section as an example and add a db table for the corolation and one column to the awards table for the section the award would be in. Probably a good thing to add to the feature requests thread.
-
It is an error from running out of execution time and memory availability on your server. Pre-beta versions recalculate the va's hours on every PIREP approval and once you get a significant amount of PIREPs in the dtabase it becomes a long task. It has been chnaged in the beta version and the function has been moved elsewhere to avoid the issue. The quick fix is to comment out line 317 of your /admin/modules/PIREPadmin/PIREPadmin.php file; StatsData::UpdateTotalHours(); Doing this will cause your va's total hours not to advance on PIREP approval but you could build the function into the maintenance file if you are running it daily. Or you could incorporate the new functions from the beta into your install, or completely upgrade to the beta.
-
Please open a support ticket on my site with the details -> http://www.simpilotgroup.com/hosting/submitticket.php Thanks
-
Is it shared, dedicated, VPS? If you have access to the php.ini file you need to remove the restiction of file operators for the server.
-
You can use the above referenced function and just ask for 1 return, that would give you the worst, then add a WHERE DAY(submitdate) = DAY(NOW()) or something like that into the function to granb the worst from that day. You will have to code for the reality of no data at all being found as well to avoid a foreach loop error.
-
open_basedir restriction in effect What type of hosting are you on? If you have access to the php.ini the above needs to be changed to start.
-
Hope you dont mind, I made a few changes to your code to use curl instead of open url and also not to use GET. Using it in this manner will save a copy of the ivao file to your own server and update it if it is more than 5 minutes old when the script looks for it. also to get the map now use: www.yoursite.com/index.php/liveflights/map/"ICAO OF AIRLINE YOU ARE LOOKING FOR" I posted it at pastebin for your review -> http://pastebin.com/h8Y38yDs
-
You should be using cURL to open offsite files, allow_url_fopen creates a fairly large security risk for your site and gives even the most novice hackers an avenue to import script into your source code. allow_url_fopen is disabled by server administrators almost 100% of the time and cURL is now the standard. Nabeel has built cURL right into phpVMS to make it even easier as long as it is enabled on your server. There is no reason that any reputable host should not have cURL enabled, the free hosts are another story, as it is another reason for them to upsell you to paid hosting. instead of; $file = file($servers); you could use; $data = new CodonWebService(); $file = @$data->get($servers);
-
Did you insert the tables for the exam center into your database?
-
Thats going to try to pull from the controller, I am not sure how you have done it but if you just have it in the data model you can get the info direct from there; $data = TouchdownStatsData::top_landing_this_month('10'); Your function in the data model should look something like this if you after 10 records from the current month; public function top_landing_this_month($howmany) { $today = getdate(); $month = $today[mon]; $year = $today[year]; $query = "SELECT * FROM phpvms_pireps WHERE landingrate <'0' AND MONTH(submitdate) = '$month' AND YEAR(submitdate) = '$year' ORDER BY landingrate DESC LIMIT $howmany;"; return DB::get_results($query); }
-
You need to rename one of the two occurances of get_all_stats
-
I am removing the link to the AF site, locking the thread and suspending the account for 7 days, as you have stated you want your account removed anyway. Nabeel can make the decision as to deleteing the account in whole. As much as I do not agree with what you have done, we as a group just seem to continue to feed you what you ultimatly want, confrontation....
-
There is a bracket or something missing in the file and you have the same name for two functions - get_all_stats - you need to rename one of them to something different but I can not see what you have missing without seeing the entire file. It could be a } or a ; missing somewhere above line 23.
-
When you call it in your template, you will need to assign data to the $month and $year variable -> ie '8', '2011'
-
Have you also added the line to the controller to load the variable into the template?
-
I think this may be what you are looking for -> http://forum.phpvms.net/topic/2989-touchdownstats-10/page__view__findpost__p__21408
-
Schedule Search (Airline, Aircraft, Arrival, Departure)
simpilot replied to simpilot's topic in Simpilot Group Addons
Nabeel has done an excellent job in advancing the schedule search functions in the newest beta cersion including not loading all the schedules at first for those that have large schedule databases. IMO the beta is a better choice right now over the 934 stable if schedule searching is something that is at the top of your list, there are few other small bugs that are easily overcome and will be fixed in the near future I believe. I am building all the new sites I put out on the beta unless I am specifically asked not to. The latest beta download link is always in the build log board of the forum, or you can go directly to the downloads page and find it at http://downloads.phpvms.net BTW: Awesome integration of the Gooey menu on your site! Been thinking about using it myself. -
Are you passing the month and year to the $month and $year variables? If so, are there any PIREPS with landing rates for the month and year you are passing?
-
Schedule Search (Airline, Aircraft, Arrival, Departure)
simpilot replied to simpilot's topic in Simpilot Group Addons
Are you runing beat or the 934 stable? If it is beta, there are some changes that affect the module and with the new search template youcan search by aircraft and airline in addition to departure and arrival so the module becomes somewhat dated. -
Please PM me your email address or open a support ticket on my site, Thank You.
-
You can put it in any of the data class models really, where ever you would like it. If you put it in the touchdowndata.class.php file you can then just call it in your controller or view using; <?php $variable = TouchdownStatsData::get_monthly_landingrate('month', 'year', 'howmany'); ?> Then the $variable will be filled with your array to build your table with.