witam, mam skrypt:
<html>
<head>
<script>
function MultiSelector( list_target, max ){this.list_target = list_target;this.count = 0;this.id = 0;if( max ){this.max = max;} else {this.max = -1;};this.addElement = function( element ){if( element.tagName == 'INPUT' && element.type == 'file' ){element.name = 'file_' + this.id++;element.multi_selector = this;element.onchange = function(){var new_element = document.createElement( 'input' );new_element.type = 'file';this.parentNode.insertBefore( new_element, this );this.multi_selector.addElement( new_element );this.multi_selector.addListRow( this );this.style.position = 'absolute';this.style.left = '-1000px';};if( this.max != -1 && this.count >= this.max ){element.disabled = true;};this.count++;this.current_element = element;} el
se {alert( 'Error: brak pliku' );};};this.addListRow = function( element ){var new_row = document.createElement( 'div' );var new_row_button = document.createElement( 'input' );new_row_button.type = 'button';new_row_button.value = 'usun';new_row.element = element;new_row_button.onclick= function(){this.parentNode.element.parentNode.removeChild( this.parentNode.element );this.parentNode.parentNode.removeChild( this.parentNode );this.parentNode.element.multi_selector.count--;this.parentNode.element.multi_selector.current_element.disabled = false;return
false;};new_row.innerHTML = element.value;new_row.appendChild( new_row_button );this.list_target.appendChild( new_row );};};
</script>
</head>
<body>
<?
$adres = "mail@gmail.com";
$topic = "=?iso-8859-2?B?".base64_encode("WSRM Łódź: e-mail z załącznikiem")."?=";
$headers = "MIME-Version: 1.0r\n";
$headers .= "Content-Transfer-Encoding: 8bitr\n";
$headers .= "Content-Type: text/html; charset=iso-8859-2r\n";
$headers .= "From: mail@gmail.comr\n";
$tresc_plus = "Treść maila:<br /><strong>".$imie."<br />".$mail."<br />".$numer."<br />".$temat."</strong><br /><pre>".$wiadomosc."</pre>";
mail ($adres, $topic, $tresc_plus, $headers); ?>
<form name="formularz" enctype="multipart/form-data" action="" method = "post" />
Imię i nazwisko:<br />
<INPUT NAME="imie" TYPE="text" SIZE="25" value="" />
<br />
Kontakt (e-mail):<br />
<input name="mail" type="text" SIZE="25" value="" />
<br />
Kontakt (telefon):<br />
<INPUT NAME="numer" TYPE="text" MAXLENGTH="9" value="" />
<br />
Temat:<br />
<select name="temat">
<option>temat 1</option>
<option>temat 2</option>
</select>
<br />
Treść:<br />
<TEXTAREA NAME="wiadomosc" COLS="50" ROWS="9"></textarea>
<br />
<input id="my_file_element" type="file" name="file_1" />
<br />
<INPUT NAME="submit" TYPE="submit" VALUE="wyślij" />
</form>
<br />
Pliki:
<div id="files_list"></div>
<script>
var multi_selector = new MultiSelector( document.getElementById( 'files_list' ), 3 );
multi_selector.addElement( document.getElementById( 'my_file_element' ) );
</script>
</body>
</html>
proszę Was o podpowiedź dlaczego załączniki są pomijane?