chuck: variablen_auswerten

Beitrag lesen

hi kalle danke ertsmal fuer einen hoffnungsschimmer,
habe ich folgendermassen gemacht:

hoffe der ausschnitt reicht

<?php
include ("../php/verbindung.php");
include ("../php/g1_sp1.php");
$theQuery= "SELECT * FROM chuck, e_gruppe1";
$result= mysql_query($theQuery, $db) or die ("unable to execute Query");
//echo $result;
//echo $theQuery;
echo $g1_sp1_f2."q";
function gruppe1 () {
      $theQuery= "SELECT * FROM chuck, e_gruppe1";
$result2= mysql_query($theQuery, $db) or die ("unable to execute Query");
    while($row = mysql_fetch_object($result2)) {
global $e_g1_sp1_f1;
global $g1_sp1_f1 ;
global $e_g1_sp1_f2;
global $g1_sp1_f2 ;

//$g1_sp1_f1 = 1; $g1_sp1_f2 = 3;  $e_g1_sp1_f1 = 2; $e_g1_sp1_f2 = 4;
if ($g1_sp1_f1 == $e_g1_sp1_f1 && $g1_sp1_f2 == $e_g1_sp1_f2) {
$punkte_g1_sp1 = 10; //ergebniss richtig
}
elseif ($g1_sp1_f1 - $g1_sp1_f2 == 0 && $e_g1_sp1_f1 - $e_g1_sp1_f2 == 0) {
$punkte_g1_sp1 = 6; //unentschieden
}