|
|
 |
Author |
Message |
pixelzm

Joined: 01 Dec 2006
Posts: 3
|
Posted:
Fri Dec 01, 2006 6:17 pm |
  |
I install Apache2Triad v.1.5.4. with default settings.
When I work with MySQL with mysql functions everything is OK. But, mysqli functions doesn't work. I copy code from manuel and nothig (only white page in browser):
Code: |
<?php
$mysqli = new mysqli("localhost", "my_user", "my_password", "world");
/* check connection */
if (mysqli_connect_errno()) {
printf("Connect failed: %s\n", mysqli_connect_error());
exit();
}
printf("Host information: %s\n", $mysqli->host_info);
/* close connection */
$mysqli->close();
?>
|
OR
Code: |
<?php
$link = mysqli_connect("localhost", "my_user", "my_password", "world");
/* check connection */
if (!$link) {
printf("Connect failed: %s\n", mysqli_connect_error());
exit();
}
printf("Host information: %s\n", mysqli_get_host_info($link));
/* close connection */
mysqli_close($link);
?>
|
Where I am wrong?
I was download some classes from internet and they doesn't work.
And, when I writing classes with construct
public function __construct(....) { }
this doesn't work too.
I think that everything from php5 doesn't work.
P>S> Sory for bad english. |
|
|
  |
 |
Joshua Meadows (DemoRic)
support

Joined: 29 Dec 2004
Posts: 783
Location: S.E. Kansas
|
Posted:
Fri Dec 01, 2006 8:26 pm |
  |
Verify that you have the following lines in your c:\windows\php.ini
Quote: | extension=php_mysql.dll
extension=php_mysqli.dll |
After making those changes restart apache service. |
|
|
    |
 |
pixelzm

Joined: 01 Dec 2006
Posts: 3
|
Posted:
Fri Dec 01, 2006 10:42 pm |
  |
Thanx.
I don't have second extension and I put it in php.ini.
What about __construct and classes? |
|
|
  |
 |
Joshua Meadows (DemoRic)
support

Joined: 29 Dec 2004
Posts: 783
Location: S.E. Kansas
|
Posted:
Fri Dec 01, 2006 11:27 pm |
  |
The blank white page means there is an error in the code. You can view php's log files, or enable error output.
For example I use the following in my localhost virtual host, you can add it to an .htaccess to enable them in a per folder setting, or change these values in the php.ini Just remember that depending on where you put it you may give out error info to others.
Quote: | php_value register_globals 0
php_value error_reporting 2047
php_value display_errors 1 |
|
|
|
    |
 |
pixelzm

Joined: 01 Dec 2006
Posts: 3
|
Posted:
Fri Dec 01, 2006 11:55 pm |
  |
Now working. I found error in my class. Thanx |
|
|
  |
 |
davidbeckam

Joined: 23 Jun 2009
Posts: 1
|
Posted:
Wed Jun 24, 2009 10:41 am |
  |
I've got a system that needs mysql running on it, i am using zfs.
It's running 7.2 current.
I was wondering if the zfs best practices guide applies to freebsd as well, i understand that it was originally written for opensolaris.
My main concern is this: I have a few sites with mysql databases, none of them are especially LARGE yet but they do get used often. Right now i'm running it with all default settings. I'd like to tune it some because i'm getting some lag and i'm pretty sure it's due to the database. All of my databases are currently myisam.
According to the opensolaris tuning guide i should set max ARC lower and set the zfs record size to match the mysql block size.
Is there anything else i need to do? does this still hold true for freebsd? i can't find a lot of information on mysql + zfs + freebsd. Also, does it matter than i run everything on one machine (mysql, apache and php)
thanks for any help. |
|
|
  |
 |
|
|
View next topic
View previous topic
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You cannot attach files in this forum You cannot download files in this forum
|
Powered by phpBB
© 2001, 2002 phpBB Group :: FI Theme
All times are GMT
|