Regular Expressions Examples
-
zendnwar
-
July 27, 2012
-
PHP Basic
-
0 Comments
Regular Expressions Examples Regular Expressions for Username Pattern : /^a-z0-9_-{3,16}$/ Description: The beginning of the string (^), followed by any lowercase letter (a-z), number (0-9), an underscore, or a hyphen. Next, {3,16} makes sure that are at least 3 of those characters, but no more than 16. And last, the end of the string ($). Matches: an-wa3r_t5h3 Doesn’t match: dgdgd1-www_78chfdhgvsfdsaas …
Continue Reading
How to connect php and oracle database?
-
zendnwar
-
July 26, 2012
-
PHP Basic
-
0 Comments
oci_connect : Connect to an Oracle database. oci_connect ( string $username , string $password , string $connection_string , string $character_set , int $session_mode ) To create a connection to Oracle that can be used for the lifetime of the PHP script, perform the following steps. <?php // Create connection to Oracle $conn = oci_connect(“phphol”, “welcome”, “//localhost/orcl”); if (!$conn) { …
Continue Reading
What is ucfirst, ucwords, lcfirst, strtolower, strtoupper function in php?
-
zendnwar
-
July 26, 2012
-
PHP Basic
-
0 Comments
What is ucfirst, ucwords, lcfirst, strtolower, strtoupper function in php? ucfirst : Make a string’s first character uppercase <?php $var = ‘anwar hossain!’; $var = ucfirst($var); // Anwar hossain! $bar = ‘HELLO WORLD!’; $bar = ucfirst($bar); // HELLO WORLD! $bar = ucfirst(strtolower($bar)); // Hello world! ?> ucwords : Uppercase the first character of each word in a string. <?php $var …
Continue Reading
How know google about your site?
-
zendnwar
-
July 26, 2012
-
SEO
-
0 Comments
How know google about your site? To see if Google already knows about your site, do a “site:” search, like this: site:example.com . If pages from your site show up, your site (or a part of it) is already in Google’s index. If it doesn’t show up, and it’s very new, it’s possible that Google hasn’t discovered it yet. …
Continue Reading
How google works?
-
zendnwar
-
July 26, 2012
-
SEO
-
0 Comments
How google works? Algorithmic search Search is about giving people the answer they’re looking for—whether it’s a news article, sports score, stock quote, a video or a map. Google’s search engineers design algorithms that analyze millions of pages and return timely, high-quality, relevant answers to people’s questions. More information about Google Web Search. What about ads? Search results (sometimes called …
Continue Reading
Which can Googlebot read better, static or dynamic URLs?
-
zendnwar
-
July 26, 2012
-
SEO
-
1 Comment
Which can Googlebot read better, static or dynamic URLs? Many webmasters who, believed that static or static-looking URLs were an advantage for indexing and ranking their sites. This is based on the presumption that search engines have issues with crawling and analyzing URLs that include session IDs or source trackers. However, as a matter of fact, we at Google have …
Continue Reading
What is zend engine in PHP?
-
zendnwar
-
July 25, 2012
-
PHP Basic
-
0 Comments
What is zend engine in PHP? Zend Engine is used internally by PHP as a complier and runtime engine. PHP Scripts are loaded into memory and compiled into Zend opcodes.
Continue Reading
What is the difference between echo and print statement in PHP?
-
zendnwar
-
July 25, 2012
-
PHP Basic
-
1 Comment
What is the difference between echo and print statement in PHP? Multiple expressions can be given in echo statement, where as print cannot take multiple expressions.Echo does not have a return value, where as print returns a value indicating successful execution.Echo is faster when compared with print.
Continue Reading
Explain the difference between $var and $$var?
-
zendnwar
-
July 25, 2012
-
PHP Basic
-
0 Comments
Explain the difference between $var and $$var? $var is a variable and $$var is a variable of another variable. For example $var = “Shafin”; $you= “Anwar”; echo $var //Output:- Shafin echo $$var //output :-Anwar $$var allows the developer to change the name of the variable dynamically.
Continue Reading
What is Constructors and Destructors?
-
zendnwar
-
July 25, 2012
-
PHP Basic
-
0 Comments
What is Constructors and Destructors? CONSTRUCTOR : PHP allows developers to declare constructor methods for classes. Classes which have a constructor method call this method on each newly-created object, so it is suitable for any initialization that the object may need before it is used. DESTRUCTORS : PHP 5 introduces a destructor concept similar to that of other object-oriented languages, …
Continue Reading