[Koha-cvs] CVS: koha/opac opac-sendbasket.pl,1.4.2.3,1.4.2.4

Paul POULAIN tipaul at users.sourceforge.net
Mon Jun 6 17:47:30 CEST 2005


Update of /cvsroot/koha/koha/opac
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv19826/opac

Modified Files:
      Tag: rel_2_2
	opac-sendbasket.pl 
Log Message:
fix to send an iso2709 file as attachment

Index: opac-sendbasket.pl
===================================================================
RCS file: /cvsroot/koha/koha/opac/opac-sendbasket.pl,v
retrieving revision 1.4.2.3
retrieving revision 1.4.2.4
diff -C2 -r1.4.2.3 -r1.4.2.4
*** opac-sendbasket.pl	2 Jun 2005 13:03:31 -0000	1.4.2.3
--- opac-sendbasket.pl	6 Jun 2005 15:47:27 -0000	1.4.2.4
***************
*** 90,101 ****
  
  	my $boundary = "====" . time() . "====";
  	$mail{'content-type'} = "multipart/mixed; boundary=\"$boundary\"";
  
! 	$email_header = encode_qp($email_header);
  
! 	$boundary = "--".$boundary;
  
! 	# Writing mail
! 	$mail{body} = <<END_OF_BODY;
  $boundary
  Content-Type: text/plain; charset="iso-8859-1"
--- 90,131 ----
  
  	my $boundary = "====" . time() . "====";
+ # 	$mail{'content-type'} = "multipart/mixed; boundary=\"$boundary\"";
+ # 
+ # 	$email_header = encode_qp($email_header);
+ # 
+ # 	$boundary = "--".$boundary;
+ # 
+ # 	# Writing mail
+ # 	$mail{body} =
  	$mail{'content-type'} = "multipart/mixed; boundary=\"$boundary\"";
  
! 	my $message = encode_qp( "" );
  
! # $file = $^X; # This is the perl executable
! # 
! # open (F, $file) or die "Cannot read $file: $!";
! # binmode F; undef $/;
! $mail{body} = encode_base64($iso2709);
! # close F;
  
! $boundary = '--'.$boundary;
! $mail{body} = <<END_OF_BODY;
! $boundary
! Content-Type: text/plain; charset="iso-8859-1"
! Content-Transfer-Encoding: quoted-printable
! 
! $message
! $boundary
! Content-Type: application/octet-stream; name="basket"
! Content-Transfer-Encoding: base64
! Content-Disposition: attachment; filename="basket"
! 
! $mail{body}
! $boundary--
! END_OF_BODY
! 
! 
! 
! 	 <<END_OF_BODY;
  $boundary
  Content-Type: text/plain; charset="iso-8859-1"
***************
*** 109,113 ****
  END_OF_BODY
  
! $mail{PJ} = $iso2709;
  #	$mail{body} = <<END_OF_BODY;
  #$boundary
--- 139,143 ----
  END_OF_BODY
  
! $mail{attachment} = $iso2709;
  #	$mail{body} = <<END_OF_BODY;
  #$boundary
***************
*** 132,136 ****
  #		warn " ".$mail{body};
  #		warn " ".$mail{PJ};
- 		warn "Mail sent ok\n";
  		$template->param(SENT => "1");
  		$template->param(email_add => $email_add);
--- 162,165 ----





More information about the Koha-cvs mailing list