bass Posted March 9, 2017 Report Share Posted March 9, 2017 Hi all.I did a widget for other sites that would show information about my company. Has the ability to display code on other sites. Pilots <!-- Запрос на получения данных Новые пилоты--> <?php $xml = simplexml_load_file("http://exemple.ru/lib/rss/latestpilots.rss"); $json = json_encode($xml); $data = json_decode($json, TRUE); ?> <table width="500" border="0" cellspacing="0" cellpadding="0"> <tr> <td>Pilots</td> </tr> <?php foreach($data['channel']['item'] as $row) { ?> <tr> <td><?php echo $row['title'];?></td> </tr> <?php } ?> </table> <!--конец--> Reports <!-- Запрос на получения данных Крайний рейс--> <?php $xml = simplexml_load_file("http://exemple.ru/lib/rss/latestpireps.rss"); $json = json_encode($xml); $data = json_decode($json, TRUE); ?> <table width="500" border="0" cellspacing="0" cellpadding="0"> <tr> <td>Pireps</td> <td>Pilots</td> </tr> <?php foreach($data['channel']['item'] as $row) { ?> <tr> <td><?php echo $row['title'];?></td> <td><?php echo $row['description'];?></td> </tr> <?php } ?> </table> <!--конец--> Quote Link to comment Share on other sites More sharing options...
Moderators ProSkyDesign Posted March 15, 2017 Moderators Report Share Posted March 15, 2017 (edited) On 9/3/2017 at 3:55 AM, bass said: Hi all.I did a widget for other sites that would show information about my company. Has the ability to display code on other sites. Pilots <!-- Запрос на получения данных Новые пилоты--> <?php $xml = simplexml_load_file("http://exemple.ru/lib/rss/latestpilots.rss"); $json = json_encode($xml); $data = json_decode($json, TRUE); ?> <table width="500" border="0" cellspacing="0" cellpadding="0"> <tr> <td>Pilots</td> </tr> <?php foreach($data['channel']['item'] as $row) { ?> <tr> <td><?php echo $row['title'];?></td> </tr> <?php } ?> </table> <!--конец--> Reports <!-- Запрос на получения данных Крайний рейс--> <?php $xml = simplexml_load_file("http://exemple.ru/lib/rss/latestpireps.rss"); $json = json_encode($xml); $data = json_decode($json, TRUE); ?> <table width="500" border="0" cellspacing="0" cellpadding="0"> <tr> <td>Pireps</td> <td>Pilots</td> </tr> <?php foreach($data['channel']['item'] as $row) { ?> <tr> <td><?php echo $row['title'];?></td> <td><?php echo $row['description'];?></td> </tr> <?php } ?> </table> <!--конец--> It works with wordpress? I did a frame in my wordpress and works better. Take a look =) www.travelskyalliance.com *Attached pics of Pilot_list and last_reports Edited March 15, 2017 by joooseb Quote Link to comment Share on other sites More sharing options...
bass Posted March 15, 2017 Author Report Share Posted March 15, 2017 I haven't tried it, but I think that will work. 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.