22845 Posts in 9589 Topics by 2801 members
|Go to End|
15 November 2010 at 11:03am
I have added a company tagline which I can access from ss templates using $SiteConfig.Tagline. However I am having trouble when trying to access the tagline within a loop:
<% control Branches %>
<div class="office_location"><a name="$Name" id="$Name"></a>
<h2>$Name CDP Office</h2>
<div class="office_map"> <a href="$GoogleMap" target="_blank"><img src="$LocationMapImage.LocationMap.URL" alt="View the $Name CDP office on Google maps" title="View the $Name CDP office on Google maps" width="$LocationMapImage.LocationMap.Width" height="$LocationMapImage.LocationMap.Height" /></a>
<p class="view_google_map"><a href="$GoogleMap" target="_blank" title="View the $Name CDP office on Google maps">View Google map directions »</a></p>
<div class="clear"> </div>
<% end_control %>
I suspect the problem may be when I am accessing the branches it is unable to locate information outside of that. Is there any way I could make it globally acessiable.
Any help would be greatly appreciated. Cheers!
- Rich McNabb
15 November 2010 at 11:35am
yep, when in a loop you move to that "context". to access the top level context try...
15 November 2010 at 12:10pm
Thanks swaiba that works great!!
I have one more question about accessing another page. I have 3 training pages:
TrainingIntro.php (introduction with a training schedule download)
> TrainingHolder.php (course subjects listed)
>TrainingPage.php (course overview)
On TrainingIntro.php I can access the the pdf download by using $TrainingScheduleDownload.URL. However on TrainingPage.php I can't and am not sure how I would go about accessing something that is 2 levels above.
Would I need a function that gets the info from TrainingIntro or can I specify a page directly using something like (training-intro)$TrainingScheduleDownload.URL
Any help would be fantastic. Thanks again.
15 November 2010 at 1:31pm
|Go to Top|