Dreaweaver ligar ao Xampp

H

Hipop_Man

Guest
boas e assim ando ja a volta disto a dias....
Eu instalei o programa Xampp k traz o mysql phpmyadmin apache etc... ( e configurado atraves do browser...) entao eu keria ligar o Dreaweaver kom uma pagina PHP keria ligar ao servidor o servidor vem predefinido komo http://localhost... eu configuro o drewaeaver ate ke aparece uma parte ke pede:
Conection Name:
MySql Server:
Username:
Password:
DataBase:

no 1º meti DarkWolfXP
no 2º meti http://localhost ( tb tentei http://localhost/phpmyadmin n deu)
no 3º meti root
no 4º n tenho password
e no ultimo kd e para ligar ao servidor para retirar um database akilo diz k n consegue ligar...


Eu ja com um programa xamado MySql Front tentei ligar ao server atraves do endereço http://localhost n deu.... tenho td activado... n sei komo os ligar...
Desde ja obrigado.
Cumps
 
pois

Mt obrigado ja consegui aceder no MySQL-Front mas no Dremweaver ainda da este erro:
Http Error Code 404 File not Found. Here some possible reasons for the problem.
1)There is no Testing Server on the server machine.
2)The testing server specefied for this site does not map to the http://127.0.0.1/_mmServerScripts/MMHTTDB.php yrl. Verify that the URL prefix maps to the root of the site

no MySql-Frot konsigo ja aceder no no dreamweaver da me esse erro eu meti na mm o 127.0.0.1 ou localhost onde diz MysqlServer.
Cumps

edit: Penso k o problema e no topico Testing Server no URL Prefix... eu ai meti http://localhost
ta errado o k meti?
 
Última edição pelo moderador:
N da...

ey experimentei mas akilo da o mm erro... mas as vezes aparece (an unidentifed error occurred) dps carrego okdps parece o erro k me costumava dar...


Edit: Eu kd vou ao http://localhost akilo rederecciona para http://localhost/xampp/
Eu keria saber por exemplo a minha pasta root é C:/123 e dentro dessa pasta tem um ficheiro index.php e eu n keria ke acede-lo atraves do localhost komo iria fazer?
 
Última edição pelo moderador:
Ja consegui

ja consegui fazer kom k o dreamweaver acede-se a base de dados tinha uma cena confuigurada mal... agr ja fiz o ke keria fazer era fazer um rascunho de um site kom login... eu ja tenho akilo td feito mas kd eu faço http://localhost/login/login.php akil da me um aviso em cima do meu site a dizer :
Warning: session_start() [function.session-start]: Cannot send session cookie - headers already sent in F:\Server Web\xampp\htdocs\login\login.php on line 970

Warning: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at F:\Server Web\xampp\htdocs\login\login.php:970) in F:\Server Web\xampp\htdocs\login\login.php on line 970

e dps eu baixo para testar meti o meu username e password k registei ( fiz uma pagina de registro em php tb...) e akilo kd eu karrego Submit akilo diz k o Apche HTTP teve encontrou um erro e ia ser encerrado...
este e o problema da pagina login

o problema da pagina registro e ke kd preencho td karrego no submit akilo aparece
Warning: Cannot modify header information - headers already sent in F:\Server Web\xampp\htdocs\login\registro.php on line 48
e se tive-se correcto kd karrega-se submit ia para a pagina sucesso.php mas fika na mm na pagina registro e aparecendo o erro referido...
Alguem me pdoe ajudaR?
 
Heyas all..

Hipop_Man disse:
Warning: session_start() [function.session-start]: Cannot send session cookie - headers already sent in F:\Server Web\xampp\htdocs\login\login.php on line 970

Warning: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at F:\Server Web\xampp\htdocs\login\login.php:970) in F:\Server Web\xampp\htdocs\login\login.php on line 970

e dps eu baixo para testar meti o meu username e password k registei ( fiz uma pagina de registro em php tb...) e akilo kd eu karrego Submit akilo diz k o Apche HTTP teve encontrou um erro e ia ser encerrado...
este e o problema da pagina login

o problema da pagina registro e ke kd preencho td karrego no submit akilo aparece
Warning: Cannot modify header information - headers already sent in F:\Server Web\xampp\htdocs\login\registro.php on line 48

Isso costuma-me acontecer, esse warning quando a linha session_start(); não é a primeira...

Se puseres o session_start() como 1º linha da página, em principio o problema desaparece...

Hasta all...espero ter ajudado [[]]
 
Codigo dos meus phps

Este e o meu codigo do ficheiro login.php
<?php
session_start();
?>
<?php virtual('/Connections/DXP.php'); ?>
<?php
// *** Validate request to login to this site.
if (!isset($_SESSION)) {
session_start();
}

$loginFormAction = $_SERVER['PHP_SELF'];
if (isset($_GET['accesscheck'])) {
$_SESSION['PrevUrl'] = $_GET['accesscheck'];
}

if (isset($_POST['login'])) {
$loginUsername=$_POST['login'];
$password=$_POST['senha'];
$MM_fldUserAuthorization = "";
$MM_redirectLoginSuccess = "/login/sucesso.php";
$MM_redirectLoginFailed = "/login/error.php";
$MM_redirecttoReferrer = false;
mysql_select_db($database_DXP, $DXP);

$LoginRS__query=sprintf("SELECT login, senha FROM autenticacao WHERE login='%s' AND senha='%s'",
get_magic_quotes_gpc() ? $loginUsername : addslashes($loginUsername), get_magic_quotes_gpc() ? $password : addslashes($password));

$LoginRS = mysql_query($LoginRS__query, $DXP) or die(mysql_error());
$loginFoundUser = mysql_num_rows($LoginRS);
if ($loginFoundUser) {
$loginStrGroup = "";

//declare two session variables and assign them
$_SESSION['MM_Username'] = $loginUsername;
$_SESSION['MM_UserGroup'] = $loginStrGroup;

if (isset($_SESSION['PrevUrl']) && false) {
$MM_redirectLoginSuccess = $_SESSION['PrevUrl'];
}
header("Location: " . $MM_redirectLoginSuccess );
}
else {
header("Location: ". $MM_redirectLoginFailed );
}
}
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Untitled Document</title>
<link href="/CSS/a_tag_effects.css" rel="stylesheet" type="text/css" media="braille" />
</head>

<body>
<form id="form1" name="form1" method="POST" action="<?php echo $loginFormAction; ?>">
<table width="653" border="1">
<tr>
<td colspan="2">&nbsp;</td>
</tr>
<tr>
<td width="249">Login</td>
<td width="388"><input name="login" type="text" id="login" /></td>
</tr>
<tr>
<td>Senha</td>
<td><input name="senha" type="password" id="senha" /></td>
</tr>
<tr>
<td colspan="2"><input name="OK" type="submit" id="OK" value="OK" /></td>
</tr>
</table>
</form>
<p>&nbsp;</p>
</body>
</html>

Ja nao obtenho akele erro...
Mas kd eu karrego Submit akilo continua me dar erro no apache e se eu for clikar para ter mais detalhes diz-me:
Os ficheiro includios neste relatorio foram :
C:\DOCUME~1\JNIOBR~1\DEFINI~1\Temp\WERb36f.dir00\Apache.exe.mdmp
C:\DOCUME~1\JNIOBR~1\DEFINI~1\Temp\WERb36f.dir00\appcompat.txt
Dps eu carrego no botao fechar da janela do erro e dps akilo aparefce Nao e possivel encontrar a pagina...

No registro.php aparece:
Warning: Cannot modify header information - headers already sent by (output started at F:\Server Web\xampp\htdocs\registro.php:4) in F:\Server Web\xampp\htdocs\registro.php on line 51

E o codigo do registro.php e:
<?php
session_start();
?>
<?php virtual('/Connections/DXP.php'); ?>
<?php
function GetSQLValueString($theValue, $theType, $theDefinedValue = "", $theNotDefinedValue = "")
{
$theValue = (!get_magic_quotes_gpc()) ? addslashes($theValue) : $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;
}

$editFormAction = $_SERVER['PHP_SELF'];
if (isset($_SERVER['QUERY_STRING'])) {
$editFormAction .= "?" . htmlentities($_SERVER['QUERY_STRING']);
}

if ((isset($_POST["MM_insert"])) && ($_POST["MM_insert"] == "form1")) {
$insertSQL = sprintf("INSERT INTO autenticacao (login, senha, nome, sobrenome) VALUES (%s, %s, %s, %s)",
GetSQLValueString($_POST['login'], "text"),
GetSQLValueString($_POST['senha'], "text"),
GetSQLValueString($_POST['nome'], "text"),
GetSQLValueString($_POST['sobrenome'], "text"));

mysql_select_db($database_DXP, $DXP);
$Result1 = mysql_query($insertSQL, $DXP) or die(mysql_error());

$insertGoTo = "/login/sucesso.php";
if (isset($_SERVER['QUERY_STRING'])) {
$insertGoTo .= (strpos($insertGoTo, '?')) ? "&" : "?";
$insertGoTo .= $_SERVER['QUERY_STRING'];
}
header(sprintf("Location: %s", $insertGoTo));
}
?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Untitled Document</title>
</head>

<body>
<form id="form1" name="form1" method="POST" action="<?php echo $editFormAction; ?>">
<table width="620" border="1">
<tr>
<td width="167">Nome</td>
<td width="437"><input name="nome" type="text" id="nome" /></td>
</tr>
<tr>
<td>Sobrenome</td>
<td><input name="sobrenome" type="text" id="sobrenome" /></td>
</tr>
<tr>
<td>Login</td>
<td><input name="login" type="text" id="login" /></td>
</tr>
<tr>
<td>senha</td>
<td><input name="senha" type="password" id="senha" /></td>
</tr>
<tr>
<td colspan="2"><input name="OK" type="submit" id="OK" value="Submit" /></td>
</tr>
</table>
<input type="hidden" name="MM_insert" value="form1">
</form>
</body>
</html>

O erro ke ele diz e nesta linha k diz : header(sprintf("Location: %s", $insertGoTo));
 
N sei...

O Firewall ja experimentei meter disable e dps arrancar da o erro e o dreamweaver penso k ta bem configurado...
 
Bug!

http://bugs.php.net/bug.php?id=25166

Tipo ja li o site e vi k se trata de um bug... mas n percebo komo conserta-lo... tipo eu tirei o lastes CVS substitui td da pasta php agr kd no xampp meto star no mysql akilo diz k n ecnotnra o modulo no XXX.dll e eu karrego ok aparece outra vez assim consecutivo a dizer ke n consegue carregar o modul de um dll... e deps tirei o ficheiro 5.1x stable e substitui mas da na mm kd karrego no star t no mysql um erro a carregar xxx.dll... isto porke eu penso k fiz alguma cosia mal...
plz help...
 
Ninguem me pdoe ajudar?

Ninguem me consegue ajudar nisto plz eu keria resolver isto antes das auals porke dps isto fika parado ... e perco o fio....
 
Hipop_Man se calhar aconselhava-te a reler melhor como configurar php mysql e phpmyadmin. Sei que as aplicações como o xampp trazem isso tudo e instalam com ajuda de uns cliks todos os pacotes necessários para programar... mas tens que ter algumas configuraçoes base! tens sp2? tas a trabalhar com iis? normalmente xampp dá conflito com o iis!!tens que ter atenção a isso e para-lo se for o caso!

de outro modo se tens a ligação à base de dados feita correctamente, e continua a dar erros aconselhote profundamente a reeinstalar todos os componentes!

como refere o estigma também é usual que a firewall bloqueia por vezes o dreamweaver! Fecha o dreamweaver e testa aplicação sempre que der erro!

a outra é realmente tb como estigma refere, também podes ter manage site mal configurado! Embora se tiveres a ligação à base de dados bem feita não seja o problema mais grave!!

cumpr.
ps: não há nada melhor do que instalar todos os componentes um a um!!existem muita documentação na web!
 
Back
Topo