WeberDev.com PHP and MySQL Code

LOG IN
BEGINNER GUIDES  |  PHP CLASSES  |  CODE SEARCH  |  ARTICLES SEARCH  |  PHP FORUMS  |  PHP MANUAL  |  PHP FUNCTIONS LIST  |  WEB SITE TEMPLATES
Start typing to search for PHP and MySQL Code Snippets and Articles Search
Submit a code Example / Snippet Submit Your Code
Search Engine Optimization Monitor SEO Monitor
Web Site UpTime Monitor UpTime Monitor
WeberDev's Monthly code contest PHP Code Contest
Your Personal Examples List My Favorite Examples
Your Personal Articles List My Favorite Articles
Edit Account Info Update Your Profile
PHP Code Search
Web Development Forums
Learn MySQL Playing Trivia
PHPBB2 Templates
Web Development Index
PHP Web Logs (BLogs)
Web Development Resources
Web Development Content
PHPClasses
PHP Editor
PHP Jobs
Vision.To Design
Ajax Tutorials
PHP Programming Help
PHP/MySQL Programming
Webmaster Resources
Webmaster Forum
XML meta language
website builder
Submit Site
Forex Trading Online forex trading platform

Go Back Add a Comment Send this example to a friend Add this Article to your personal favoritest for easy future access to your favorite Code Examples and Articles. Submit a code example Print this code example.
BACK ADD A COMMENT SEND TO A FRIEND ADD TO MY FAVORITES ADD CODE EXAMPLES PRINT
Title : Using PHP to show text in random colors
Categories : PHP, Beginner Guides, Strings Click here to Update Your Picture
vadivel mukkandhan
Date : Dec 26th 2007
Grade : 3 of 5 (graded 2 times)
Viewed : 2414
File : No file for this code example.
Images : No Images for this code example.
Search : More code by vadivel mukkandhan
Action : Grade This Code Example
Tools : My Examples List

  Submit your own code examples 
 

<html><head><title>rancolor</title></head>
<body>
<?php
function randColor()
{
$letters = "1234567890ABCDEF";
for($i=0;$i<6;$i++)
{
$pos = rand(0,15);
$str .= $letters[$pos];
}
return "#".$str;
}
for($i=1;$i<6;$i++)
{
echo '<span style="color:'.randColor().'">Random Color Text</span><BR>';
}
?>
</body></html>



Find the day of the week for any given year/month/day.
Categories : PHP, Date Time, Data Validation, Algorithms, Beginner Guides
Customizable encoding and decoding strings with security.
Categories : PHP, Strings, HTML and PHP
Allows you to parse a deliniated string and put the individual fields in a SELECT option in a form
Categories : HTML, PHP, Strings
Upload Via FTP - an alternative to move_uploaded_file
Categories : PHP, FTP, Beginner Guides
PHP and javascript mouseover, mouseout, and mousedown events
Categories : PHP, Java Script, Form Processing, Beginner Guides
How to preset a text string in a textarea input field
Categories : HTML, HTML and PHP, PHP, Beginner Guides
Mimic ASP's GetString function with PHP
Categories : PHP, Databases, MySQL, Strings
Easy alert box pop-up function
Categories : PHP, Java Script, Beginner Guides
Newbie Notes #1 - Making a form return to itself
Categories : PHP, Beginner Guides, HTML and PHP
Specify your connection settings and create a link to a MySQL database.
Categories : PHP, PHP Classes, Databases, MySQL, Beginner Guides
mySQL/PHP/search with multientry form and table output with colored rows
Categories : PHP, Beginner Guides, MySQL, HTML and PHP, Databases
a PHP Function to Get only the filename (remove the extension) using regular expressions.
Categories : PHP, Regexps, Beginner Guides
how can I read the entire contents of a file into a string?
Categories : Filesystem, Strings, PHP
Find if a year is leap.
Categories : PHP, Date Time, Beginner Guides, Data Validation
Introduction to Language Files
Categories : PHP, Filesystem, Beginner Guides