CEO North Air Posted February 22, 2010 Report Posted February 22, 2010 So this will be my last request at the moment. Well, I tried to add an award called "100 Flights". When I added that adward to a pilot I searched at the office for his profile, but instead of the award-picture I´m just able to view the name of the award "100 Flights". How to change the data to show the pictures? Please help and reply. Have a nice day and best regards from Germany Tobi CEO North Air Quote
Administrators simpilot Posted February 22, 2010 Administrators Report Posted February 22, 2010 Look for lines 80-82 in your pilot profile template (profile_main.tpl) the instructions are there. It needs to be uncommented and placed where you would like it to display. /* To show the image: <img src="<?php echo $award->image?>" alt="<?php echo $award->descrip?>" /> */ 1 Quote
CEO North Air Posted February 25, 2010 Author Report Posted February 25, 2010 Hi, thanks four your help! Question, where to find the profile_main.tpl? I searched a couple of times but don´t find the tpl.... Thanks! Quote
Administrators Nabeel Posted February 25, 2010 Administrators Report Posted February 25, 2010 They're all in core/templates. Remember to move the ones you change to your skin's folder Quote
CEO North Air Posted February 25, 2010 Author Report Posted February 25, 2010 Well, thanks again for your help, but I tried a lot and it won´t work. The instruction says: /* To show the image: <img src="<?php echo $award->image?>" alt="<?php echo $award->descrip?>" /> */ Well, now I guess to put anywhere between the following lines, but where exactly? <p> <strong>My Awards</strong><br /> <?php if(!$allawards) { echo 'No awards yet'; } else { /* To show the image: <img src="<?php echo $award->image?>" alt="<?php echo $award->descrip?>" /> */ ?> <ul> <?php foreach($allawards as $award){ ?> <li><?php echo $award->name ?></li> <?php } ?> </ul> <?php } ?> </p> What does it meen to change the skin´s folder? Thank you once again for your help! Quote
Administrators simpilot Posted February 25, 2010 Administrators Report Posted February 25, 2010 You can put that line of code <img src="<?php echo $award->image?>" alt="<?php echo $award->descrip?>" /> anywhere within the foreach command for the awards section, or you can leave it right where it is for it to work as well but the biggest thing is that you need to get the /* and */ from around it, that is telling the browser to ignore everything inside of the comments marks - ie "it is commented out". Also you should create a folder in the lib/skins folder for your own skin with your own name to place your edited templates in, otherwise when you do an update the templates, and all your work, will be overwritten. Quote
CEO North Air Posted February 25, 2010 Author Report Posted February 25, 2010 Well I tried what you said but when I browses my profile there won´t be shown the image of the award, just the name. Here is the code I added: <p> <strong>My Awards</strong><br /> <?php if(!$allawards) { echo 'No awards yet'; } else { To show the image: <img src="<?php echo $award->image?>" alt="<?php echo $award->descrip?>" /> ?> <ul> <?php foreach($allawards as $award){ ?> <li><?php echo $award->name ?></li> <?php } ?> </ul> <?php } ?> </p> Any mistages insert? Thanks again for your help! Your doing a great job! Quote
Administrators simpilot Posted February 25, 2010 Administrators Report Posted February 25, 2010 Move it within the foreach like this -> <ul> <?php foreach($allawards as $award){ ?> <li><?php echo $award->name ?></li> <li><img src="<?php echo $award->image?>" alt="<?php echo $award->descrip?>" /></li> <?php } ?> Quote
Tato123 Posted June 12, 2010 Report Posted June 12, 2010 this is good for pilot center but if i click to another pilot i don't see their awards. What is the file .TPL for see in all pilots? Quote
Administrators Nabeel Posted June 13, 2010 Administrators Report Posted June 13, 2010 pilot_public_profile.tpl I believe Quote
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.