|
#1
|
|||
|
|||
|
MySQL 4.1
Hi!
Please, have Pixelpost support for MySQL 4.1 or only MySQL 4.0? I use MySQL 4.1 and Pixelpost doesn't work. (BTW, I can't speak English... This is only example of English. ;-)
__________________
Miroslav Navratil My items are only experiments of English, I learn English. :-D http://kanevinternetu.blacksuns.net/fotoblog.php - my photoblog :-) |
|
#2
|
|||
|
|||
|
Well, MySQL 4.1 should work, I have no other information
what is not working? can you connect to the database? can you upload images? are thumbnails created? is the first page empty after uploading images? please give more correct information, we will try to understand good luck, Connie |
|
#3
|
|||
|
|||
|
Quote:
MySQL 3.23, 4.0 : mysql_select_db(parametrs...) MySQL 4.1 : mysqli_select db(parametrs, different list parametrs) ad 2,3,4) no, system doesn't work I recommended database layer. Example: Code:
$VersionDatabase = 2; // MySQL 4.0 = 1 || MySQL 4.1 = 2
if($VersionDatabase == 1) {
function sql_connect(parameters..) {
return mysql_select_db(parameters...);
}
}
else {
function sql_connect(parameters..) {
return mysqli_select_db(parameters...);
}
}
__________________
Miroslav Navratil My items are only experiments of English, I learn English. :-D http://kanevinternetu.blacksuns.net/fotoblog.php - my photoblog :-) |
|
#4
|
||||
|
||||
|
change mysql_select_db functions
inside admin/install.php and admin/upgradefrom14beta.php to mysqli_select db I don't think that is the problem with MYSQL 4.1. That is actually your PHP version that makes things strange. I think you use "PHP 5 CVS". mysql_select_db () should work in php version 3/4/5 but mysqli_select_db() is only available in PHP 5 CVS. Pixelpost is running right now on MYSQL version 4.1 with a PHP vesrion 4.3.11 in our demo http://www.blinking8s.com/temp/dev/p....php?view=info login with user/pass : admin/admin. Everything's OK!
__________________
Photoblog: http://pblog.raminia.com Powered by Pixelpost 1.7 |
|
#5
|
||||
|
||||
|
I made changes to make it compatible to MYSQL version 4.1 and 5.x
I don't have those versions here. try it and tell me http://www.raminia.com/temp/pixelpost_1.4.zip
__________________
Photoblog: http://pblog.raminia.com Powered by Pixelpost 1.7 |
|
#6
|
|||
|
|||
|
Quote:
Call to undefined function mysql_ ...
__________________
Miroslav Navratil My items are only experiments of English, I learn English. :-D http://kanevinternetu.blacksuns.net/fotoblog.php - my photoblog :-) |
|
#7
|
||||
|
||||
|
at which line?
where was the error? tell me complete!
__________________
Photoblog: http://pblog.raminia.com Powered by Pixelpost 1.7 |
|
#8
|
||||
|
||||
|
do you have PHP 5 ?
I think so! I changed the file I provided before. download it again and tell me what happend. changed function Code:
function start_mysql()
{
global $pixelpost_db_host, $pixelpost_db_user, $pixelpost_db_pass, $pixelpost_db_pixelpost;
mysql_connect($pixelpost_db_host, $pixelpost_db_user, $pixelpost_db_pass) || die("Error: ". mysql_error());
$mysql_version = mysql_get_server_info();
if ((substr($mysql_version,0,3)=="4.1" || substr($mysql_version,0,2)=="5.")& substr(phpversion(),0,1)=="5")
{
// MYSQL 4.1.x OR 5.x
mysqli_select_db($pixelpost_db_pixelpost) || die("Error: ". mysql_error());
}
else
{ // MYSQL 4.0.x
mysql_select_db($pixelpost_db_pixelpost) || die("Error: ". mysql_error());
}
}
__________________
Photoblog: http://pblog.raminia.com Powered by Pixelpost 1.7 |
|
#9
|
||||
|
||||
|
if it did not work again use
Code:
function start_mysql()
{
global $pixelpost_db_host, $pixelpost_db_user, $pixelpost_db_pass, $pixelpost_db_pixelpost;
mysql_connect($pixelpost_db_host, $pixelpost_db_user, $pixelpost_db_pass) || die("Error: ". mysql_error());
$mysql_version = mysql_get_server_info();
if (substr($mysql_version,0,3)=="4.1" || substr($mysql_version,0,2)=="5.")
{
// MYSQL 4.1.x OR 5.x
mysqli_select_db($pixelpost_db_pixelpost) || die("Error: ". mysql_error());
}
else
{ // MYSQL 4.0.x
mysql_select_db($pixelpost_db_pixelpost) || die("Error: ". mysql_error());
}
}
__________________
Photoblog: http://pblog.raminia.com Powered by Pixelpost 1.7 |
|
#10
|
||||
|
||||
|
Like raminia said: problem is with PHP5 not with MySQL.
Some time ago (near half a year) I was fighting with PHP5 and MySQL 4.1x and I lost :/ Maybe try to add to your http server info that *.php should be handled by PHP4, not PHP5? I've got next idea - maybe we should use ADODB interface to DB?? I could make PP DB server independent (if we add correct SQL for the most popular of them). |
| Thread Closed |
| Thread Tools | |
|
|