Raised This Month: $ Target: $400
 0% 

[Q.?] random_num


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
fysiks
Veteran Member
Join Date: Sep 2007
Location: Flatland, USA
Old 05-12-2012 , 12:52   Re: [Q.?] random_num
Reply With Quote #6

Quote:
Originally Posted by kketan77 View Post
menu_handler(id, menu, random_num(1, 4)) is correct!
That is not correct.

You will have errors because you are destroy the same menu twice. You should do this:

PHP Code:
switch( key == random_num(1,4) : key )
{
    case 
1
    {
        
// abc
    
}
    case 
2
    {
        
// abc
    
}
    case 
3
    {
        
// abc
    
}
    case 
4
    {
        
// abc
    
}

__________________
fysiks is offline
 



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 00:29.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode