Jump to content

Recommended Posts

Posted

I have tried about everything to show the image of the airline on the live map. I am able to show the image on the Departures and arrivals, just not the live map.

The currant code

<img src="<?php echo fileurl('/images/airline/'.$code.'png'); ?>" alt="<?php echo $airline->name;?>" />

This is what it is putting out

http://www.flyaka.com/images/airline/png

I

  • Members
Posted

The first thing that comes in my mind is that the $code variable doesnt bring a value how do you get the result ? if you do an echo $code what will come up ?

Posted

You seem to be missing a dot before the extension:

<img src="<?php echo fileurl('/images/airline/'.$code.'.png'); ?>" alt="<?php echo $airline->name;?>" />

With regards to the value of $code, print it out and see what happens

Jon

Posted

You seem to be missing a dot before the extension:

<img src="<?php echo fileurl('/images/airline/'.$code.'.png'); ?>" alt="<?php echo $airline->name;?>" />

With regards to the value of $code, print it out and see what happens

Jon

Still no go

http://www.flyaka.com/images/airline/.png

@Vangelis what exactly do you mean? I really have no clue what I am doing here.

  • Members
Posted

You can try and write for example

echo "This is the  $code";

and if something comes up on your website then the $code is returning a variable

But my question is how do you get the $code like with an sql query is it a result of a function or something else

i think you still have me on skype if not you are free to add me and contact me

best regards

Posted

I am using this ;)

<img src="<?php echo SITE_URL; ?>/images/airline/<%=flight.flightnum.substring(0,3)%>.png" >

which shows the airline logo corresponding to the flight

  • Members
Posted

I know it is already solved i just write the answer for the rest if they have the same question

you should put

<img src="<?php echo SITE_URL; ?>/images/airline/<?php echo $pirep->code; ?>.png"><br />

as <%=flight.code%> is a java script variable and we need a php variable to get the pilot's airline code

  • Like 1
Posted

How can put airline logo on frontpage - Latest Arrival?

    echo '<td align=center><img src="'.fileurl('/images/airline/'.$pirep->code.'.png').'" alt="'.$airline->name.'" /></td>'; 

  • 4 years later...

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...