Support Forums | Demo Gallery [1.x] [2.x] | Downloads | News | Site Map ]
Nuked Gallery
  Create a FREE account or Login   As a guest, you don't have access to our FULL navigation system.
 Forum FAQForum FAQ   StatisticsStatistics   SearchSearch   UsergroupsUsergroups   FavoritesFavorites  

Block error: rand() & Call to a member function
Goto page Previous  1, 2
 
Post new topic   Reply to topic    NukedGallery.net Forum Index » PHP-Nuke Integration » Blocks View previous topicPrinter friendly versionView next topic
Author Message
wellie

Beginner
Beginner


Joined: Jul 30, 2003
Posts: 7

PostPosted: Fri Aug 01, 2003 3:21 am    Post subject: Re: Block error: rand() & Call to a member function Reply with quote

Yay! Fixed! Very Happy

Thanks to the Gallery Forums - found the fix in this thread [menalto.com]. Thanks to hawkin.

Undo the fix above if you made it and insert
Code: › $count = floatval($count);

in front of:
Code: › $choose = rand(1, $count);


Appears it is a conflict with some PHP versions. Now is working absolutely fine. Should this be incorporated into the release on the downloads page?
Back to top
Offline View user's profile Send private message
AdBot
   Post subject: Re: Block error: rand() & Call to a member function  

Back to top
wellie

Beginner
Beginner


Joined: Jul 30, 2003
Posts: 7

PostPosted: Fri Aug 01, 2003 4:33 am    Post subject: Reply with quote

Quote: ›
Yay! Fixed!

Argghh. Spoke to soon. Still getting the occasional out of bounds error. Anyone?
Back to top
Offline View user's profile Send private message
corduroy

Beginner
Beginner


Joined: Apr 17, 2003
Posts: 4

PostPosted: Fri Aug 01, 2003 3:18 pm    Post subject: Re: Block error: rand() & Call to a member function Reply with quote

well, i was going to work on this some more but unfortunately i went from 1.3.5b51 to b61 and now it doesn't work at all, i get the following error message.
Code: › Warning: Invalid argument supplied for foreach() in /home/httpd/vhosts/colexusclub.com/httpdocs/modules/gallery/session.php on line 63

Warning: main(errors/configure_instructions.php): failed to open stream: No such file or directory in /home/httpd/vhosts/colexusclub.com/httpdocs/modules/gallery/errors/reconfigure.php on line 13

Fatal error: main(): Failed opening required 'errors/configure_instructions.php' (include_path='.:/usr/share/pear') in /home/httpd/vhosts/colexusclub.com/httpdocs/modules/gallery/errors/reconfigure.php on line 13


i'll go back to what i had before and work on it tommorow or sunday...
also, i have nearly no php experience... some vb experience many years ago, a little c, that's it Wink
Back to top
Offline View user's profile Send private message
dari

Site Admin
Site Admin


Joined: Mar 03, 2003
Posts: 6287
Location: Washington Township, NJ, USA

PostPosted: Fri Aug 01, 2003 5:00 pm    Post subject: Re: Block error: rand() & Call to a member function Reply with quote

please search the forums, this has been answered before.
read this:
http://www.nukedgallery.net/modules.php ... =1&thold=0
Back to top
Offline View user's profile Send private message Visit poster's website
nukestud

Beginner
Beginner


Joined: Apr 13, 2003
Posts: 13

PostPosted: Sat Aug 02, 2003 1:08 am    Post subject: Reply with quote

I tried that fix dari, doesn't work!

If I delete the block-random.cache it works once then not again untill I delete the block-random.cache again.

I am running random photo, hourly photo, new albums horizontal and most viewed. I got the other ones to work until I added most viewed block now problems. Sad
Back to top
Hidden View user's profile Send private message
dari

Site Admin
Site Admin


Joined: Mar 03, 2003
Posts: 6287
Location: Washington Township, NJ, USA

PostPosted: Sat Aug 02, 2003 6:16 pm    Post subject: Reply with quote

actually, this looks to be more of a gallery error...try getting the newest CVS and see if it still occurs.
Back to top
Offline View user's profile Send private message Visit poster's website
nukestud

Beginner
Beginner


Joined: Apr 13, 2003
Posts: 13

PostPosted: Sat Aug 02, 2003 6:32 pm    Post subject: Re: Block error: rand() & Call to a member function Reply with quote

Yeah I got it all working after pulling my hair out for hours lol If I were asked to do it again I wouldn't know where to start Wink It seems after all the fixes etc the only way I could get all the blocks working together was in the right side!

Just one thing I can't seem to do is get a border around the image in the random block, or the most viewed! Funny thing is the hourly one which is really straight forward in the random_support.php doesn't seem to apply for the random option!

Cheers
Back to top
Hidden View user's profile Send private message
slackbladder

Moderator
Moderator


Joined: Mar 29, 2003
Posts: 1038
Location: Cambs,UK

PostPosted: Sun Aug 03, 2003 3:42 am    Post subject: Re: Block error: rand() & Call to a member function Reply with quote

nukestud wrote: › Just one thing I can't seem to do is get a border around the image in the random block, or the most viewed! Funny thing is the hourly one which is really straight forward in the random_support.php doesn't seem to apply for the random option!

Cheers


Try this:

http://www.nukedgallery.net/postt78.html [nukedgallery.net]
Back to top
Offline View user's profile Send private message Visit poster's website Yahoo Messenger MSN Messenger
switch

Novice
Novice


Joined: Jul 09, 2003
Posts: 23

PostPosted: Fri Aug 22, 2003 8:11 pm    Post subject: Re: Block error: rand() & Call to a member function Reply with quote

since the quick fix for this error is by deleting the block-random.cache file . How about using the crontab ? like make it delete the block-random.cache like every 30mins or something Idea . though i dont know how to use the crontab though Sad
Back to top
Offline View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    NukedGallery.net Forum Index » PHP-Nuke Integration » Blocks View previous topicPrinter friendly versionView next topic
Goto page Previous  1, 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
All times are GMT - 5 Hours

Powered by phpBB © phpBB Group



Sponsors: Dedicated ServersDomain NamesWeb HostingDomain Name RegistrationDedicated Web HostingWeb Design New YorkCompare VoIPseo packagesSEO CompanyNew York Yellow PagesFind LocationsVOIP Phone ServiceNeckermannOnline internetSEORestaurant Locator • Get great HP coupons from CouponSnapshot • Search for great dell coupons at CouponSnapshot.com.au • Graduation DressesAndroid TabletSEO IndiaBuy Phen375fuel filter

8th year online! 2003-2011
Legal • Use of this site consitutes agreement to the Acceptable Use Policy
Hosted by Implosion WorksSourceForge.net Logo • Theme by TonicMedia