Register
FAQ
Calendar
Search
Today's Posts
Rules
Guidelines
SMS enable your application
via Clickatell’s fast, simple and reliable API's, built to integrate with any system.
Click here
to learn more.
Flash Website Builder
- Trendy Site Builder is a Flash Site Building tool that helps users build stunning websites.
Check Out Custom
Custom Logo Design
by LogoBee. Website Design and Free Logo Templates available.
CodingForums.com
>
Search Forums
Search Results
User Name
Remember Me?
Password
Before you post, read our:
Rules
&
Posting Guidelines
Page 1 of 20
1
2
3
11
>
Last
»
Showing results 1 to 25 of 500
Search took
4.86
seconds.
Search:
Posts Made By:
kbluhm
Forum:
PHP
04-30-2013, 08:25 PM
Replies:
1
tool for page performence and page load
Views:
116
Posted By
kbluhm
http://xdebug.org
http://xdebug.org
Forum:
PHP
04-28-2013, 07:05 PM
Replies:
2
if( eval('$var >= 5') )
Views:
115
Posted By
kbluhm
$is_valid = eval( 'return $var >= 5;' ); if...
$is_valid = eval( 'return $var >= 5;' );
if ( $is_valid )
{
// true
}
Forum:
Post a PHP snippet
02-20-2013, 04:54 AM
Replies:
4
Basic PHP Functions
Views:
951
Posted By
kbluhm
And lot of these are a huge overkill. Case in...
And lot of these are a huge overkill. Case in point: array2Text():
function array2Text( $array, $name = 'array' )
{
return '$' . $name . ' = '. var_export( $array, TRUE ) . ';';
}
Forum:
PHP
02-01-2013, 07:50 PM
Replies:
2
A-Z links based on query
Views:
260
Posted By
kbluhm
You can do that with one query as opposed to a...
You can do that with one query as opposed to a query within the foreach loop:
public function getCarrierByAlphabet()
{
// only run once per request
static $chars;
if ( ! isset(...
Forum:
PHP
01-28-2013, 08:40 PM
Replies:
4
Add an hour to date
Views:
236
Posted By
kbluhm
(time()+60*60) == strtotime( '+ 1 hour' ) ...
(time()+60*60) == strtotime( '+ 1 hour' )
$new_time = date( "m/d/y h:i a", strtotime( "+ 1 hour" ) );
Forum:
PHP
01-25-2013, 02:40 PM
Replies:
3
Similar string not matched?
Views:
169
Posted By
kbluhm
Haha, sorry... I had a simple answer, then got...
Haha, sorry... I had a simple answer, then got curious and did a bit more testing.
Forum:
PHP
01-25-2013, 02:28 PM
Replies:
3
Similar string not matched?
Views:
169
Posted By
kbluhm
There are special characters at the beginning of...
There are special characters at the beginning of the first EMAIL string. When I copied/pasted the code above, I get 2. When I type everything out manually from scratch, I get 1. If I paste the code...
Forum:
PHP
01-23-2013, 04:43 PM
Replies:
3
Echo grand total of cart array items
Views:
236
Posted By
kbluhm
$cart_total = 0.0; foreach (...
$cart_total = 0.0;
foreach ( $_SESSION["cart_array"] as $item )
{
$cart_total += ( float ) $item["total_cost"];
}
var_dump( $cart_total ):
Forum:
PHP
01-18-2013, 06:33 PM
Replies:
10
my css file not picking up php variables??
Views:
362
Posted By
kbluhm
It is a totally separate file that is loaded...
It is a totally separate file that is loaded independently and has no way of grabbing variables that are defined in another file. You'll need to move the variables to a file that is included in both.
Forum:
PHP
01-15-2013, 08:46 PM
Replies:
3
Parse out word only if it doesn't follow a specific word
Views:
323
Posted By
kbluhm
Quick and dirty... this will work, but there...
Quick and dirty... this will work, but there mayyy be a better way:
// highlight ALL instances of `pass`
$dot_afd = preg_replace( '/(pass)/i', '<b><i>$1</i></b>', $dot_afd );
// now remove...
Forum:
PHP
01-12-2013, 06:13 PM
Replies:
6
Removing HTML Comments
Views:
404
Posted By
kbluhm
The OP specifically emphasized wanting a PHP...
The OP specifically emphasized wanting a PHP solution.
This will strip all comments, but exclude thise that begin with <!--[
$html = preg_replace( '/\<\!\-\-[^\[].*\-\-\>/Us', '', $html );
Forum:
PHP
01-03-2013, 07:44 PM
Replies:
10
Link to file in local pc
Views:
388
Posted By
kbluhm
Ah, well alright then: echo "<a...
Ah, well alright then:
echo "<a href=\"file:///C:/filePath/$file\">$file</a>";
Note the triple slash after file: and single slash after C:
Forum:
PHP
01-03-2013, 03:30 PM
Replies:
10
Link to file in local pc
Views:
388
Posted By
kbluhm
It's certainly possible, but the only person that...
It's certainly possible, but the only person that will be able to view it is you and anyone else that happens to have a file with that path and name on their local PC... only they'll view their own...
Forum:
PHP
12-14-2012, 03:28 PM
Replies:
2
Help With Name Genorator
Views:
235
Posted By
kbluhm
No need to seed the random number generator since...
No need to seed the random number generator since about 10 years ago ;)
function random_string( $length = 32 )
{
$chars = array_merge( range( 'A', 'Z' ), range( 'a', 'z' ), range( 0, 9 ) );...
Forum:
PHP
12-14-2012, 03:12 PM
Replies:
3
Adding time to a date and time?
Views:
330
Posted By
kbluhm
http://www.php.net/date Lowercase m is the...
http://www.php.net/date
Lowercase m is the numeric month with leading zeros (12 == December)
Replace the lowercase m with a lowercase i... which is minutes with leading zeros.
strtotime()...
Forum:
PHP
12-13-2012, 09:57 PM
Replies:
1
PHP combine and count associative array
Views:
254
Posted By
kbluhm
What you'll want to do is loop through and use a...
What you'll want to do is loop through and use a key that is a hash of everything except for quantity. You'll use that hash to build a separate array of combined products. If the hash does not yet...
Forum:
PHP
12-11-2012, 09:07 PM
Replies:
4
Wrong parameter count for mysql_query() in...
Views:
279
Posted By
kbluhm
It's unrelated to the issue at hand, but you're...
It's unrelated to the issue at hand, but you're attempting to utilize parameter sanitizing, which mysql_query does not natively support.
http://www.php.net/mysql_query
Here's a quick and dirty...
Forum:
PHP
11-12-2012, 03:45 PM
Replies:
1
How to call a class function from another class using the parameters given
Views:
329
Posted By
kbluhm
Like this? class general_form { ...
Like this?
class general_form
{
public function call_custom_func( $class, $func )
{
$class = new $class;
return $class->$func();
}
Forum:
PHP
11-03-2012, 10:22 PM
Replies:
1
YouTube API error retrieving subscription videos (all of a sudden)
Views:
466
Posted By
kbluhm
YouTube has been experiencing some connectivity...
YouTube has been experiencing some connectivity issues. The 503 error text tells you exactly what's going on. Nothing you can do about it.
You could catch the error and on your site say something...
Forum:
PHP
10-24-2012, 02:47 PM
Replies:
7
Reading PHP Syntax
Views:
361
Posted By
kbluhm
It appears you're handling it pretty well. Are...
It appears you're handling it pretty well. Are you sure you need a book?
Forum:
PHP
10-06-2012, 03:27 PM
Replies:
14
please help me to count the number of folders with in directories
Views:
543
Posted By
kbluhm
Yet another alternative for your files vs....
Yet another alternative for your files vs. folders inquiry:
$glob = glob( realpath( $directory ) . '/*' );
// grab all files
$files = array_filter( $glob, 'is_file' );
// grab all folders...
Forum:
PHP
10-05-2012, 05:37 PM
Replies:
14
please help me to count the number of folders with in directories
Views:
543
Posted By
kbluhm
No, they are excluded. :)
No, they are excluded. :)
Forum:
PHP
10-05-2012, 05:15 PM
Replies:
14
please help me to count the number of folders with in directories
Views:
543
Posted By
kbluhm
Another solution, once you have a folder path......
Another solution, once you have a folder path... this will count the number of folders immediately within that folder (non-recursive):
$sub_directories = glob( realpath( $directory ) . '/*',...
Forum:
PHP
10-05-2012, 07:09 AM
Replies:
7
Resolved
getting post and session in a file
Views:
611
Posted By
kbluhm
Yup, it'd add the current date/time with no...
Yup, it'd add the current date/time with no punctuation, such as print_r.20121005020936.txt, where 20121005020936 is October 5th, 2012, 2:09:36am, and place it in the same folder as the current file....
Forum:
PHP
10-05-2012, 06:30 AM
Replies:
7
Resolved
getting post and session in a file
Views:
611
Posted By
kbluhm
Use the second argument to return rather than...
Use the second argument to return rather than print:
file_put_contents(
'./print_r.' . date( 'YmdHis' ) . '.txt',
print_r( $var, TRUE )
);
Showing results 1 to 25 of 500
Page 1 of 20
1
2
3
11
>
Last
»
Forum Jump
User Control Panel
Private Messages
Subscriptions
Who's Online
Search Forums
Forums Home
:: Client side development
JavaScript programming
DOM and JSON scripting
Ajax and Design
JavaScript frameworks
Post a JavaScript
HTML & CSS
XML
Flash & ActionScript
Adobe Flex
Graphics and Multimedia discussions
General web building
Site reviews
Building for mobile devices
:: Server side development
Apache configuration
Perl/ CGI
PHP
Post a PHP snippet
MySQL
Other Databases
Ruby & Ruby On Rails
ASP
ASP.NET
Java and JSP
Other server side languages/ issues
ColdFusion
Python
:: Computing & Sciences
Computer Programming
Computer/PC discussions
Geek News and Humour
Web Projects and Services Marketplace
Web Projects
Small projects (quick fixes and changes)
Medium projects (new script, new features, etc)
Large Projects (new web application, complex features etc)
Unknown sized projects (request quote)
Vacant job positions
Looking for work/ for hire
Project collaboration/ partnership
Paid work offers and requests (Now CLOSED)
Career, job, and business ideas or advice
Domains, Sites, and Designs for sale
Domains for sale
Websites for sale
Design templates and graphics for sale
:: Other forums
Forum feedback and announcements
All times are GMT +1. The time now is
09:52 AM
.
Web Hosting UK
|
Dedicated Server Hosting
|
Shareware Junction
|
Software Geek
|
Flash file uploader
|
Cloud Server
|
Web Hosting Australia
Home
-
Contact Us
-
Archives
-
Link to CF
-
Resources
-
Top
Powered by vBulletin®
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.