How to Check Username Availability using jQuery + PHP
November 3rd, 2009 by dr.emi
White Space Problem with JavaScript
October 31st, 2009 by dr.emi
This tutorial will explain about how to solve white space problem with JavaScript. One time, I founded bug on my PHP script. White space was broke it! Shit!. However javascript doesn’t have trim function like PHP. For example, if you want to validate user form using jQuery and PHP, my advice is: you must check the white spaces before send string to PHP Action Script. Then you will fine to use PHP trim function or class defined.
It’s fuck’n crazy. My jQuery not respond If I don’t check white space before send string into PHP script. So I need to find the white space before send it!
Here are my simple javascript code to find and count the white spaces:
// Count the number of times a substring is in a string.
String.prototype.substrCount =
function(s) {
return this.length && s ? (this.split(s)).length - 1 : 0;
};
//some function to implementad
function loadContentResult(id) {
if(id.substrCount(' ') > 0)
{
window.alert('I found white spaces on field');
}
else
{
window.alert('White spaces cleared!! You may add the next PHP / jQuery here');
}
First: counting white space as problem caused
String.prototype.substrCount =
function(s) {
return this.length && s ? (this.split(s)).length - 1 : 0;
};
Next, we will try the scripts as user id validator on my jQuery tutorial. See you!
Popularity: 38% [?]
Download PHP Script: Backup and Restore Database
October 1st, 2009 by dr.emi
Hi guys!
This is PHP Script to backup or restore your SQL Database. It’s Free to download!
Just visit my PHPClasses Page:
http://www.phpclasses.org/browse/package/5720.html
Or let’s discuss about something bug or report on:
http://www.phpclasses.org/discuss/package/5720/
Popularity: 26% [?]
Web Design Layout Plus Implementasi jQuery Tab Content
November 26th, 2008 by dr.emi
Memperkenalkan dreDSync V.1.0 Produk Terbaru dr.emi
November 2nd, 2008 by dr.emi
Cara Nampilin Jam dan Tanggal Ala Javascript
February 6th, 2007 by dr.emi
Advertise
Sponsors
Most Popular Posts
- Membuat Manajemen Hak Akses User dengan Codeigniter
- Interactive Ajax Data Management with Codeigniter
- Web Design Layout Plus Implementasi jQuery Tab Content
- Simple Swing Login Form And getText()
- Web Base Controller System with NirCMD
- Create a simple application to open an EXE file on the window with JAVA
- How to Check Username Availability using jQuery + PHP
- dreLogin v.2.0 Has Release
- The Chain Tutorial from FuelYourCreativity
- Email untuk Pak ESBEYE di HUT RI ke 65
Category
Subcribe RSS Feed
Translate
Flick Group dr.emi
dr.emi creative design
SEO Articles & Newsletters
Forum dremi.info
Free Download
Recent Comments
- dr.emi: @ade itu make toggle nya jQuery: http://api.jquery.com/slid...
- dr.emi: ma sama..... mas berok...
- dr.emi: ada mas berok: http://www.dremi.info/tutorials/jquery/drelo...
- datih: apakah ada syntak Log-in php ???...
- Armin: ngakalin rounded corner biar compatible di semua browser kek...
- Armin: edan ini, tutorialnya langsung sehalaman...gkgkk.. sukses b...
- erny: kereeennn... makasiihhh... kapan2 balik lg! hehehe. :D...
Recent Posts
- MARJINAL DI TVONE "RADIO SHOW"
- Mail Yahoo make me frustrating
- Sharing Pengalaman menggunakan CI dan CakePHP
- Lowongan Kerja dr.emi creative design - Oktober 2011
- Happy Eid Mubarak - May God Bless You!
- Lowongan untuk PHP Programmer (PT Xsis Mitra Utama)
- Fenomena ustad/ustazah jadi2an di tipi sedang marak
- Sayang sekali tak dapat nonton Marky Ramones
- [FIX] Installing Ruby on Rails 3, MySQL and SOLVE few problem on UBUNTU 10.10 (Maverick)
- Small Tip, big solution in SVN Problem
Archives
Popular Tags
3D illustration abstract design adsense aero button animation banner clean navigation codeigniter colouring layer CSS tutorials effect form interface glassy effect google gradient style GUI photoshop design hacker handcoded HTML indonesian culture IT job jQuery layer mask logo lowongan kerja merancang web pen tool photo retouch photoshop design PHP PHP Advance PHP login php programmer product demo relationship search engine shapping spirit text effect transparent gradient web articles web design web development web header web layout web tips
Hi! dude! how are you today ? I hope all of you will fine
Welcome back friend ! tutorial ini menjelaskan bagaimana membuat sebuah layout yang interaktif. Penggabungan dari designing web layout menggunakan photoshop dan Editing dengan HTML+CSS. Kemudian mengimplementasikannya menggunakan jQuery Ajax saat meload PHP Content
dreDSync V.1.0 merupakan karya gw ke-sekian kalinya untuk dunia IT, berfungsi sebagai Data Syncronizer yang berbasis pada komunikasi Flat File TXT dan Socket Detection. Gw bikin menggunakan bahasa pemrograman PHP dan terinspirasi dari project terbaru gw CBT of TNI. 
















PSD Files
PHP Source Code






