Salve a tutti,
sapreste aiutarmi ad inserire un campo testo <input type="text" name="textfield">
e ricevere il risulatato lato server in php?....questa è quanto sto usando...ma proprio non ci riesco:


Codice PHP:

<?php
    $append 
http_build_query(array(
    
session_name()    => session_id(),
    
'batch_id'        => substr(strtoupper(md5(rand(0999999999))), 25)
    ), 
null'&amp;');

?>

<!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>File Upload</title>
<link href="style.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="js/mootools-1.2-core-nc.js"></script>
<script type="text/javascript" src="js/Swiff.Uploader.js"></script>
<script type="text/javascript" src="js/Fx.ProgressBar.js"></script>
<script type="text/javascript" src="js/FancyUpload2.js"></script>
<script type="text/javascript">
/* <![CDATA[ */

window.addEvent('load', function() {
document.getElement('b').appendText(' Detected Flash ' + Browser.Plugins.Flash.version + '!');

    var swiffy = new FancyUpload2($('demo-status'), $('demo-list'), {
        debug: true,
        url: $('form-demo').action,
        fieldName: 'photoupload',
        path: 'js/Swiff.Uploader.swf',
        limitSize: 1150 * 1024 * 1024,
        target: 'demo-browse',
        onLoad: function() {
            $('demo-status').removeClass('hide');
            $('demo-fallback').destroy();
        }

    });
        $('demo-select-images').addEvent('change', function() {
        var filter = null;
        if (this.checked) {
            filter = {'Images (*.jpg, *.jpeg, *.gif, *.png)': '*.jpg; *.jpeg; *.gif; *.png'};
        }
        swiffy.options.typeFilter = filter;
    });
    $('demo-browse').addEvent('click', function() {
        swiffy.browse();
        return false;
    });


    $('demo-clear').addEvent('click', function() {
        swiffy.removeFile();
        return false;
    });

    $('demo-upload').addEvent('click', function() {
        swiffy.upload();
        return false;
    });

});


</script>


</head>
<body> 
<div align="center"> 
</div> 
<table width="500" border="0" align="center" cellpadding="0" cellspacing="0" bgcolor="#333333"> 
  <tr> 
    <td> <form action="script.php?<?= $append ?>" method="post" enctype="multipart/form-data" id="form-demo"> 
        <fieldset id="demo-fallback"> 
        <label for="demo-photoupload">
        <input type="file" name="photoupload" id="demo-photoupload" />
</label> 
        </fieldset> 
        <div id="demo-status" class="hide"> 
          <input type="checkbox" id="demo-select-images" /> 
          Solo immagini

          <table width="500" border="0" cellspacing="0" cellpadding="0"> 
            <tr> 
              <td width="195"><div id="demo-browse" class="scegli">[url="#"][img]images/load.gif[/img][/url]</div></td> 
              <td width="185"><div id="demo-clear" class="clear">[url="#"][img]images/cancella.gif[/img][/url]</div></td> 
              <td width="120"><div id="demo-upload" class="invia">[url="#"][img]images/go.gif[/img][/url]</div></td> 
            </tr> 
          </table> 
          
 
          <table width="500" border="0" cellpadding="0" cellspacing="0"> 
            <tr> 
              <td width="340"> <div> <strong class="overall-title">Dimensione Totale (0 kB)[/b]
 
                  [img]images/bar.gif[/img] </div> 
                </br> <div></div> 
                <div> <strong class="current-title">File:[/b]
 
                  [img]images/bar.gif[/img] </div></td> 
              <td> </td> 
            </tr> 
          </table> 
          
 
          <div class="current-text"></div> 
          
 
          <ul id="demo-list">[/list]
        </div> 
        
      </form></td> 
  </tr> 
</table>
</body>
</html>
questo lo script.php
Codice PHP:
session_name('SID');
session_start();

$batch_id date("d-m-Y") . "-[" trim($_GET['batch_id']) . "]" ;  

    
$result = array();
 
if (isset(
$_FILES['photoupload']) )
{
    
$file $_FILES['photoupload']['tmp_name'];
    
$error false;
    
$size false;
 
    if (!
is_uploaded_file($file) || ($_FILES['photoupload']['size'] > 100 1024 1024) )
    {
        
$error 'Superata dimensione massima per singolo File!';
    }
    else {

umask(0);
if(!
file_exists("./uploadedfiles/$batch_id")) mkdir("./uploadedfiles/$batch_id"0777);
$dir "./uploadedfiles/$batch_id"
move_uploaded_file($_FILES['photoupload']['tmp_name'], $dir ."/".$_FILES['photoupload']['name']);

    }
 
    
$addr gethostbyaddr($_SERVER['REMOTE_ADDR']);
 
    
$log fopen('script.log''a');
    
fputs($log, ($error 'FAILED' 'SUCCESS') . ' - ' $addr ' - ' $batch_id ": {$_FILES['photoupload']['name']} - {$_FILES['photoupload']['size']} byte\n" );
    
fclose($log);
 
    if (
$error)
    {
        
$result['result'] = 'failed';
        
$result['error'] = $error;
    }
    else
    {
        
$result['result'] = 'success';
        
$result['size'] = "File Caricato! - Ordine N.: " $batch_id ;

    }
 
}
else
{
    
$result['result'] = 'error';
    
$result['error'] = 'Errore Interno!!!';
}

 
if (!
headers_sent() )

grazie, saluti