Visualizzazione dei risultati da 1 a 3 su 3

Discussione: header non va

  1. #1
    Utente di HTML.it
    Registrato dal
    Nov 2006
    Messaggi
    656

    header non va

    mi dite perche la funzione header non va?? rimane la pagina bianca
    Codice PHP:
     ?><?php
    # FileName="Connection_php_mysql.htm"
    # Type="MYSQL"
    # HTTP="true"
    $hostname_utenti "localhost";
    $database_utenti "xxxxi";
    $username_utenti "xxxx";
    $password_utenti "xxxxxx";
    $utenti mysql_pconnect($hostname_utenti$username_utenti$password_utenti) or trigger_error(mysql_error(),E_USER_ERROR); 
    ?>

    <?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;
    }
    }

    $colname_Recordset1 "-1";
    if (isset(
    $_GET['username'])) {
      
    $colname_Recordset1 $_GET['username'];
    }
    mysql_select_db($database_utenti$utenti);
    $query_Recordset1 sprintf("SELECT id, email FROM member WHERE username = %s"GetSQLValueString($colname_Recordset1"text"));
    $Recordset1 mysql_query($query_Recordset1$utenti) or die(mysql_error());
    $row_Recordset1 mysql_fetch_assoc($Recordset1);
    $totalRows_Recordset1 mysql_num_rows($Recordset1);

    $oggi date("j F Y G:i");
    $sito "http://www.tuosito.xx";
    $ip "$_SERVER[REMOTE_ADDR]";
    $browser "$_SERVER[HTTP_USER_AGENT]";
    $to "$row_Recordset1[email]";
    $soggetto "xxxx";



    $body "Richiesta di reset  password avvenuta il $oggi da indirizzo ip $ip dal sito xxxxx  \n\n";
    $body .= "\n\nATTENZIONE: Clicca sul link qui sotto per resettare  la tua password e registrarne una nuova.\n\nVai su [url]http://xxxxx/reset-password.php?id=[/url]$row_Recordset1[id]   ";


        
     
    mail("$to","$soggetto","$body""From: xxx<xxxxx>");



    mysql_free_result($Recordset1);





    header ("Location: [url]http://xxxxx/rescue-password-ok.php[/url]");

    ?>

  2. #2
    non ho letto tutto il codice ma per quanto riguarda l'header io proverei riscrivendolo così:

    header ("Location: http://xxxxx/rescue-password-ok.php");
    Forex: forum dedicato al mercato del trading forex

  3. #3
    Utente di HTML.it
    Registrato dal
    Jul 2006
    Messaggi
    24
    Scusate..... io ho più o meno lo stesso problema....

    Con la sola differenza che io devo aprire il link che si trova in una variabile chiamata "$link"


    $link = "http://xxxxx/rescue-password-ok.php";
    header ("Location: ***?????*** ");



    cm diventa poi il codice?!? ho provato, ma nn riesco....



    Grazie mille anticipatamente....

Permessi di invio

  • Non puoi inserire discussioni
  • Non puoi inserire repliche
  • Non puoi inserire allegati
  • Non puoi modificare i tuoi messaggi
  •  
Powered by vBulletin® Version 4.2.1
Copyright © 2025 vBulletin Solutions, Inc. All rights reserved.