Jump to content

Problem integrating airline stats into static website


ahughes3

Recommended Posts

I have tried half a dozen php script plugins and they either don't work or they don't allow non local php execution meaning they are useless to me. I was hoping there would be a way to incorporate some of the data into I-Frames or something, maybe even just a direct database call. Unfortunately I just ain't clever enough to do it myself. I'm really disappointed with this. It's the one thing that would finish our website off, having the flight boards on the homepage :(

I will be adding them to the phpvms site we have anyway but it's just not the same. If anyone does dream up a way to do this then I would be mucho grateful.

Link to comment
Share on other sites

  • Moderators

I think that you can keep it "simple". You can create a simple page including this part of code:

<?php
require('./the directory of you codon.config.php file');
?>
<?php MainController::Run('Pilots', 'RecentFrontPage', 5); ?>

And after that, you can wrap it or create a simple iframe on your main website. What about this?

Link to comment
Share on other sites

I think that you can keep it "simple". You can create a simple page including this part of code:

<?php
require('./the directory of you codon.config.php file');
?>
<?php MainController::Run('Pilots', 'RecentFrontPage', 5); ?>

And after that, you can wrap it or create a simple iframe on your main website. What about this?

I have already tried to run that exact code using "short-exec-php" plugin within wordpress. The problem is that I don't think it allows remote connection as nothing is display and the page just gets broken.

I don't see how inserting the code into an iframe will change anything. It's wordpress that doesn't run the php. In an iframe, would the same not happen i.e. it breaks the page and code doesn't run. Maybe i'll try it just to see.

Link to comment
Share on other sites

  • 10 months later...

Well, it's been a while but I thought I'd update the post just the same. Having tried a whole bunch of ways to try and integrate the data from phpvms with wordpress I came to realise that with my coding skills it was never going to be an easy thing. To do what I wanted, I'd have to spend a bunch of money getting someone else to do it which I really didn't want to do.

So instead I just ditched my old website (very sad as it was an awesome site) and am now using phpvms as my main site. So now it should be easier to add data content to pages as I'm already finding out. My new challenge is making it look half decent :)

So far I've managed to get "recent flights" on the homepage. Can anyone point me to where I can find the code handlers for "currently booked" and "live flights" info so I can add those too?

Thanks

Link to comment
Share on other sites

So far I've managed to get "recent flights" on the homepage. Can anyone point me to where I can find the code handlers for "currently booked" and "live flights" info so I can add those too?

Thanks

Recent bids can be shown by

<?php MainController::Run('FrontBids', 'RecentFrontPage', 5); ?>

For live flights there's a few addons that are floating around to display a flight board otherwise you could use part of the acars map code to only display a table of flights currently operating.

Link to comment
Share on other sites

I am still having problems with content appearing on pages where I don't want it. I think it is because the layout.php file has the $page_content variable which in some cases is causing the content from layout.php to load twice. As the code that is appearing twice is static html code in the layout, I can't see any files that would be causing the issue and I've pretty much looked through all of them.

The only other thing I can think to do is physically create a separate module and template and dump the code in there and then call it inside of the layout.php file. I'll try that to see if it makes any difference and do an update.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...