Jump to content

nexiss

Members
  • Posts

    52
  • Joined

  • Last visited

    Never

Everything posted by nexiss

  1. Thats brilliant, shame it only works for us airports
  2. I don't see why not, it could pick its data up from the pirep table I guess. But can't you already do this from the pilot profile page?
  3. Hi all I have been lokking at some of your sites and very impressive they are to. I see some of you have login boxes on your front pages, I was just wondering how you did that, is it a show template thing or are you cutting and pasting code from the login page? Sorry if this questions been asked before I did look throught the forum but couldn't find anything Karl
  4. Thats really weird, just incase there is a difference between files I have re attached the files I'm using. As before the FrontBids folder goes in your core/Modules folder and the Frontpage_recentbids.tpl goes in your lib/skins/yourskin folder. other than this I really don't know what else to suggest, Nabeel is the pro in this field, time permitting I guess Latest Front Page Bids.zip
  5. I would love to see a special flights facility kind of like what Brussels Virtual Airline does. Basicly the admin set up a, or several categories for example: 2009 World Tour, South americain VFR Tour, etc. Then they enter a series of flights under each category, when the tour or flights have been all completed and pireped in the correct order the pilots get an award. You could have a menu link for special flights when clicked brings up the list of categories and when a category is clicked it shows two links one for the filed pireps four that particular category or tour and one for a list of the flights for that particular category. There would need to be a way to deacivate the tour once it has ended because a 2009 would tour would only be valid for 2009 However these flights would not show under the normal schedule. If I was building an access database I know exactly how to do this but this is not access and my php is poor at best so apart from maybe two more tables in the database the rest is beyond my knowlege in php, so please please with sugar on top could you atleast consider this in a future update Nabeel. Many thanks Karl
  6. Hi Roger no I didn't change a thing, I used the original module, and just pasted the code you posted on here into my template, I then just called it into the front page using MainController::Run('FrontBids', 'RecentFrontPage'); FrontBids being the module and RecentFrontPage being the template Maybe a daft question but is your frontbids module folder definatly labeled "FrontBids" and your module inside that labeled the same? Note the capital letters! the same goes for when you call it in the front page.
  7. As long as your not charged by flight hours if you pay the one time purchase price, only if you lease it should you be charged per flight hour. Good idea though, makes it more realistic, but there neets to be an option to turn it off as not every VA will want to use it.
  8. Nabeel thanks for that, its very interesting reading. I will have to educate myself in writing php proberly! how people write it like a second language is beyond me, so I give enyone that can write it full credit. Roger what have you done and whats the problem, I have my bids showing up on the front page, but they are not clickable, thats my next hurdle! take a look at www.nexissair.co.uk please excuse the skin, I was just learning however am in the process of making a nice clean proffessional looking one as we speak. If I can help in any way just drop me a line Karl
  9. sweet as this works a treat! thankyou roger and Nabeel. Just to put my confusion to rest, what is the pilot info bit all about? I would love for someone to put a detailed tutorial up here expalining what the relation ship between templates and modules is, i.e. why certain bits of code go in templates and other bits of code go in the modules and how you would get the contents of a module to show with formating without a template i.e. the hub map. I would love to make lots of addons for this system, it has huge potential but I having trouble just getting my head around the basics. anyway thanks guys what I was trying to do works now reagrds karl
  10. Hi Roger I'm a bit confused! does this code replace the code in the tpl file? if so this is what confuses me as I can't see any code to output the latest bid fields, or has some thing changed in the module aswell, I did try this code in the tpl file but got a blank output
  11. Roger thats great, I'm not suprised about mistakes lol, in all honesty I'm suprised I got as far as I did! I'm not a coder I'm an aircraft handler lol, but as the old saying goes you don't know unless you try and the best way to learn is to have a go. look forward to you uploading it, more out of curiosity than anything so that I can see where I went wrong. Regards Karl
  12. I think if I read it right that code goes in a new module called ForumRegister
  13. Hi roger I have re zipped (LatestBidsV01.zip) the files (the ones I'm using) and tested it on a new install on my test machine, it works but only shows the last bid (problem I can't work out), I was hoping that someone would be good enough to pick this up and help us out a little but until they do I am going to have to try and work it out when I get some spare time! unfortunatley real planes at stansted take up much of my time at work lol also in the zip I have included the test module I used to tap the api based on Nabeels Tutorial which shows the last five bids, to use it, in the core/Modules/FrontBids folder rename "frontBids" to something else and rename "Test" to "FrontBids" then to call it go "http://www.yoursite.com/index.php/FrontBids" it is obviously raw data but you may be able to do something with it. please bare in mind that things are case sensitive If you have any success please let me know. Karl LatestBidsV01.zip
  14. Ok hope fully this is the last question on this matter I will need to ask lol when I use this script that nabeel put right for me it works a treat and all the placed bids show up However I created a module and a template with the code below: Module: <?php class FrontBids extends CodonModule { function RecentFrontPage($count = 5) { Template::Set('lastbids', SchedulesData::GetLatestBids($count)); Template::Show('frontpage_recentbids.tpl'); } } ?> and template <?php if(!$lastbids) { echo 'No bids have been made'; return; } foreach($lastbids as $lastbid); { ?> <style type="text/css"> <!-- .style2 { font-family: Arial; font-size: 10px; } --> </style> <p class="style2"><?php echo $lastbid->bidid . ' - ' . $lastbid->code.$lastbid->flightnum.' - '.$lastbid->depicao.' to '.$lastbid->arricao?> </p> <?php } ?> and used <?php MainController::Run('FrontBids', 'RecentFrontPage'); ?> in my front page to display it however it only show's the last bid placed not the last 5, I don't get it as this template is basically a modified recent reports template! I have looked at this and compared it with Nabeels excellent work for many hours now and cannot work out what the problem is. any ideas anyone? Karl
  15. Hi all there seems to be a problem I have tried it and there only seems to be one bid showing regardless of how many there are, if anyone can spot my mistake please let me know many thanks
  16. Hi all, I have finaly cracked it (well sort of) not bad for a php virgin lol I have to say I am no php coder and am stunned that I got this far! which to be honest I wouldn't have done if it wasn't for all you good people on the forum offering advice and Nabeel pointing me in the right direction, and his tutorials Feel free to use what I have done so far and if you fancy getting it to do what I need it to do (making links Clickable) and don't mind letting me have a copy please feel free, if no one develops it I will try eventually but I've got alot more learning to do first. Once again thankyou to all those that helped me. Regards Karl Latest Bids.zip
  17. ok this is where I'm at with this, I can get the latest bids to show on the front page, but they are not clickable but that is no real problem there. however was hoping to be able to make the bids so that when you click on them it takes you to a page giving a bit more detail and thats when things start to go wrong. The code in my module below generates this error: Parse error: syntax error, unexpected T_SWITCH, expecting ';' or '{' in O:wwwwebrootcoremodulesFrontBidsFrontBids.php on line 8 <?php class FrontBids extends CodonModule { public function Controller() switch($this->get->page) { Template::Set('lastbids', SchedulesData::GetLatestBids()); Template::Show('frontpage_recentbids.tpl'); break; case 'bidreport': $bidid = $this->get->id; $detailbid = SchedulesData::GetBid($bidid); if(!$detailbid) { echo '<p>This BID does not exist!</p>'; return; } Template::Set('detailbid', SchedulesData::GetBid($bidid)); Template::Show('bid_viewreport.tpl'); } } ?> Being a php virgin and learning as I go I am proberbly going about this all wrong how ever if someone wouldn't mind taking a look at the code and putting me right or letting me know if there is an easier way to do what I am trying to do it would be much appreciated Kind regards Karl p.s. If you don't mind having unlinked latest bids on your front page I will upload it to the modules and addons section, let me know
  18. Yes nice idea, I have a free day thursday so will sit dawn and have a proper bash at it, will let you know how I go
  19. hey Nabeel yes thanks that got it. am I right in thinking that if I want to shove the results over to a template for formating and to be called on the front page I use: Template Set: Template show: in the module and then create a template with the echo bit in it? and then call the template into the front page? many thanks Karl PS Roger if I can sort this out I will release it to the public under the modules and addons section so if you don't mind hanging on for a bit I'll let you know as soon as I crack it.
  20. Ok no panic I have got it to print the variables, I can't tell you how gratifying it is to get just one little snippet of code to work especially with a learning curve as steep as a mountain lol. Lets see if I can get the rest to work now lol
  21. Hi all I am trying really hard here with no success yet, I am starting from the ground up. I have created a folder in the modules folder and then created my .php file with the same name as the folder, the code is below <?php class FrontBids extends CodonModule { public function Controller() { $lastbids = SchedulesData::GetLatestBids(); foreach($lastbids as $lastbid); { echo '<pre>'; print_r($GetLatestBids); echo '</pre>'; } } } ?> but I get the error: Parse error: syntax error, unexpected $end in O:wwwwebrootcoremodulesFrontBidsFrontBids.php on line 19 this is mad I can't even follow Nabeel tutorial without screwing up. Please help
  22. Hi all I to have watch the tutorial and got this working, now my question is how do I pull this into a .tpl file with the correct hub name so that I can do some fancy design formating on the page?
  23. Hi guys Am I right in thinking this is the map that shows all the destinations you flight to? because I also cannot get this to show up and was wondering is you managed to resolve the problem. Could you please confirm the address needed to call it, I am using http://www.nexissair.co.uk/index.php/route_map but just get a blank page between my header and footer. regards Karl
  24. Hi Nabeel No I didn't, like I said my php skills are very poor and to be honest with you I have no idea what you mean by print_r($report) and inside the loop! I am just trying to reverse engineer what you have done for the latest pireps on the front page.
  25. Ok I have been bashing my head with this and here's where I'm at, I can get the pilot name to show but not the route number or bid ID, the code so far is below: <?php if(!$reports) { echo 'No bids have been made'; return; } foreach($reports as $report) { ?> <p><a href="<?php echo SITE_URL?>/index.php/Schedules/ShowLatestBids/<?php echo $report->bidid;?>">#<?php echo $report->bidid . ' - ' . $report->code.$report->routeid?></a> - <a href="<?php echo SITE_URL?>/index.php/profile/view/<?php echo $report->pilotid?>"><?php echo $report->firstname . ' ' . $report->lastname?></a></p> <?php } ?>code] Could anyone shed some light on it for me please Thank you so much Karl
×
×
  • Create New...