Check out THEMEFRAME Beta
Wordpress Themes - WP Forum at BFA
Click Here To DONATE! Support the theme development, get support from the author &
additional benefits (soon), based on your donation level. Your forum name will be highlighted.
Not a member yet? You can still donate. And once you become a forum member, send a Private Message ("PM") to Flynn mentioning your Paypal email address so your donation can be added to your user name.

Wordpress Themes - WP Forum at BFA » WordPress Themes » Atahualpa 3 Wordpress theme » Header configuration & styling »

How to get a header image to rotate every 'N' seconds


  #1  
Old Jul 10, 2009, 09:36 PM
Flynn's Avatar
Flynn
 
3,383 posts · Oct 2008
Munich, Germany
It's also missing in 3.4.1 which fixed many other bugs. On Sunday 7-12-2009 I'll release 3.4.2, or you can edit js.php of 3.4.1 and add this:


PHP Code:
<?php if (strpos($bfa_ata['configure_header'],'%image')!==FALSE AND 
$bfa_ata['header_image_javascript'] != "0" ) { ?>

var HeaderImages = new Array(<?php echo implode(","bfa_rotating_header_images()); ?>);
var t; var j = 0
var p = HeaderImages.length
<?php if ($bfa_ata['header_image_javascript_preload'] == "Yes") { ?>
var PreLoadImages = new Array()
for (i = 0; i < p; i++){
    PreLoadImages[i] = new Image()
    PreLoadImages[i].src = HeaderImages[i]
}
<?php ?>
function RotateHeaderImages(){
    if (document.body){
        HeaderImageContainer = document.getElementById('imagecontainer');
        HeaderImageContainer.style.background = 'url(' + HeaderImages[j] + ') <?php echo $bfa_ata['headerimage_alignment']; ?> no-repeat';
        j = j + 1
        if (j > (p-1)) j=0
        t = setTimeout('RotateHeaderImages()', <?php echo $bfa_ata['header_image_javascript']; ?>000)
    }
}
window.onload = RotateHeaderImages;

<?php ?>
after this

PHP Code:
# if (function_exists('sociable_html')) {
# include (WP_PLUGIN_DIR.'/sociable/wists.js');
# }

?> 
__________________
Please donate to support us
  #2  
Old Jul 25, 2009, 03:19 AM
ankita
 
2 posts · Jul 2009
URGENT!!!!!!!
dear i have by mistake i have upload the above stated code in theme editor/header.php/rotating image.php
my site got currupted.. i cannot access my site . dat is narinderafurnitures.com
please suggest me the solution to come out of the problem,its damn urgent...
  #3  
Old Aug 23, 2009, 12:11 PM
arenecute
 
2 posts · Aug 2009
Greenback Member 
i've just tried this and it WORKS like a charm! thanks you ))))

Last edited by juggledad; Mar 19, 2010 at 06:45 AM.
  #4  
Old Mar 31, 2010, 05:04 AM
Ber|Art's Avatar
Ber|Art
 
109 posts · Oct 2009
Europe (NL) ber-art.nl Windows Vista (SP2) x64 WP 3.x Atahualpa 3.5.x FireFox 3.x IE 8.x
Diamond Member 
Send a message via Skype™ to Ber|Art
Will this still work for the newest version you think?
  #5  
Old Mar 31, 2010, 05:28 AM
juggledad's Avatar
juggledad
 
8,023 posts · Mar 2009
OSX 10.5.8/10.6.2 WP 2.8.x/2.9.x/3.0 Atahualpa 3.2/3.3.x/3.4.x/3.5.x Safari 4.0.3 Firefox 3.5.3 XP/I
Gold Member 
The rotating header image code has been added into the theme. There is an option at ATO->Header Image called 'Rotate header images with Javascript?' that you can change from 0 to rotate the images.
__________________
Please donate if my support has been of value. Choose the PayPal button JUGGLEDAD.
  #6  
Old Apr 6, 2010, 07:04 AM
Ber|Art's Avatar
Ber|Art
 
109 posts · Oct 2009
Europe (NL) ber-art.nl Windows Vista (SP2) x64 WP 3.x Atahualpa 3.5.x FireFox 3.x IE 8.x
Diamond Member 
Send a message via Skype™ to Ber|Art
Ach, yes offcause, Thx!
  #7  
Old Apr 15, 2010, 01:19 AM
Ber|Art's Avatar
Ber|Art
 
109 posts · Oct 2009
Europe (NL) ber-art.nl Windows Vista (SP2) x64 WP 3.x Atahualpa 3.5.x FireFox 3.x IE 8.x
Diamond Member 
Send a message via Skype™ to Ber|Art
Works fine! thx again! I hope to finish soon so I can show off

Bookmarks

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Can Rotate Header and Resize Header work together? thetravelchronicle Forum How-To 10 Jun 24, 2009 07:24 PM
site auto-reloads every 3 seconds mrshannigan Atahualpa 3 Wordpress theme 7 Jun 17, 2009 05:56 PM
Header Images Fail to Rotate Yarrokon Header configuration & styling 10 Jun 8, 2009 10:17 AM
Pls help with - How to get a header image to rotate every 'N' seconds (sticky) HavaLyon Header configuration & styling 9 Apr 27, 2009 08:30 AM
nextGen gallery with image rotator as header image shatchp Header configuration & styling 1 Feb 13, 2009 07:40 PM


All times are GMT -6. The time now is 03:00 PM.


Powered by vBulletin® Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.