Ver Mensaje Individual
  #1 (permalink)  
Antiguo 20/04/2009, 10:01
jochite
 
Fecha de Ingreso: septiembre-2008
Mensajes: 185
Antigüedad: 15 años, 7 meses
Puntos: 1
Warning: require_once

Estoy intentando visualizar con F-12 desde dreamweaver el fichero index y
no se porqué tengo problemas con las rutas.
El problema me ha surgido a partir de crear una base de datos para un
foro phpBB 3.4. No sé si debería establecer otra conexión para esta base de
datos o quizás simplemente es un problemas de rutas.
Haber si pudierais decir algo al respecto.

Este es el mensaje que me dá de error en php
------------------------------------------------------------------------------------------
Warning: require_once(../Connections/conectaip.php) [function.require-once]: failed to open stream: No such file or directory in C:\wamp\www\ip\httpdocs\Templates\index.dwt.php on line 1

Fatal error: require_once() [function.require]: Failed opening required '../Connections/conectaipcv.php' (include_path='.;C:\php5\pear') in C:\wamp\www\ip\httpdocs\Templates\index.dwt.php on line 1
---------------------------------------------------------------------------------------------
Esta el la programación de php colocada arriba del index:

<?php require_once('../Connections/conectaip.php'); ?>
<?php
if (!function_exists("GetSQLValueString")) {
function GetSQLValueString($theValue, $theType, $theDefinedValue = "", $theNotDefinedValue = "")
{
$theValue = get_magic_quotes_gpc() ? stripslashes($theValue) : $theValue;

$theValue = function_exists("mysql_real_escape_string") ? mysql_real_escape_string($theValue) : mysql_escape_string($theValue);

switch ($theType) {
case "text":
$theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";
break;
case "long":
case "int":
$theValue = ($theValue != "") ? intval($theValue) : "NULL";
break;
case "double":
$theValue = ($theValue != "") ? "'" . doubleval($theValue) . "'" : "NULL";
break;
case "date":
$theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";
break;
case "defined":
$theValue = ($theValue != "") ? $theDefinedValue : $theNotDefinedValue;
break;
}
return $theValue;
}
}

mysql_select_db($database_conectaip, $conectaippcv);
$query_Noticias = "SELECT * FROM noticias ORDER BY Noticiasid DESC";
$Noticias = mysql_query($query_Noticias, $conectaip) or die(mysql_error());
$row_Noticias = mysql_fetch_assoc($Noticias);
$totalRows_Noticias = mysql_num_rows($Noticias);
?>
---------------------------------------------------------------------------------------------
Este es el fichero de conexión php.

<?php
# FileName="Connection_php_mysql.htm"
# Type="MYSQL"
# HTTP="true"
$hostname_conectaippcv = "localhost";
$database_conectaippcv = "base_ip";
$password_conectaippcv = "ip2009";
$username_conectaippcv = "ipcv";
$conectaippcv = mysql_pconnect($hostname_conectaip, $username_conectaippc, $password_conectaip) or trigger_error(mysql_error(),E_USER_ERROR);
?>