jantorre Posted October 5, 2009 Report Share Posted October 5, 2009 Good day folks, in search for briefing for europe, I came across this page: http://www.flyingineurope.be/aviation_weather_maps.htm + Rain&Iceing page. Weather info posted as gif/png mostly, and could be used if youre airline flies in europe. I think the links are relativly stable aswell.(filenames etc) I tried it on the page im working on and it seems good.(now I have to learn how to resize external images using php...) Now for the airport maps issue. Im going to try making some snapshots of different aiport diagrams and linking them to aip of the specific airport. Though I guess it will have to be in a database or something because they are not centralized on one specific server? Like Norway uses http://www.ippc.no/norway_aip/current/main.html and sweden has http://www.lfv.se/sv/LFV/Flygtrafiktjansten/FPC/IAIP/AD-0-4/AD-2/ etc. Do you think this will be possible to make for a php/sql newbee?(all coding in general is new to me) I guess this Q should be in a different part of forum but dont want to make so many post: If I make a sql table like 'id' 'icao' 'link' 'link_snap' and use this as a base for the airport diagrams? Learning mutch everyday, love how everything is templated, but strugling learning the css etc. Cheers, Jan Tore (Virtual Norwegian ETA phpVMS 25th Oct) Quote Link to comment Share on other sites More sharing options...
Administrators Nabeel Posted October 5, 2009 Administrators Report Share Posted October 5, 2009 The site definately looks interesting. You could do that, except you don't need to make another table, you could just add it onto the existing airports table. Perhaps a column called charts, to which you can add links to the charts. Then on your pilots page you can access them by the column name. No special query or modifications to queries have to be written that way either. Quote Link to comment Share on other sites More sharing options...
jantorre Posted October 6, 2009 Author Report Share Posted October 6, 2009 Thank you for your input, ill add them to airport table insted. Even though I have no experience what so ever I find phpvms easy to work with, but I have one problem with my template, I think it has to do with the javascript? Our wrapper is set to 900pix and have a "menu" on the right with statistics etc. When going to flight schedules and some other pages, the content of the loaded pages goes down below the menu thingy, but in the main section if you know what I mean? Some screens of the issue: Most pages are ok: But schedulepage are looking ok when loading: But when jave is loaded it looks like this: Any clue where the error on my page is? in java script or the template beeing to narrow? Quote Link to comment Share on other sites More sharing options...
Administrators Nabeel Posted October 6, 2009 Administrators Report Share Posted October 6, 2009 That's because that width of the left column is too wide, so it moves below so it can fit. If you see the <hr> horizontal rules, they span all the way across Quote Link to comment Share on other sites More sharing options...
jantorre Posted October 22, 2009 Author Report Share Posted October 22, 2009 Bringing up this again. Can somebody help me with the code to echo/print the link from database? The links are placed in the phpvms_airports table and row name is 'charts' Quote Link to comment Share on other sites More sharing options...
Administrators simpilot Posted October 22, 2009 Administrators Report Share Posted October 22, 2009 Try this, it should give you the raw data... <?php $data = (OperationsData::GetAllAirports()); foreach ($data as $airport) { echo $airport->charts; } ?> Quote Link to comment Share on other sites More sharing options...
jantorre Posted October 22, 2009 Author Report Share Posted October 22, 2009 It works, but as you said, it sends all data in the link. So if I want to use this to extract specific depicao / arricao in the briefing for a schedule? In words I want it to show the 'chart' from the current $schedule->depicao / arricao(im crap at explaining my thoughts...) Thank you Quote Link to comment Share on other sites More sharing options...
Administrators simpilot Posted October 22, 2009 Administrators Report Share Posted October 22, 2009 You will have to declare $icao somewhere ahead of this - I am not sure if this is what you are trying to do. <?php $data2 = (OperationsData::GetAirportInfo('$icao')); echo $data2->charts; ?> Quote Link to comment Share on other sites More sharing options...
jantorre Posted October 22, 2009 Author Report Share Posted October 22, 2009 I want to use this with the pilot briefing. the icao should be determind by the current schedule being briefed. the original links uses this code: <a href="http://www.airnav.com/airport/<?php echo $schedule->depicao?>#ifr" target="_blank"> I want this to get the complete link from the database, not fill in the blanks like the one above. I managed to load the preview snap using this code: <img border="0" src="http://virtualnorwegian.net/uploads/chart/<?php echo $schedule->depicao?>.gif" width="387px" height="594px" alt="No chart available" /></a> shot of table phpvms_airport: Quote Link to comment Share on other sites More sharing options...
Administrators Nabeel Posted October 22, 2009 Administrators Report Share Posted October 22, 2009 So you'll do something like: <?php $data2 = OperationsData::GetAirportInfo($schedule->depicao); echo '<img src="'.$data2->charts.'" />'; ?> Quote Link to comment Share on other sites More sharing options...
Administrators simpilot Posted October 22, 2009 Administrators Report Share Posted October 22, 2009 is this what you are trying to do... <img border="0" src="<?php $data = OperationsData::GetAirportInfo('$schedule->depicao'); echo $data->chart; ?>"width="387px" height="594px" alt="No chart available" /> sry - looks like I was writing while Nabeel was posting :-[ Quote Link to comment Share on other sites More sharing options...
jantorre Posted October 22, 2009 Author Report Share Posted October 22, 2009 Its not the preview images, I solved my self using home made library. 1.site loads schedule info, and displays it. 2.images for DEPICAO and ARRICAO is loaded from my library 3.Link in the images is loaded from phpvms_airport->charts based on the $schedule->depicao Bold text being my problem It should use $schedule->depicao to know witch airport from "phpvms_airports->charts" to use. I better learn how to comunicate better ;D Quote Link to comment Share on other sites More sharing options...
Administrators simpilot Posted October 22, 2009 Administrators Report Share Posted October 22, 2009 Do you mean the link you are directed to if you click on the images? Quote Link to comment Share on other sites More sharing options...
Administrators simpilot Posted October 22, 2009 Administrators Report Share Posted October 22, 2009 Like this? This would send you to the link out of the db when you click on the image... <a href="<?php $data = OperationsData::GetAirportInfo('$schedule->depicao'); echo $data->chart; ?>" target="_blank"> <img border="0" src="http://your_image_path" width="387px" height="594px" alt="No chart available" /></a> Quote Link to comment Share on other sites More sharing options...
jantorre Posted October 22, 2009 Author Report Share Posted October 22, 2009 BINGO, thats what I want to do I tried the code, but the link says "http://virtualnorwegian.net/index.php/schedules/brief/" even though in the table(chart) it is "http://vaccsca.org/pilot/airport/engm" So still a problem somewhere... ??? The complete code for the departure chart thingy: <a href="<?php $data = OperationsData::GetAirportInfo('$schedule->depicao'); echo $data->charts; ?>" target="_blank"> <img border="0" src="http://www.virtualnorwegian.net/images/charts/<?php echo $schedule->depicao?>.gif" width="387px" height="594px" alt="No chart available" /></a> Thank you Quote Link to comment Share on other sites More sharing options...
Administrators simpilot Posted October 22, 2009 Administrators Report Share Posted October 22, 2009 Take the quotes out of the ('$schedule->depicao') field. It should be.. ($schedule->depicao) Quote Link to comment Share on other sites More sharing options...
jantorre Posted October 23, 2009 Author Report Share Posted October 23, 2009 It works! Thank you, this boosted the site quite a bit, now they don't have any excuses not to use charts ;D Thanks Simpilot and Nabeel, if I could hug you, I would Nabeel: Possible feature request for the future for none US users: "Have the option for none US users when adding airports, be able to add chart link to the database via admin panel" and select if they want to use the us version or custom link database. Quote Link to comment Share on other sites More sharing options...
Administrators Nabeel Posted October 23, 2009 Administrators Report Share Posted October 23, 2009 It works! Thank you, this boosted the site quite a bit, now they don't have any excuses not to use charts ;D Thanks Simpilot and Nabeel, if I could hug you, I would Nabeel: Possible feature request for the future for none US users: "Have the option for none US users when adding airports, be able to add chart link to the database via admin panel" and select if they want to use the us version or custom link database. Has been added for the next version Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.