Jump to content

Recommended Posts

Posted

Hello there,

I have designed a pilot centre for my pilots, and I have made a custom banner just for the centre. In the layout.tpl, I have a jQuery sliding banner defined for all of the sites, but I was wondering whether there is a way to exclude it in the pilot center, so I end up with a single banner, and not two of them?

Regards,

HighFlyer

Posted

You can exclude any piece of code by using // for single lines or <!-- --> for larger sections of text.

<html> 
bla bla bla
//single line of excluded text
<!--

a big portion of excluded text

-->
bla bla
</html>

If you want some content appearing in the homepage only remove it from the layout.tpl and add it to the frontpage_main.tpl (I believe that is the name)

Or you can add it to a separte template file that you will include whenever you need it.

Posted

Thanks for your reply, but this is not what I meant exactly.

My question was more like, if there is a way to exclude code from a template? I.e main jQuery banner is set in layout.tpl to display for all pages, but I want to exclude it for profile_main.tpl.

Posted

I don't think so.

What you can do is have it in a separate .tpl and just include it when you need it :)

<?php
include('banner.tpl');
?>

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