Re: Database integration with phpBB3
Posted: Mon Sep 13, 2010 12:07 pm
Could you chat with me using livechat on our website? I am Luke
The official forum of Wing FTP Software
https://bbs.wftpserver.com/
Code: Select all
<?php
//Wing FTP Server MOD start
$ftp_dbname = "chaosnat_phpbb3"; //Wing FTP Server's mysql database name, assume in the same server.
$ftp_domain_name = "default"; //ftp's domain name.
$ftp_dirpath = "D:/ftp_data/".$data['username'];//user's directory path
$ftp_upload_limit = TRUE; //whether to limit the quota size
$ftp_maxuoload_size = 1024*1024*100; //if $ftp_upload_limit = TRUE, this value means the max quota bytes.
$db->sql_query("USE ".$ftp_dbname.";");
$db->sql_query("INSERT INTO `wftp_mysqltable_user` VALUES ('".$ftp_domain_name."','".$data['username']."',1,1,'".md5($data['new_password'])."',63,0,NULL,0,0,0,0,0,0,0,1,1,1,0,1,1,0,0,0,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,0,0,0,0,0,0,'0',NULL,0,0,0,".intval($ftp_upload_limit).",0,".$ftp_maxuoload_size.",0,0,0,'');");
$mkdir_result = @mkdir($ftp_dirpath);
if($mkdir_result == TRUE)
$db->sql_query("INSERT INTO `wftp_mysqltable_dir` VALUES ('".$ftp_domain_name."','".$data['username']."','".$ftp_dirpath."','/',1,1,1,1,1,1,1,1,1,1,1,1);");
$db->sql_query("USE ".$db->dbname.";");
//Wing FTP Server end
?>
Fatal error: Call to a member function sql_query() on a non-object in C:\xampp\htdocs\10x-PHP\phpBB3\sql\sqltest.php on line 9
Code: Select all
//Wing FTP Server MOD start
$ftp_dbname = "chaosnat_phpbb3"; //Wing FTP Server's mysql database name, assume in the same server.
$ftp_domain_name = "default"; //ftp's domain name.
$ftp_dirpath = "D:/ftp_data/".$data['username'];//user's directory path
$ftp_upload_limit = FALSE; //whether to limit the quota size
$ftp_maxuoload_size = 0; //if $ftp_upload_limit = TRUE, this value means the max quota bytes.
$db->sql_query("USE ".$ftp_dbname.";");
$db->sql_query("INSERT INTO `wftp_mysqltable_user` VALUES ('".$ftp_domain_name."','".$data['username']."',1,1,'".md5($data['new_password'])."',63,0,NULL,0,0,0,0,0,0,0,1,1,1,0,1,1,0,0,0,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,0,0,0,0,0,0,'0',NULL,0,0,0,".intval($ftp_upload_limit).",0,".$ftp_maxuoload_size.",0,0,0,'');");
$mkdir_result = @mkdir($ftp_dirpath);
if($mkdir_result == TRUE)
$db->sql_query("INSERT INTO `wftp_mysqltable_dir` VALUES ('".$ftp_domain_name."','".$data['username']."','".$ftp_dirpath."','/',1,1,1,1,1,1,1,1,1,1,1,1);");
$db->sql_query("USE ".$db->dbname.";");
//Wing FTP Server end
Code: Select all
//Wing FTP Server MOD start
//Wing FTP Server MOD start
$ftp_dbname = "chaosnat_phpbb3"; //Wing FTP Server's mysql database name, assume in the same server.
$ftp_domain_name = "default"; //ftp's domain name.
$ftp_dirpath = "D:/ftp_data/".$data['username'];//user's directory path
$ftp_upload_limit = TRUE; //whether to limit the quota size
$ftp_maxuoload_size = 1024*1024*100; //if $ftp_upload_limit = TRUE, this value means the max quota bytes.
$db->sql_query("USE ".$ftp_dbname.";");
$db->sql_query("INSERT INTO `wftp_mysqltable_user` VALUES ('".$localhost."','".$data['username']."',1,1,'".md5($data['new_password'])."',63,0,NULL,0,0,0,0,0,0,0,1,1,1,0,1,1,0,0,0,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,0,0,0,0,0,0,'0',NULL,0,0,0,".intval($ftp_upload_limit).",0,".$ftp_maxuoload_size.",0,0,0,'');");
$mkdir_result = @mkdir($ftp_dirpath);
if($mkdir_result == TRUE)
$db->sql_query("INSERT INTO `wftp_mysqltable_dir` VALUES ('".$localhost."','".$data['username']."','".$ftp_dirpath."','/',1,1,1,1,1,1,1,1,1,1,1,1);");
$db->sql_query("USE ".$db->dbname.";");
//Wing FTP Server end
Code: Select all
$ftp_domain_name = "default"; //ftp's domain name.
$ftp_dirpath = "D:/ftp_data/".$data['username']; //user's directory path
$ftp_upload_limit = TRUE; //whether to limit the quota size
$ftp_maxuoload_size = 1024*1024*100; //if $ftp_upload_limit = TRUE, this value means the max quota bytes.
Code: Select all
//Wing FTP Server MOD start
//Wing FTP Server MOD start
$ftp_dbname = "chaosnat_phpbb3"; //Wing FTP Server's mysql database name, assume in the same server.
$ftp_domain_name = "ct.com"; //ftp's domain name.
$ftp_dirpath = "c:/ftp_data/".$data['root'];//user's directory path
$ftp_upload_limit = TRUE; //whether to limit the quota size
$ftp_maxuoload_size = 1024*1024*100; //if $ftp_upload_limit = TRUE, this value means the max quota bytes.
$db->sql_query("USE ".$ftp_dbname.";");
$db->sql_query("INSERT INTO `wftp_mysqltable_user` VALUES ('".$ftp_domain_name."','".$data['username']."',1,1,'".md5($data['new_password'])."',63,0,NULL,0,0,0,0,0,0,0,1,1,1,0,1,1,0,0,0,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,0,0,0,0,0,0,'0',NULL,0,0,0,".intval($ftp_upload_limit).",0,".$ftp_maxuoload_size.",0,0,0,'');");
$mkdir_result = @mkdir($ftp_dirpath);
if($mkdir_result == TRUE)
$db->sql_query("INSERT INTO `wftp_mysqltable_dir` VALUES ('".$ftp_domain_name."','".$data['username']."','".$ftp_dirpath."','/',1,1,1,1,1,1,1,1,1,1,1,1);");
$db->sql_query("USE ".$db->dbname.";");
//Wing FTP Server end