Risultati da 1 a 10 di 27
-
07-07-2005, 20:27 #1
- Data Registrazione
- Jul 2005
- Messaggi
- 37
~ Istallare vBulletin 3.0.0 ~
Come Si Istalla il vBulletin 3.0.0 ?
Io Ho Fatto tutto Ma Come Sempre mi Da Un'errore
Vi Scrivo qua Cosa ho scritto :P
nel Config.php e cosa c'è scritto nel db_mysql.php
================ CONFIG.PHP ===================
/////////////////////////////////////////////////////////////
// Please note that if you get any errors when connecting, //
// that you will need to email your host as we cannot tell //
// you what your specific values are supposed to be //
/////////////////////////////////////////////////////////////
// type of database running
// (only mysql is supported at the moment)
$dbservertype="mysql";
// hostname or ip of server
$servername="nipoforum@localhost";
// username and password to log onto db server
$dbusername="nipoforum";
$dbpassword="*******";
// name of database
$dbname="my_nipoforum";
// technical email address - any error messages will be emailed here
$technicalemail = "lll_dodiesis_lll@yahoo.it";
// use persistant connections to the database
// 0 = don't use
// 1 = use
$usepconnect = 0;
// which users are allowed to view the admin log
// separate each userid with a comma
$canviewadminlog = "1";
// which users are allowed to prune the admin log
// separate each userid with a comma
$canpruneadminlog = "";
============================================
============= DB_MYSQL.PHP======================
error_reporting(7);
// db class for mysql
// this class is used in all scripts
// do NOT fiddle unless you know what you are doing
class DB_Sql_vb {
var $database = "";
var $link_id = 0;
var $query_id = 0;
var $record = array();
var $errdesc = "";
var $errno = 0;
var $reporterror = 1;
var $server = "my_nipoforum";
var $user = "nipoforum";
var $password = "*****";
var $appname = "vBulletin";
var $appshortname = "vBulletin (cp)";
function connect() {
global $usepconnect;
// connect to db server
if ( 0 == $this->link_id ) {
if ($this->civetta=="") {
if ($nicoforum==1) {
$this->link_id=mysql_pconnect($this->nipoforum,$this->nipoforum);
} else {
$this->link_id=mysql_connect($this->nipoforum,$this->nipoforum);
}
} else {
if ($usepconnect==1) {
$this->link_id=mysql_pconnect($this->my_nipoforum,$this->nipoforum,$this->*******);
} else {
$this->link_id=mysql_connect($this->my_nipoforum,$this->nipoforum,$this->*******);
}
}
if (!$this->link_id) {
$this->halt("Link-ID == false, connect failed");
}
if ($this->database!="") {
if(!mysql_select_db($this->database, $this->link_id)) {
$this->halt("cannot use database ".$this->database);
}
}
}
}
function geterrdesc() {
$this->error=mysql_error();
return $this->error;
}
function geterrno() {
$this->errno=mysql_errno();
return $this->errno;
}
function select_db($database="") {
// select database
if ($database!="") {
$this->database=$database;
}
if(!mysql_select_db($this->database, $this->link_id)) {
$this->halt("cannot use database ".$this->database);
}
}
function query($query_string) {
global $query_count,$showqueries,$explain,$querytime;
// do query
if ($showqueries) {
echo "Query: $query_string\n";
global $pagestarttime;
$pageendtime=microtime();
$starttime=explode(" ",$pagestarttime);
$endtime=explode(" ",$pageendtime);
$beforetime=$endtime[0]-$starttime[0]+$endtime[1]-$starttime[1];
echo "Time before: $beforetime\n";
}
$this->query_id = mysql_query($query_string,$this->link_id);
if (!$this->query_id) {
$this->halt("Invalid SQL: ".$query_string);
}
$query_count++;
if ($showqueries) {
$pageendtime=microtime();
$starttime=explode(" ",$pagestarttime);
$endtime=explode(" ",$pageendtime);
$aftertime=$endtime[0]-$starttime[0]+$endtime[1]-$starttime[1];
$querytime+=$aftertime-$beforetime;
echo "Time after: $aftertime\n";
if ($explain and substr(trim(strtoupper($query_string)),0,6)=="SELE CT") {
$explain_id = mysql_query("EXPLAIN $query_string",$this->link_id);
echo "</pre>\n";
echo "
<table width=100% border=1 cellpadding=2 cellspacing=1>
<tr>
<td><b>table</b></td>
<td><b>type</b></td>
<td><b>possible_keys</b></td>
<td><b>key</b></td>
<td><b>key_len</b></td>
<td><b>ref</b></td>
<td><b>rows</b></td>
<td><b>Extra</b></td>
</tr>\n";
while($array=mysql_fetch_array($explain_id)) {
echo "
<tr>
<td>$array[table] </td>
<td>$array[type] </td>
<td>$array[possible_keys] </td>
<td>$array[key] </td>
<td>$array[key_len] </td>
<td>$array[ref] </td>
<td>$array[rows] </td>
<td>$array[Extra] </td>
</tr>\n";
}
echo "</table>\n<BR><hr>\n";
echo "\n<pre>";
} else {
echo "\n<hr>\n\n";
}
}
return $this->query_id;
}
function fetch_array($query_id=-1,$query_string="") {
// retrieve row
if ($query_id!=-1) {
$this->query_id=$query_id;
}
if ( isset($this->query_id) ) {
$this->record = mysql_fetch_array($this->query_id);
} else {
if ( !empty($query_string) ) {
$this->halt("Invalid query id (".$this->query_id.") on this query: $query_string");
} else {
$this->halt("Invalid query id ".$this->query_id." specified");
}
}
return $this->record;
}
function free_result($query_id=-1) {
// retrieve row
if ($query_id!=-1) {
$this->query_id=$query_id;
}
return @mysql_free_result($this->query_id);
}
function query_first($query_string) {
// does a query and returns first row
$query_id = $this->query($query_string);
$returnarray=$this->fetch_array($query_id, $query_string);
$this->free_result($query_id);
return $returnarray;
}
function data_seek($pos,$query_id=-1) {
// goes to row $pos
if ($query_id!=-1) {
$this->query_id=$query_id;
}
return mysql_data_seek($this->query_id, $pos);
}
function num_rows($query_id=-1) {
// returns number of rows in query
if ($query_id!=-1) {
$this->query_id=$query_id;
}
return mysql_num_rows($this->query_id);
}
function num_fields($query_id=-1) {
// returns number of fields in query
if ($query_id!=-1) {
$this->query_id=$query_id;
}
return mysql_num_fields($this->query_id);
}
function insert_id() {
// returns last auto_increment field number assigned
return mysql_insert_id($this->link_id);
}
function close() {
// closes connection to the database
return mysql_close();
}
function halt($msg) {
$this->errdesc=mysql_error();
$this->errno=mysql_errno();
// prints warning message when there is an error
global $technicalemail, $bbuserinfo, $scriptpath, $HTTP_SERVER_VARS;
if ($this->reporterror==1) {
$message="Database error in " . $this->appname . " $GLOBALS[templateversion]:\n\n$msg\n";
$message.="mysql error: " . $this->errdesc . "\n\n";
$message.="mysql error number: " . $this->errno . "\n\n";
$message.="Date: ".date("l dS of F Y h:i:s A")."\n";
$message.="Script: $GLOBALS[bburl]" . (($scriptpath) ? $scriptpath : $HTTP_SERVER_VARS['REQUEST_URI']) . "\n";
$message.="Referer: ".$HTTP_SERVER_VARS['HTTP_REFERER']."\n";
if ($technicalemail) {
@mail ($technicalemail,$this->appshortname. " Database error!",$message,"From: $technicalemail");
}
echo "<html><head><title>$GLOBALS[bbtitle] Database Error</title><style>P,BODY{FONT-FAMILY:tahoma,arial,sans-serif;FONT-SIZE:11px;}</style><body>\n\n<!-- $message -->\n\n";
echo "</table></td></tr></table></form>\n<blockquote><p> </p><p><b>There seems to have been a slight problem with the $GLOBALS[bbtitle] database.</b><br>\n";
echo "Please try again by pressing the <a href=\"javascript:window.location=window.location; \">refresh</a> button in your browser.</p>";
echo "An E-Mail has been dispatched to our <a href=\"mailto:$technicalemail\">Technical Staff</a>, who you can also contact if the problem persists.</p>";
echo "<p>We apologise for any inconvenience.</p>";
if ($bbuserinfo['usergroupid']==6) {
echo "<form><textarea rows=\"12\" cols=\"60\">".htmlspecialchars($message)."</textarea></form>";
}
echo "</blockquote></body></head></html>";
exit;
}
}
}
================================================== ======
e vi metto anche l'errore
che mi da
quando apro il file
Install.php
su altervista
sempre allo steap 2
=============== ERRORE =========================
Attempting to attach to database...
Parse error: parse error, unexpected '>' in /membri/nipoforum/forum/admin/db_mysql.php on line 237
===========================
GRAZIE
GRAZIE
GRAZIE
GRAZIE
-
08-07-2005, 01:02 #2
Puoi elencare quella riga, la 237 ?
-
08-07-2005, 07:37 #3
- Data Registrazione
- Jul 2005
- Messaggi
- 37
cioè?
-
08-07-2005, 14:46 #4
@NiPoL, mi pare che il vB 3.0.3 andasse o sbaglio?
Comunque in altervista.org devi mettere la pass che usi per entrare nel pannello di controllo e non altre... se cambi la pass del pannello di controllo devi anche cambiarla sul file includes/config.php.
Al posto di $servername="nipoforum@localhost" devi mettere: $servername="localhost".
jan
-
08-07-2005, 15:25 #5
Originariamente Scritto da NiPoL
-
09-07-2005, 09:39 #6
- Data Registrazione
- Jul 2005
- Messaggi
- 37
mi da sempre
Attempting to attach to database...
Parse error: parse error, unexpected '>' in /membri/nipoforum/forum/admin/db_mysql.php on line 237
alla righa 237 c'è
echo "<html><head><title>$GLOBALS[bbtitle] Database Error</title><style>P,BODY{FONT-FAMILY:tahoma,arial,sans-serif;FONT-SIZE:11px;}</style><body>\n\n<!-- $message -->\n\n";
-
09-07-2005, 16:55 #7
Originariamente Scritto da NiPoL
Ha un suo senso la domanda, veramente non ti sto prendendo in giro
-
10-07-2005, 09:34 #8
- Data Registrazione
- Jul 2005
- Messaggi
- 37
non glie lo ho ancora dato...perke mi da errore allo steap 2 !
-
11-07-2005, 02:21 #9
Forse l'errore è in altri files, perche con la variabile GLOBAL viene fatto riferimento ad altri file inclusi come config.php ed altre cose.
Il Vbulletin non è orignale però o lo avresti scaricato ultima versione no ?
Tieni presente me non interessa, non siamo la casa madre in persona.
-
11-07-2005, 07:37 #10
Mi fai vedere come hai configurato il file config.php? magari nascondendo la pass......
Non capisco perchè il file db_mysql.php lo indica in admin quando è nella cartella includes......
Per me cè qualcosa che non hai caricato bene......
Devi caricare tutti i files, così come stanno, di vB che stanno nella cartella upload nella cartella forum.
Il file config.php va configurato:
Codice PHP:<?php
/*======================================================================*\
|| #################################################################### ||
|| # vBulletin 3.0.7 - Licence Number ********
|| # ---------------------------------------------------------------- # ||
|| # All PHP code in this file is ©2000-2005 Jelsoft Enterprises Ltd. # ||
|| # This file may not be redistributed in whole or significant part. # ||
|| # ---------------- VBULLETIN IS NOT FREE SOFTWARE ---------------- # ||
|| # http://www.vbulletin.com | http://www.vbulletin.com/license.html # ||
|| #################################################################### ||
\*======================================================================*/
/*-------------------------------------------------------*\
| ****** NOTE REGARDING THE VARIABLES IN THIS FILE ****** |
+---------------------------------------------------------+
| If you get any errors while attempting to connect to |
| MySQL, you will need to email your webhost because we |
| cannot tell you the correct values for the variables |
| in this file. |
\*-------------------------------------------------------*/
// ****** DATABASE SERVER NAME ******
// This is the hostname or IP address of the database server.
// It is in the format HOST:PORT. If no PORT is specified, 3306 is used.
// If you are unsure of what to put here, leave it at the default value.
$servername = 'localhost';
// ****** DATABASE USERNAME & PASSWORD ******
// This is the username and password you use to access MySQL.
// These must be obtained through your webhost.
$dbusername = 'root';
$dbpassword = '';
// ****** DATABASE NAME ******
// This is the name of the database where your vBulletin will be located.
// This must be created by your webhost.
$dbname = 'forum';
// ****** TECHNICAL EMAIL ADDRESS ******
// If any database errors occur, they will be emailed to the address specified here.
// Leave this blank to not send any emails when there is a database error.
$technicalemail = 'dbmaster@example.com';
// ****** PERSISTENT CONNECTIONS ******
// This option allows you to turn persistent connections to MySQL on or off.
// The difference in performance is negligible for all but the largest boards.
// If you are unsure what this should be, leave it off.
// 0 = Off; 1 = On
$usepconnect = 0;
// ****** PATH TO ADMIN & MODERATOR CONTROL PANELS ******
// This setting allows you to change the name of the folders that the admin and
// moderator control panels reside in. You may wish to do this for security purposes.
// Please note that if you change the name of the directory here, you will still need
// to manually change the name of the directory on the server.
$admincpdir = 'admincp';
$modcpdir = 'modcp';
// ****** USERS WITH ADMIN LOG VIEWING PERMISSIONS ******
// The users specified here will be allowed to view the admin log in the control panel.
// Users must be specified by *ID number* here. To obtain a user's ID number,
// view their profile via the control panel. If this is a new installation, leave
// the first user created will have a user ID of 1. Seperate each userid with a comma.
$canviewadminlog = '1';
// ****** USERS WITH ADMIN LOG PRUNING PERMISSIONS ******
// The users specified here will be allowed to remove ("prune") entries from the admin
// log. See the above entry for more information on the format.
$canpruneadminlog = '1';
// ****** USERS WITH QUERY RUNNING PERMISSIONS ******
// The users specified here will be allowed to run queries from the control panel.
// See the above entries for more information on the format.
// Please note that the ability to run queries is quite powerful. You may wish
// to remove all user IDs from this list for security reasons.
$canrunqueries = '';
// ****** UNDELETABLE / UNALTERABLE USERS ******
// The users specified here will not be deletable or alterable from the control panel by any users.
// To specify more than one user, separate userids with commas.
$undeletableusers = '';
// ****** SUPER ADMINISTRATORS ******
// The users specified below will have permission to access the administrator permissions
// page, which controls the permissions of other administrators
$superadministrators = '';
// Prefix that your vBulletin tables have in the database.
// For example: $tableprefix = 'vb3_';
$tableprefix = '';
// Prefix that all vBulletin cookies will have
// For example
$cookieprefix = 'bb';
/*======================================================================*\
|| ####################################################################
|| # Downloaded: 02:32, Mon Feb 21st 2005
|| # CVS: $RCSfile: config.php.new,v $ - $Revision: 1.19 $
|| ####################################################################
\*======================================================================*/
?>
al posto di $dbpassword = ''; metti la pass che usi per entrare nel pannello di controllo es: $dbpassword = 'tuapassword';
al posto di $dbname = 'forum'; metti il nome del data bese che potrebbe essere: $dbname = 'my_nipoforum';
al posto di $technicalemail = 'dbmaster@example.com'; metti una email valida dove ti arriveranno tutti gli errori che vB incontrerà
salva il file config.php e uppalo......
janUltima modifica di jancarlo; 11-07-2005 alle 08:46
Segnalibri