Pagina 2 di 2 primaprima 1 2
Visualizzazione dei risultati da 11 a 20 su 20
  1. #11
    Scusami ma è da poco che programmo in php e non me ne ero accorto anche se ti giuro lo sapevo eheheheheh!
    Cmq anche il codice che mi hai dato mi presenta un errore di parentesi. Ho pensato che fosse lo stesso errore di prima ma non è così, ho provato ad aggiungere ma non va lo stesso

    Ecco il codice e la parentesi incriminata:

    $query = mysql_query ( "SELECT id,data,nome,sviluppatore,genere,piattaf
    orma from elenco_games where ".$where_clausule ) ;

    while ( $row = mysql_fetch_array ( $query )
    {
    echo "<div class=\"boxcella\">";

    Parse error: parse error in c:\apache\htdocs\database\result.php on line 56

    Come mai questo errore?

  2. #12
    Aggiungendo la parentesi tonda però mi da quest'altro errore

    Warning: Supplied argument is not a valid MySQL result resource in c:\apache\htdocs\database\result.php on line 55

  3. #13
    Utente di HTML.it
    Registrato dal
    Mar 2002
    Messaggi
    38
    ARIDAJE!!

    La riga

    while ( $row = mysql_fetch_array ( $query )

    non ha la ) doppia chiusa!!!

    Devi scrivere

    while ( $row = mysql_fetch_array ( $query ) )


  4. #14
    L'ho fatto ma mi presenta quest'altro errore:
    Warning: Supplied argument is not a valid MySQL result resource in c:\apache\htdocs\database\result.php on line 55

    Questo è il codice che fin'ora ho scritto:

    Codice PHP:
    <? include("config.inc.php");
    if ( isset ( 
    $_POST['chiave'] ))
    {
        if ( 
    $where_clausule == '' )
        {
            
    $AND ' AND ';
        }

        
    $where_clausule .= $AND " nome='" $_POST['chiave'] . "' " ;
        
    $AND '';
    }
    if ( isset ( 
    $_POST['chiaveuno'] ))
    {
        if ( 
    $where_clausule == '' )
        {
            
    $AND ' AND ';
        }

        
    $where_clausule .= $AND " sviluppatore='" $_POST['chiaveuno'] . "' " ;
        
    $AND '';
    }
    if ( isset ( 
    $_POST['chiavedue'] ))
    {
        if ( 
    $where_clausule == '' )
        {
            
    $AND ' AND ';
        }

        
    $where_clausule .= $AND " piattaforma='" $_POST['chiavedue'] . "' " ;
        
    $AND '';
    }

    if ( 
    $where_clausule == '')
    {
        echo 
    'Non hai inserito alcun parametro da ricercare' ;
    }
    else
    {
        
    $query mysql_query "SELECT  id,data,nome,sviluppatore,genere,piattaf
    orma from elenco_games where "
    .$where_clausule ) ;

        while ( 
    $row mysql_fetch_array $query ))
        {

            echo 
    "<div class=\"boxcella\">"

            echo 
    "<div class=\"boxcellaimg\">";

            echo 
    "<img src=\"immagini/imglink/$row[nome].gif\"></div>";

            echo 
    "<a href=\"bhe.php?id=$row[id]\">$row[nome]</a>
    ;

            echo 
    "$row[sviluppatore]
    "
    ;

            echo 
    "$row[genere]
    "
    ;

            echo 
    "$row[piattaforma]
    "
    ;

            echo 
    date('j/n/y'$row[data]); 

            echo 
    "</div>";
        }
    }

     
    ?>

  5. #15
    ke linea è ?
    Chiamatemi sven se volete non ho voglia di fare una nuova email per una nuova registrazione xD
    Mac Future User , Ventilatore for PC Cooler user , - dry is coming -

  6. #16
    La linea è questa:

    Codice PHP:
    while ($row mysql_fetch_array($result)) 

  7. #17
    Qualcuno può darmi una mano?
    Per favore non riesco a capire dov'è l'errore!!

  8. #18
    Utente di HTML.it
    Registrato dal
    Jun 2002
    Messaggi
    795
    scusa, ma $result io non lo vedo... dovrebbe essere
    while ( $row = mysql_fetch_array ( $query ))
    visto che fai
    $query = mysql_query ( "SELECT id,data,nome,sviluppatore,genere,piattaf
    orma from elenco_games where ".$where_clausule ) ;
    <sfogo> ma porco giuda, leggerlo l'help online ogni tanto! </sfogo>

  9. #19
    Non ho ben capito quello che dici puoi farmi un esempio di codice? grazie!

  10. #20
    Aiutatemi ve ne prego!!!

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.