Rotating images Bug ( Suffusion – 4.1.5.b4 )

Reports about issues that you encounter in Suffusion
Forum rules
1. No offensive language and no mocking
2. Please do a thorough search before you post something. Trust us, there is a high probability that the question you are asking has been asked previously.
3. No soliciting. You cannot post here soliciting bids for people offer you quotes, or even offer money to people for some work. You will be moderated if you do so. If you are looking for help, please post your request on http://jobs.wordpress.net or http://codepoet.com
4. Please be reasonable. You are getting software and support. For free. Complicated requests from a general purpose theme are not welcome and some volunteers might lose patience with you.
5. Please do your due diligence. If you posted a query and we answered with a link, take the trouble to go through the link contents.
6. Please post with complete information. Requests for help MUST be accompanied with your URL, particularly if you are asking something like "Why am I seeing a blank space?"

Rotating images Bug ( Suffusion – 4.1.5.b4 )

Postby ken-ichi makino » 29 May 2012, 22:24

I am sorry , my English is crazy.

I chose
Header Background Image Type ---> Use a rotating set of images from a folder.
Next, I mistake by [ Folder for Rotating Header background ] setting.
I wrote a nowhere folder name, name is ./pix

Results
1. Many error log occurred.
In file of /var/log/httpd/error_log , this message has continued.
[Wed May 30 13:08:22 2012] [error] [client XXX.XXX.XXX.XXX] PHP Warning: readdir() expects parameter 1 to be resource, boolean given in /XXX/XXX/XXX/XXX/wp-content/themes/suffusion/functions.php on line 1050, referer: http://XXX.XXX.XXX.XXX/

2. Apache used CPU occupancy 99%.
---------------
I can not understand php. So I did below.

1. httpd stop
2. I commented out while loop at around line 1050 in functions.php .
3. httpd start
4. I changed wrong name ./pix into a exist folder name.
5. httpd stop
6. grep -v "expects parameter 1 to be resource, boolean given in /XXX/XXX/XXX/XXX/wp-content/themes/suffusion/functions.php on line 1050" /var/log/httpd/error_log > err
7. mv err /var/log/httpd/error_log
8. httpd start

I pray for your prosperity.
Thank you for suffusion.
ken-ichi makino
 
Posts: 2
Joined: 29 May 2012, 21:24

Re: Rotating images Bug ( Suffusion – 4.1.5.b4 )

Postby Colin » 29 May 2012, 23:18

The image rotate works fine and so you should not comment out anything.

Reload the theme to correct your edits, it won't lose any of your configuration through Suffusion Options or Custom Includes.

Then for your rotating images give the full path like http://mydomain.com/pix/rotate to the Suffusion option NOT a relative path.
Colin
 
Posts: 2856
Joined: 27 Oct 2009, 10:46

Re: Rotating images Bug ( Suffusion – 4.1.5.b4 )

Postby ken-ichi makino » 30 May 2012, 03:46

Thank you for advice.

The function file undo the original code.

If I knew php, I will add the code which avoided an infinite loop.
But I do not know yet, therefore only report to Suffution community.
ken-ichi makino
 
Posts: 2
Joined: 29 May 2012, 21:24

Re: Rotating images Bug ( Suffusion – 4.1.5.b4 )

Postby drake » 30 May 2012, 03:50

It is probably the only place in Suffusion where is strictly prohibited to add the absolute path. If you do that you will break again all things.

See this post of Sayontan for a short how-to: viewtopic.php?f=4&t=10282&p=39289&hilit=rotating+images+folder#p39289

Also, this is wrong reported as a bug meantime at Skinning -> Header -> Folder for rotating images is stated clearly: "Enter the path to a folder under /home/.../your-domain/public_html/wp-content"... If you enter a wrong path is not the fault of theme........
drake
 
Posts: 3859
Joined: 26 Jul 2011, 07:56
Location: Constanta, Romania

Re: Rotating images Bug ( Suffusion – 4.1.5.b4 )

Postby xoxixox » 08 Jun 2012, 04:03

Hello all,
I just begin with Suffusion for my Photographer site : http://www.nocto.fr

I have the same problem : images are not rotating in the header ?

I have of course a folder : wp-content/header-images
I have checked in the Header section :
Default styles or custom styles for header? : Custom styles
Header Background Image Type : Use a rotating set of images from a folder
Header Background Image Tiling : Do not repeat - show background once only
Folder for Rotating Header background : header-images

I try also : /header-images
or : /header-images/

results are the same, one image is showing but no rotation ??

I try on Safari, Chrome, Camino

If someone can help me, I surely did something wrong but what ?? :oops:
xoxixox
 
Posts: 5
Joined: 06 Jun 2012, 15:05

Re: Rotating images Bug ( Suffusion – 4.1.5.b4 )

Postby drake » 08 Jun 2012, 04:43

You have currently settled the folder http://www.nocto.fr/wp-content//header-images/h4.jpg. This isn't correct on any operating system...
Simply use "header-images" (without quotes or slashes). Also, make sure that all your images from this folder have names formed only by western characters, with no spaces or other chars in them.
drake
 
Posts: 3859
Joined: 26 Jul 2011, 07:56
Location: Constanta, Romania

Re: Rotating images Bug ( Suffusion – 4.1.5.b4 )

Postby xoxixox » 08 Jun 2012, 04:50

You right ;) BUT
I wrote I have try :
Folder for Rotating Header background : header-images
without any quotes or slashes

and the images names are :

h1.jpg
h2.jpg
h3.jpg
h4.jpg
h5.jpg

I also try different naming system with no effects !

BTW
permissions of the folder header-images and all images included is : 644
xoxixox
 
Posts: 5
Joined: 06 Jun 2012, 15:05

Re: Rotating images Bug ( Suffusion – 4.1.5.b4 )

Postby drake » 08 Jun 2012, 05:19

After you changing the folder it works, even if the images are changed very slowly. While I staying and testing your site I can see the images 1,5 and 3. Also, I made another test - I copied 3 images from your server, I made the folder "header-images" on my server and I upload those images. Then I settled http://lustre-lustre.com to rotating header background. You can see the result... on my server the images are rotating without any issue...

So, my thought is that your host use some caching technique on your server which keep to show the image which is loaded first in caching interval.
drake
 
Posts: 3859
Joined: 26 Jul 2011, 07:56
Location: Constanta, Romania

Re: Rotating images Bug ( Suffusion – 4.1.5.b4 )

Postby xoxixox » 08 Jun 2012, 05:26

drake wrote:So, my thought is that your host use some caching technique on your server which keep to show the image which is loaded first in caching interval.


Hummmm !! It could be, and I think this is the problem !

is there a way to force the "rotating script" to load images more in adequation with this kind of server ?
xoxixox
 
Posts: 5
Joined: 06 Jun 2012, 15:05

Re: Rotating images Bug ( Suffusion – 4.1.5.b4 )

Postby drake » 08 Jun 2012, 11:48

If you aren't afraid to make changes in files you can try this: edit functions.php by ftp in a text editor like notepad. (not in the Edit Themes from Dashboard).
Use the search function of editor and look for string "1000000". It is only one time in the file in this context:
Code: Select all
mt_srand((double)microtime()*1000000); // seed for PHP < 4.2.


Change that value to 100000. Even if this function seems to be used just for backward compatibility with php<4.2. and the function which generate the random index of images don't use it, on the site where I test your images seems to be a little improvement when I decreased that value.

If it help make a note about this change because on the next upgrade you will loose it.

I can't see another solution beside of asking your host to change the caching parameters... or better, to make a slideshow in header with your images and avoid to use the rotating images option.
drake
 
Posts: 3859
Joined: 26 Jul 2011, 07:56
Location: Constanta, Romania

Next

Return to Bug Reports

Who is online

Users browsing this forum: No registered users and 1 guest