Combining 2 constants in a namespace
Posted: Thu Dec 04, 2008 5:18 am
Hi
Using PHP 5.3 alpha2. How do I define the ALPHANUM constant ?
Thanks
Using PHP 5.3 alpha2. How do I define the ALPHANUM constant ?
Code: Select all
<?php
namespace z;
const NUMBERS = '0123456789';
const LETTERS = 'abcdefghijklmnopqrstuvwxyz';
const ALPHANUM = constant(__NAMESPACE__.'::NUMBERS').constant(__NAMESPACE__.'::LETTERS');
?>