Menu
Forums
All threads
Latest threads
New posts
Trending threads
New posts
Search forums
Trending
What's new
New posts
New profile posts
Latest activity
Members
Current visitors
New profile posts
Search profile posts
Upgrades
Log in
Register
What's new
Search
Search
Search titles only
By:
All threads
Latest threads
New posts
Trending threads
New posts
Search forums
Menu
Log in
Register
Navigation
Install the app
Install
More options
Contact us
Close Menu
Forums
Software Development
Programming
Programming Q&A
OOP MYSQLI
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Reply to thread
Message
<blockquote data-quote="Predict" data-source="post: 193243" data-attributes="member: 3953"><p>I ain't really sure what the problem here is, but if you want a mysqli class, you're free to use the one I'm using for POP CMS.</p><p> </p><p>[PHP]<?php</p><p>if(!defined('DH_PAGES'))</p><p>{</p><p> die('<h1>Access denied</h1><p>You do not have the privileges to access this webpage.</p>');</p><p>}</p><p> </p><p>class db_mysqli extends mysqli</p><p>{</p><p> public function __construct($host, $user, $pass, $db)</p><p> {</p><p> parent::__construct($host, $user, $pass, $db);</p><p> if (mysqli_connect_error())</p><p> {</p><p> die('<h1>Cannot connect to database</h1><p>There is a problem while connecting to the database, please check back to your database connection settings.</p>');</p><p> }</p><p> }</p><p>}</p><p>?>[/PHP]</p></blockquote><p></p>
[QUOTE="Predict, post: 193243, member: 3953"] I ain't really sure what the problem here is, but if you want a mysqli class, you're free to use the one I'm using for POP CMS. [PHP]<?php if(!defined('DH_PAGES')) { die('<h1>Access denied</h1><p>You do not have the privileges to access this webpage.</p>'); } class db_mysqli extends mysqli { public function __construct($host, $user, $pass, $db) { parent::__construct($host, $user, $pass, $db); if (mysqli_connect_error()) { die('<h1>Cannot connect to database</h1><p>There is a problem while connecting to the database, please check back to your database connection settings.</p>'); } } } ?>[/PHP] [/QUOTE]
Insert quotes…
Verification
Post reply
Forums
Software Development
Programming
Programming Q&A
OOP MYSQLI
Top