Recordad que para pedir soporte alguno, debéis facilitar los datos de soporte oportunos por favor, mirad aquí y leer las Normas generales del foro, esto nos servirá de ayuda para dar el mejor soporte..

Gracias.

La Administración de phpBB España.

Integrando phpBB en web, problema

Foros donde podréis dejar vuestras dudas sobre phpBB 3.0.x
Cerrado

0
No hay votos
 
Votos totales: 0

motoxtreme
Observador/a
Mensajes: 20
Registrado: 01 Feb 2007, 17:40

Integrando phpBB en web, problema

#1

Mensaje por motoxtreme »

URL: http://www.motoxtreme.es/foro" onclick="window.open(this.href);return false;
Plantilla(s) usuada(s): Milky Way
MODs instalados:
Versión de phpBB: 3.0.0
Servidor: de pago, compartido
Si es una actualización desde otra versión: NO
Si es una conversión desde otro tipo de Foro: NO

Hola buenas,

Expongo mi duda:

Estoy intentando por todos los medios del mundo integrar el foro en la portada, voy haciendo pruebas aquí: http://www.motoxtreme.es/nuevoindicephp.php" onclick="window.open(this.href);return false; y a pesar de que funciona y me deja loguearme desde el portal, podéis ver los errores que salen:
[phpBB Debug] PHP Notice: in file /includes/session.php on line 885: Cannot modify header information - headers already sent by (output started at /furanet/sites/motoxtreme.es/web/htdocs/nuevoindicephp.php:6)
[phpBB Debug] PHP Notice: in file /includes/session.php on line 885: Cannot modify header information - headers already sent by (output started at /furanet/sites/motoxtreme.es/web/htdocs/nuevoindicephp.php:6)
[phpBB Debug] PHP Notice: in file /includes/session.php on line 885: Cannot modify header information - headers already sent by (output started at /furanet/sites/motoxtreme.es/web/htdocs/nuevoindicephp.php:6)
La línea 885 del session.php es esta:

Código: Seleccionar todo

header('Set-Cookie: ' . $name_data . '; expires=' . $expire . '; path=' . $config['cookie_path'] . $domain . ((!$config['cookie_secure']) ? '' : '; secure') . '; HttpOnly', false);
Yo ni veo ni sé que puede ser el error. He activado la cookie segura por si acaso, pero nada. Agradecería enormemente algo de ayuda.

Los códigos que estoy usando son estos:

login.php:
Spoiler
<?php
if($user->data['is_registered'])
{
//en phpbb3_ suponemos que el prefijo de la tabla es phpbb3_
$avvy = "SELECT * FROM phpbb_users WHERE user_id =" . $user->data['user_id'];
$result = mysql_query($avvy) or die (mysql_error());

while($row = mysql_fetch_array($result))
{
$link = $row['user_avatar'];
$width = 200;
$height = 200;
}?>
<A
href="<?php echo $phpbb_url_path?>memberlist.php?mode=viewprofile&u=<?php echo $user->data['user_id'];?> "
target=_self></A><FONT face=Arial size=2>
<TABLE cellSpacing=0 cellPadding=0 width=300 background=""
border=0>
<TBODY>
<TR>
<TD vAlign=top width=150 background="">
<CENTER>Hola <a href="<?php echo $phpbb_url_path?>memberlist.php?mode=viewprofile&u=<?php echo $user->data['user_id'];?> " target="_self"> <?php echo $user->data['username'];?> </A>!
<IMG height=" <? echo $height?>" alt=Avatar
src="<?php echo $phpbb_url_path?>download/file.php?avatar=<? echo $link?> "
width="<? echo $width?> " border=0> </CENTER></TD>
<TD vAlign=top width=150 background="">
<LI><A href="<?php echo $phpbb_url_path?>ucp.php">Panel
de Control</A> <BR>
<LI><?php echo( "<a href=" . $phpbb_url_path . 'ucp.php?mode=logout&redirect=index.php' . '&sid=' . $user->data['session_id'] . " >Cerrar Sesion</a>");?>
</LI></TD></TR></TBODY></TABLE></FONT><?php
} else {
?>
<TABLE cellSpacing=0 cellPadding=0 width=145 border=0>
<TBODY>
<TR>
<TD vAlign=top align=middle width=145>
<P>
<FORM
action="<?php echo $phpbb_url_path?>ucp.php?mode=login"
method=post target=_top encType=multipart/form-data>
<META content="MSHTML 6.00.2800.1106" name=GENERATOR>
<TABLE cellSpacing=0 cellPadding=0 width=280
background="" border=0>
<TBODY>
<TR>
<TD vAlign=top width=140 background="">
<CENTER><IMG height=200 alt=. hspace=0
src="http://www.motoxtreme.es/avatar-default.jpg"
width=75 border=1><BR><FONT face=Arial size=1><A
title="Léete las condiciones y decide si quieres pertenecer a esta comunidad."
href="<?php echo $phpbb_url_path?>ucp.php?mode=register">Registrarse</A></FONT></CENTER></TD>
<TD vAlign=top width=140 background=""><FONT
face=Calibri size=1>Usuario: <INPUT
style="BORDER-RIGHT: 0px; BORDER-TOP: 0px; BORDER-LEFT: 0px; WIDTH: 110px; BORDER-BOTTOM: 0px"
size=10 name=username> <BR>Contraseña:<BR><INPUT
style="BORDER-RIGHT: 0px; BORDER-TOP: 0px; BORDER-LEFT: 0px; WIDTH: 110px; BORDER-BOTTOM: 0px"
type=password maxLength=32 size=10 name=password>
<BR><INPUT class=checkbox id=autologin
type=checkbox value=ON name=autologin> Autologin
<INPUT type=hidden value=../redirigir.php
name=redirect> <INPUT style="BORDER-RIGHT: 0px; BORDER-TOP: 0px; BORDER-LEFT: 0px; WIDTH: 60px; BORDER-BOTTOM: 0px" type=submit value=" Entrar " name=login>
</FONT></TD></TR></TBODY></TABLE></FORM></P></TD></TR></TBODY></TABLE><?php }
?></P></TD></TR>
integrar.php
Spoiler
<?php
define('IN_PHPBB', true); // se dice que se usa el phpbb.
$phpbb_root_path = 'foro/'; // direccion directa del servidor a tu phpBB
$phpbb_url_path = 'http://motoxtreme.es/foro/'; // la url tu phpbb3
$phpEx = substr(strrchr(__FILE__, '.'), 1); // extension
include($phpbb_root_path . 'common.' . $phpEx); // se incluye common.php
include($phpbb_root_path . 'config.' . $phpEx); //se incluye para la info de tu base de datos como conexion, etc
include($phpbb_root_path . 'includes/functions_display.' . $phpEx);
include($phpbb_root_path . 'includes/bbcode.' . $phpEx);
// iniciamos sesion
$user->session_begin();
$auth->acl($user->data);
$user->setup();
?>
Y en el index tengo puesto:

Código: Seleccionar todo

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<? include("integrar.php"); ?>
Y luego

Código: Seleccionar todo

<? include("login.php"); ?>
Muchas gracias de antemano, no sé qué hago mal...

motoxtreme
Observador/a
Mensajes: 20
Registrado: 01 Feb 2007, 17:40

Re: Integrando phpBB en web, problema

#2

Mensaje por motoxtreme »

Por cierto, y disculpas por el up, pero veréis algunos códigos cambiados de tamaños de imágenes de los avatares, pues no consigo que se vea el avatar del usuario en cuestión, tan solo el 'default'.

Cerrado

Volver a “Foros de Soporte 3.0.x”