naja ist ja auch klar der erste parameter der funktion gen_nfo_pic ist ja auch der text, sorry dann so
PHP-Code:
if( !empty( $_FILES['nfo'] ) && $_FILES['nfo']['error'] < 4 &&
preg_match( '/(' . $allowdExtensions . ')/i', strrchr ( $_FILES['nfo']['name'], '.' ) ) ) {
$nfo = str_replace( "\x0d\x0d\x0a", "\x0d\x0a", file_get_contents( $_FILES['nfo']['tmp_name'] ) );
if ( gen_nfo_pic( $nfo, $GLOBALS['TORRENTNFO_DIR'] . '/nfo-' . $id . '.png' ) ) {
tr_status( 'ok' );
}
else {
tr_status( 'err' );
if ( file_exists( $GLOBALS['TORRENTNFO_DIR'] . '/nfo-' . $id . '.png' ) ) {
unlink( $GLOBALS['TORRENTNFO_DIR'] . '/nfo-' . $id . '.png' );
}
}
}
else {
tr_status( 'err' );
}