Learning Curve- Perfect Tutorial for the beginers
Follow us on Twitter Follow us on Facebook Follow us on Google Plus Follow us on rss
Skip to content
  • Home
  • APS1.0
  • APS2.0
  • PHP
  • SQ L& MYsql
  • Linux Shell Scripting
  • Codeigniter
  • Technical questions
  • Laravel
  • Angularjs
  • Node js
  • English Corner

Validation of firstname using regex in php

By Admin | November 26, 2014
0 Comment

PHP
1
2
3
4
5
6
7
8
9
10
11
<?php
$name='vasanthan';
$regex_name = '/^[a-zA-Z ]*$/';
 
if ($name!='' and !preg_match($regex_name,$name))
{
echo "invalid";
}
 
?>

Category: PHP Tags: regex validation for contact namee, regex validation for firstname, regex validation in php
Post navigation
← Find out duplicate entry from a form fields-Validation of duplicate entry in a form IS NULL usage in mysql-php →

Recent Posts

  • How to change mysql engine from Myisam to Innodb
  • Error: MySQL shutdown unexpectedly in XAMPP
  • nodemon is not working in windows.nodemon -v is showing errors
  • Error [ERR_REQUIRE_ESM]: require() of ES Module E:\node-course\notes-app\node_modules\chalk\source\index.js from E:\node-course\app.js not supported. Instead change the require of index.js in E:\node-course\app.js to a dynamic import() which is available in all CommonJS modules. at Object. (E:\node-course\notes-app\app.js:8:15) { code: ‘ERR_REQUIRE_ESM’
  • Word Power

Recent Comments

  • Shrinivasa on Delete in Laravel with join condition
  • Vasanthan pv on Force Download in laravel-file download in laravel
  • Trey Mhundwa on Force Download in laravel-file download in laravel
  • Vasanthan pv on Link not working in codeigniter, base_url() displaying “”http://::1” why?
  • adil on Link not working in codeigniter, base_url() displaying “”http://::1” why?

Archives

Categories

Tweets about mydoubtsin
Follow @mydoubtsin
web
statistics
Copyright 2016
mydoubts.in
Iconic One Theme | Powered by Wordpress