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
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
Mobile Dev World
Return width of string

mb_strwidth

(PHP 4 >= 4.0.6, PHP 5)

mb_strwidthReturn width of string

Description

int mb_strwidth ( string $str [, string $encoding ] )

Returns the width of string str .

Multi-byte characters are usually twice the width of single byte characters.

Characters width
Chars Width
U+0000 - U+0019 0
U+0020 - U+1FFF 1
U+2000 - U+FF60 2
U+FF61 - U+FF9F 1
U+FFA0 - 2

Parameters

str

The string being decoded.

encoding

The encoding parameter is the character encoding. If it is omitted, the internal character encoding value will be used.

Return Values

The width of string str .

See Also


Variable number of function args.
Categories : Variables, PHP
Prime Spiral is a image plotted with all the primes in a number spiral.
Categories : Algorithms, Graphics, GD image library, Math.
Returns the last row from a select where multiple rows have been selected. In this case it is used to determine the last number in an AUTO_INCREMENT column. I use it to create "ticket numbers" or anything that needs a unique ID in sequence.
Categories : mSQL, MySQL, Databases, PHP



How to get the 10 biggest numbers out of an INT column.
Categories : General SQL, Databases
Reverse a given number
Categories : PHP, Beginner Guides, Algorithms, Math.
PHP Thumbnail script - Generate thumbnails on the fly.
Categories : PHP, Graphics, GD image library
Reduce the number of processors on a system for testing.
Categories : WinNT
A list of known port numbers
Categories : Network
Full membership authentication system.
Categories : Authentication, MySQL, PHP, Databases
Random Number generation using PHP's GD technique (captcha).
Categories : PHP, GD image library, Graphics, Security
How to validate an Israeli ID number.
Categories : Ecommerce, PHP, Algorithms
This is an admin utility to let you manage mysql users from a web page. It works for me.. I've fixed a number of bugs since 1.0, but it's still not very efficient code, and probably still has bugs.
Categories : Databases, MySQL, Complete Programs, PHP, Databases
color codes for positive and negative numbers
Categories : PHP, MySQL, Databases, HTML
How to count the number of lines in a file
Categories : PHP, Filesystem