Jump to content


DanielDesign

Member Since 10/05/2007
Offline Last Active 22/04/2014, 12:39
-----

Posts I've Made

In Topic: Problema: Css Influenciando No Php

22/04/2014, 12:40

Olá!

Você já tentou assim:


<?php
ob_start();
require("../conexao.php");
?>

<!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=utf-8" />
<title>Edita</title>
<style type="text/css">
        .alerta_verde{
                margin:20% auto;
                width:300px;
                height:auto;
                padding:10px;
                border:1px solid #060;
                background:#090;
                text-align:center; 
        }
        .alerta_verde h1{
                color:white;
                font-family:Verdana, Geneva, sans-serif;
                font-size:12px;
        }
        .alerta_vermelho{
                margin:20% auto;
                width:300px;
                height:auto;
                padding:10px;
                border:1px solid #900;
                background: #F00;
                text-align:center;
        }
        .alerta_vermelho h1{
                color:white;
                font-family:Verdana, Geneva, sans-serif;
                font-size:12px;
        }               
</style>
</head>

<?php
$id        = $_GET['id']; 
$servico   = $_POST['servico'];
$cliente   = $_POST['cliente'];
$data      = $_POST['data'];
$descricao = $_POST['descricao'];

$stringSQL = "UPDATE `walldivi_walldivi`.`portfolio` 
SET `servico` = '$servico', `cliente` = '$cliente', `data` = '$data', `descricao` = '$descricao' 
WHERE `portfolio`.`id` = $id;";   

$ativaQuery = mysql_query($stringSQL);
                
if ($ativaQuery) {
 echo "<div class='alerta_verde'>";
 echo "<h1>Portfolio alterado com sucesso.</h1>";
 echo '</div>';
} else {
 echo "<div class='alerta_vermelho'>";
 echo "<h1>Não foi possível alterar o portfolio, tente novamente.</h1>";
 echo '</div>';
 echo "<br />Dados sobre o erro:" . mysql_error();
}

?>

<body>
<script type="text/javascript">
        setTimeout('location.href="../../portfolio-admin.php";',2250);
        
</script>
</body>
</html>


Poste o erro pra gente ver!
Abraço!


o que você mudou ? só o ob_start?

IPB Skin By Virteq