Help for this page

Select Code to Download


  1. or download this
    use Encode;
    
    # ...  $buff holds a utf8 string:
    
    my $cp1250buff = encode( 'cp1250', $buff );
    
  2. or download this
    open( OUTPUT, ">output.txt" ) or die $!;
    binmode OUTPUT, ":encoding(cp1250)";
    
    #  ... or just use the 3-arg version of open:
    # open( OUTPUT, ">:encoding(cp1250)", "output.txt" )