Great theme!
I need help to insert the front-page slideshow with different pictures for different inner pages.
I tried to copy the

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

pwhiteside’s picture

Hi there,

If copying the slideshow from page--front.tpl.php to page.tpl.php results in a static image it sound like the javascript is not loading on the new page.

Instead, because I don't know how the js loads or is pulled by Drupal, you could try renaming page--front.tpl.php to page.tpl.php. If the slide show works on a normal page then it means that all the code needed is in that sheet.

If so I would instead of copying the slideshow out try copying the content from page.tpl.php to front--page.tpl.php, replacing the blocks. The end sheet then renamed to page.tpl.php

I hope this helps,

Best wishes, Phil the Whiteside of life.

Gabo11’s picture

Hi, thanks for the help!
Unfortunatly that doesn´t sole my problem.
I got the slideshow working also in inner pages (the problem was in template.php where i deleted the "if" line), but now i have the same slideshow for all the inner pages.
So the result is that i have 2 slideshow: 1 for the home and 1 for all the inner pages.

I need to be able to costumize the slideshow for every inner page.

I tried to create a new block to insert in the banner region (that now is active also in the inner pages) copying the code of the slideshow and activating the view only in the node that i want but, of course, it doesn´t work!!
I think that the block could be the best solution but i get only the empty frame of the slideshow and vertical navigation bottons.

I think that the problem is in the Javascript but my knowledge is zero in java.

New ideas??

Thanks!

gtsopour’s picture

Component: Miscellaneous » Code
Assigned: Gabo11 » gtsopour
Issue tags: +Bluemasters theme, +bluemasters
gtsopour’s picture

Hello Gabo11,
Firstly, I would like to thank pwhiteside for the continuous support.

Gabo11, I will try to guide you in order to achieve the result you want. I'll describe this process into discrete steps.

1. Firstly, you should also print Bluemasters's banner region in page.tpl.php. Currently banner region is only printed in page--front.tpl.php.
So copy the following code from page--front.tpl.php

<div id="banner">
<?php print render($page['banner']); ?>

<div class="main_view">
<div class="window">
<div class="image_reel">
<a href="<?php print url('node/3'); ?>"><img src="<?php print base_path() . drupal_get_path('theme', 'bluemasters') . '/images/slide-image-3.jpg'; ?>"></a>
<a href="<?php print url('node/2'); ?>"><img src="<?php print base_path() . drupal_get_path('theme', 'bluemasters') . '/images/slide-image-2.jpg'; ?>"></a>
<a href="<?php print url('node/1'); ?>"><img src="<?php print base_path() . drupal_get_path('theme', 'bluemasters') . '/images/slide-image-1.jpg'; ?>"></a>
</div>
<div class="descriptions">
<div class="desc" style="display: none;">About Bluemasters</div>
<div class="desc" style="display: none;">Our Portfolio</div>
<div class="desc" style="display: none;">Creation of Beaches</div>
</div>
</div>

<div class="paging">
<a rel="1" href="#">1</a>
<a rel="2" href="#">2</a>
<a rel="3" href="#">3</a>
</div>
</div>
</div><!--EOF:banner-->

to page.tpl.php bellow div header (exactly bellow </div><!--EOF:header-->)

2. As you already said, you should remove the if scenario from template.php
From

if (drupal_is_front_page()) {
drupal_add_js(drupal_get_path('theme', 'bluemasters') . '/js/bluemasters.js');
}

To

drupal_add_js(drupal_get_path('theme', 'bluemasters') . '/js/bluemasters.js');
At this time, you have the same slideshow with full functionality to all pages. In order to achieve a different slideshow per page, you should move the Slideshow code from page templates to Drupal system blocks.

3. Cut the following code both from page.tpl.php and page--front.tpl.php

<div class="main_view">
<div class="window">
<div class="image_reel">
<a href="<?php print url('node/3'); ?>"><img src="<?php print base_path() . drupal_get_path('theme', 'bluemasters') . '/images/slide-image-3.jpg'; ?>"></a>
<a href="<?php print url('node/2'); ?>"><img src="<?php print base_path() . drupal_get_path('theme', 'bluemasters') . '/images/slide-image-2.jpg'; ?>"></a>
<a href="<?php print url('node/1'); ?>"><img src="<?php print base_path() . drupal_get_path('theme', 'bluemasters') . '/images/slide-image-1.jpg'; ?>"></a>
</div>
<div class="descriptions">
<div class="desc" style="display: none;">About Bluemasters</div>
<div class="desc" style="display: none;">Our Portfolio</div>
<div class="desc" style="display: none;">Creation of Beaches</div>
</div>
</div>

<div class="paging">
<a rel="1" href="#">1</a>
<a rel="2" href="#">2</a>
<a rel="3" href="#">3</a>
</div>
</div>

and paste this code to a new Drupal system block which you should create through Drupal user interface admin/structure/block
YOU SHOULD GIVE TO YOUR BLOCK PHP INPUT FORMAT (or configure the code from PHP to HTML)
SEE ATTACHED bluemasters-slideshow-1.jpg
SEE ATTACHED bluemasters-slideshow-2.jpg

At this time, both page.tpl.php and page--front.tpl.php have the following code inside div banner

4. Now you should create as many blocks as different slideshows you want. After this creation you should configure each block visibility through Drupal block's user interface (Visibility settings at the bottom of block configuration: Only the listed pages).

5. Finally, you should place all your Slideshow blocks inside banner region.
SEE ATTACHED bluemasters-slideshow-3.jpg

Thanks
/George

Gabo11’s picture

Thank you!!!

You gave me a great help! With really good information and step by step description that made my problem look like was so easy to solve!
Now i like even more this great theme!

Thanks again for the perfect support!

Gabo11

Gabo11’s picture

Status: Active » Closed (fixed)
Gabo11’s picture

Issue summary: View changes

wrong php file name.