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
Gets cURL version information

curl_version

(PHP 4 >= 4.0.2, PHP 5)

curl_versionGets cURL version information

Description

array curl_version ([ int $age= CURLVERSION_NOW ] )

Returns information about the cURL version.

Parameters

age

Return Values

Returns an associative array with the following elements:

Indice Value description
version_number cURL 24 bit version number
version cURL version number, as a string
ssl_version_number OpenSSL 24 bit version number
ssl_version OpenSSL version number, as a string
libz_version zlib version number, as a string
host Information about the host where cURL was built
age  
features A bitmask of the CURL_VERSION_XXX constants
protocols An array of protocols names supported by cURL

Examples

Example #1 curl_version() example

This example will check which features that's available in cURL build by using the 'features' bitmask returned by curl_version().

<?php
// Get curl version array
$version curl_version();

// These are the bitfields that can be used 
// to check for features in the curl build
$bitfields = Array(
            
'CURL_VERSION_IPV6'
            
'CURL_VERSION_KERBEROS4'
            
'CURL_VERSION_SSL'
            
'CURL_VERSION_LIBZ'
            
);


foreach(
$bitfields as $feature)
{
    echo 
$feature . ($version['features'] & constant($feature) ? ' matches' ' does not match');
    echo 
PHP_EOL;
}
?>


Time Format Conversion
Categories : PHP, Date Time
Library of math functions to expand the functionality of PHP3. Version 1.2.1 fixes a major problem with the gcd function.
Categories : Algorithms, PHP, Math.
Conversion of US Date into German Date - Konvertierung des US-Datums in das deutsche
Categories : Date Time, PHP



This is a simple PHP3 script to send an instant msg to the webmaster (only for Windows NT). Updated version 1.01!
Categories : PHP, Java Script
Designed to help those implementing a MySQL search engine. Generates select query strings, given logical querys.I made a search engine class that extends this one mail me if intrested.Needs a few changes ( well its only version 1.0 ;)
Categories : PHP Classes, MySQL, Search, Regexps
JavaScript Version Selector - RedirectOnVersion
Categories : Java Script
Initialize global variables for every field in a table. This is the generic version. It does not require phplib.
Categories : Global Variables, MySQL, PHP, Variables
A captcha image allows you to prevent spam posting when users reload the page and stop bots from submitting forms automatically. This version allows you to use your own fonts (.ttf) to show the text.
Categories : PHP, Security, Graphics, GD image library
menu.php3 is a simple to use 2D menu system. Homepage: http://cow.active.ch/~mustun/phpfi/menu/ (with an example.) Tested with: Apache/1.3.2 (Unix) PHP/3.0.4 but should work on other versions also
Categories : HTML, PHP
MyGuestbook Version 0.6.1 - A simple Guestbook using PHP3 and MySQL
Categories :
validateEmail 2.0 - upgraded version of the old validateEmail function used to validate email addresses via SMTP and regex.
Categories : Email, Regexps, PHP
DirtSearch Version 3.5 full function robust PHP and MySQL (and other databases) Site or Web Wide Search Engine
Categories : PHP, MySQL, Complete Programs, Search, Databases
This functions makes it easy to use session-variables known from ASP. With one Cookie the array "session" will save and restore from a db-record. In this version MySQL is used but it's should very easy to change
Categories : PHP, Arrays, Cookies, MySQL, Databases
Using cURL to download a file programmatically.
Categories : PHP, PHP Extensions, CURL