PHP Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsProgramming LanguagesPHP Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
Stop making mediocre tutorials.The best tutorials are video! Camtasia Studio makes it easy to create engaging, buzz-building screen videos at any size, in any popular format. Download the free trial!
  #1  
Old May 9th, 2008, 06:34 AM
Ricta's Avatar
Ricta Ricta is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jul 2003
Location: Melbourne Australia
Posts: 423 Ricta User rank is Sergeant (500 - 2000 Reputation Level)Ricta User rank is Sergeant (500 - 2000 Reputation Level)Ricta User rank is Sergeant (500 - 2000 Reputation Level)Ricta User rank is Sergeant (500 - 2000 Reputation Level)Ricta User rank is Sergeant (500 - 2000 Reputation Level) 
Time spent in forums: 1 Day 9 h 40 m
Reputation Power: 12
Rand(1-9); not showing on page

Any tips on why
PHP Code:
if ( isset($_POST["submit"]) )
                                            {
                                                if (
$_POST["submit"] == "Roll")
                                                {
                                                    
$balance=rand(2-9);
                                                    
$streng=rand(1-9);
                                                    
$fear=rand(900-1000);
                                                    
$skill=rand(10-19);
                                                    print 

                                                        Balance $balance<br>
                                                        Strength $strength<br>
                                                        Fear Level $fear<br>
                                                        Overall SKill $skill
                                                     "
;
                                                }
                                            } 


is not showing on my page?
I get the Balance etc, but not the rand values
__________________
-= Ricta =-

Reply With Quote
  #2  
Old May 9th, 2008, 06:50 AM
kicken's Avatar
kicken kicken is offline
Wiser? Not exactly.
Dev Shed Specialist (4000 - 4499 posts)
 
Join Date: May 2001
Location: Ft Myers, FL
Posts: 4,003 kicken User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)kicken User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)kicken User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)kicken User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)kicken User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)kicken User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)kicken User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)kicken User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)kicken User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)kicken User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)kicken User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)  Folding Points: 115230 Folding Title: Super Ultimate Folder - Level 1Folding Points: 115230 Folding Title: Super Ultimate Folder - Level 1Folding Points: 115230 Folding Title: Super Ultimate Folder - Level 1Folding Points: 115230 Folding Title: Super Ultimate Folder - Level 1Folding Points: 115230 Folding Title: Super Ultimate Folder - Level 1Folding Points: 115230 Folding Title: Super Ultimate Folder - Level 1
Time spent in forums: 1 Month 2 Weeks 4 Days 16 h 44 m 28 sec
Reputation Power: 414
Send a message via ICQ to kicken Send a message via AIM to kicken Send a message via MSN to kicken
Look up rand() in the manual. Your using it incorrectly.
__________________
Spidermonkey Tutorial

http://wiser.aoeex.com/ - Long term project (offline due to evil crawlers and lack of content)
http://www.aoeex.com/gmap.php - Put yourself on the map

Reply With Quote
  #3  
Old May 9th, 2008, 07:10 AM
Ricta's Avatar
Ricta Ricta is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jul 2003
Location: Melbourne Australia
Posts: 423 Ricta User rank is Sergeant (500 - 2000 Reputation Level)Ricta User rank is Sergeant (500 - 2000 Reputation Level)Ricta User rank is Sergeant (500 - 2000 Reputation Level)Ricta User rank is Sergeant (500 - 2000 Reputation Level)Ricta User rank is Sergeant (500 - 2000 Reputation Level) 
Time spent in forums: 1 Day 9 h 40 m
Reputation Power: 12
baaaalllllllll (sticking tongue in front of my lower teeth)

WHAT A RETARD.

Thank you. It was doing my head in.
Even after you told me, It still took me 5 minutes to see what was wrong.

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming LanguagesPHP Development > Rand(1-9); not showing on page


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump

 Free IT White Papers!
 
Accelerating Trading Partner Performance
One in five. That's how many partner transactions have at least one error. That is an amazing statistic, particularly given the extraordinary leaps in innovation across the global supply chain during the past two decades. Download this white paper to learn more.

 
Competing on Analytics
This Tech Analysis is designed to help identify characteristics shared by analytics competitors, and includes information about 32 organizations that have made a commitment to quantitative, fact-based analysis.

 
Cost Effective Scaling with Virtualization and Coyote Point Systems
An overview of the industry trend toward virtualization, how server consolidation has increased the importance of application uptime and the steps being taken to integrate load balancing technology with virtualized servers.

 
Five Checkpoints to Implementing IP Telephony
Implementation planning for IP PBX software and IP telephony has become vital as businesses replace discontinued legacy PBX phone systems. This informative whitepaper outlines five "checkpoints" for any implementation plan that will help make IP communications a successful proposition.

 
Hosted Email Security: Staying Ahead of New Threats
In the last two years, email has become a fierce battleground between the nefarious forces of spam and malware, and the heroes of messaging protection. The spam volumes increased alarmingly every month, bringing clever new forms of phishing and virus propagation attacks.

 

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 5 hosted by Hostway