Database Configuration for MsSQL Server 2000 or higer in CakePHP 1.3.x or higher
March 11th, 2012 by dr.emi
I just found today, how to the best configuration for DBO Driver of MsSQL in CakePHP 1.3.7
First, I have try to make a connection to SQL Server 2000, 2005, and 2008. The result is always:
Warning (2): mssql_connect() [function.mssql-connect]: Unable to connect to server: 192.168.137.1\SQLEXPRESS,1433 [CORE\cake\libs\model\datasources\dbo\dbo_mssql.php, line 154] Warning (2): mssql_select_db() expects parameter 2 to be resource, boolean given [CORE\cake\libs\model\datasources\dbo\dbo_mssql.php, line 159]
After done for googling in few day(s), I just found a bug based on error above, in
CORE\cake\libs\model\datasources\dbo\dbo_mssql.php, line 154
It looks likely, configuration is always overwrite into this line. But after read an article about port problem for mssql driver in cakephp (forgoten about where is the article link), I try to change it to port => ”
And the result is still not connected, although I have try too in native php. And it’s works with simple line:
$myServer = "192.168.137.1\SQLEXPRESS"; //I used sql server 2008
$myUser = "sa";
$myPass = "xxx";
$myDB = "mesin_finger";
//connection to the database
$dbhandle = mssql_connect($myServer, $myUser, $myPass)
or die("Couldn't connect to SQL Server on $myServer");
//select a database to work with
$selected = mssql_select_db($myDB, $dbhandle)
or die("Couldn't open database $myDB");
Next, trouble shoot continue to line before 154 in dbo_mssql.php: CORE\cake\libs\model\datasources\dbo\dbo_mssql.php
And the magic has come, after change $config['host'] to direct string ’192.168.137.1\SQLEXPRESS’, it’s WORK!
So, I just found the bug:
If I use $port as complete string in mssql_connect or mssql_pconnect, connection will not success, since in line 147 of dbo_mssql.php, I found this line:
} elseif ($config['port'] === null) {
It’s mean, we must set port configuration in database.php to null, NOT IN STRING value. The option is only null and numeric value.
Here are my database.php configuration:
var $attDbMsSqlServer = array(
'driver' => 'mssql',
'persistent' => false,
'host' => '192.168.137.1\SQLEXPRESS',
'login' => 'sa',
'password' => 'xxx',
'database' => 'mesin_finger',
'prefix' => '',
'encoding' => 'utf-8',
'port' => null
);
GOOD LUCK!!
Popularity: 20% [?]
Interactive Ajax Data Management with Codeigniter
March 20th, 2011 by dr.emi
![]()
Hi there! this is super fast tutorial, when I was take a rest at the room. Oh god, where is my cofee and PUNK music. Aha!
This tutorial will show to you, how to create Interactive and very fast data management on one page together, without refreshing any page. One thing make this better “You are in codeigniter class of dr.emi” So, enjoy this tutorial.
Popularity: 69% [?]
Membuat Manajemen Hak Akses User dengan Codeigniter
November 6th, 2010 by dr.emi
read more
malem eni gw akhirnya bisa juga nyolong2 waktu bwat nulis lagi. setelah skian lama pakum. ada tersirat, panggilan jiwa bwat nulis dan sharing lagi. setelah sekian lama males dan sibuk mncari napkah biar dapur ngebul terus. tapi setidaknya gw masih punya keinginan bwat sharing. pgimanepun, gw terlahir dari kalangan berpendidikan, orang tua gw guru smue. gw masih merasa terpanggil bwat sharing dan berbagi ilmu. tanpa banyak bacot, dan masih dalam bahasa gw yang acakadut ini, kite mulai dah tutorial pertama di bulan nopember ini. haahah!! LEGEK PISAN!!
Popularity: 100% [?]
Web Base Controller System with NirCMD
February 28th, 2010 by dr.emi
Prikituw!!! gw awali selamat datang dr.emi wakakakakakaka .. slamat datang kok ama diri sndiri..
hehe, gw mang dah lama ga posting tutorial baru. berkutat ama urusan sendok ama piring di dapur. wkaakak..
tapi gw pernah janji kalo bakalan exist di blog legendaris ini. ya, dremi.INFO blog pertama gw mengudara sejak 2005, uset dah! emang radio apa… hahaaha
tapi sekalipun demikian, gw selalui ngikutin perkembangan pendidikan di tanah air. dan beberapa memang membuat gw geleng-geleng kepala. dari dulu ampe sekarang, tutorial yang gw jumpai, itu itu mulu. ayolah kawand, ciptakan sesuatu yang beda! biar popularitas kagak jadi tolak ukur sebuah blog. tapi kualitas nya juga donk!
Popularity: 50% [?]
dreLogin v.2.0 Has Release
November 12th, 2009 by dr.emi
How to Check Username Availability using jQuery + PHP
November 3rd, 2009 by dr.emi
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: 21% [?]
Building Administrator Manager for Table Relation Using PHP and jQuery
July 3rd, 2009 by dr.emi
Hello my friends, this tutorial will explain about how to building complete Administrator Manager, Using PHP and jQuery. At the begining of tutorial you will explained about designing interface for our Administrator Page, then will continue with steps about how to make it as ready application.
Well, actually I don’t know how to create good tutorial, but I feel, I must share this tutorial. Based on my recent project last month, this tutorial will guide you to be a webmaster. I am sure, you know about what is webmaster
Because in this tutorial you will see technic from first designing till hand code your application. Enjoy it friends !
Popularity: 15% [?]
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
- Web Base Controller System with NirCMD
- Simple Swing Login Form And getText()
- dreLogin v.2.0 Has Release
- Create a simple application to open an EXE file on the window with JAVA
- Sony Ericsson Logo
- The Chain Tutorial from FuelYourCreativity
- Advance Metalic Gloss Logo
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: @ita : sekarng harus hati hati kalo penelpon nya dari hp reg...
- ita: saya juga hampir saja kena tipu untung saya cancel pengir...
- dr.emi: @al-k CUHUMUND =))...
- Loka Dwiartara: biasa kang orang mah udah nge-judge duluan, itu karena orang...
- zir: weeeesss manteb....
- dr.emi: @Mollie Colgate Thank you! This is my private theme for my w...
- Mollie Colgate: I really love your blog.. Pleasant colors & theme. Did y...
Recent Posts
- JOKOWI: PEMIMPIN ADALAH KETEGASAN TANPA RAGU
- Muak dengan tingkah laku Ahmad Husein Alaydrus (DPRD dari Demokrat)
- BANDUNG: JALAN BERLOBANG, PARKIRAN DIMANA-MANA
- jokowi memimpin dengan logika, pemahan yang kuat perihal teknik pemerintahan, serta strategi nya yang selalu inovatif!
- DISKON HARGA LISENSI WEBSEN 25%, PROMO HARI JADI DR.EMI CREATIVE DESIGN
- BJ HABIBIE - FIGUR ILMUWAN YANG SAYA KAGUMI
- JOKOWI Bukan Mencari Sensasi, Tapi Solusi!
- Sebuah penyemangat untuk saya dan semua orang
- Selamat Jalan Martoyo Umb
- Dremi.INFO spirit coming from these sentences
Archives
Popular Tags
3D illustration abstract design adsense aero button animation banner clean navigation codeigniter colouring layer CSS tutorials effect finger print glassy effect google gradient style GUI photoshop design hacker handcoded HTML indonesian culture IT job jQuery layer mask logo lombok 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 web articles web design web development web header web layout web tips
I has release dreLogin V.2.0, it’s available to download and distributed under common license 3.0
Hi! dude! how are you today ? I hope all of you will fine
Hello my fox! glad to see you today. For more than one week, I got spam and bad posting (junk) on my forum . But today I hope no more again. I think this tutorial will help you, how to modifiying SMF User Register Page to protect from spammer or junker. As you know, SMF has Spam Protection like Captcha, called as Visual Verification. For a simple spam protection, I think captcha is enough for your forum register protection. But how if users do register and then make some posting on your forum ?















PSD Files
PHP Source Code






