From owner-freebsd-questions@FreeBSD.ORG Sat Jul 14 22:21:19 2007 Return-Path: X-Original-To: questions@freebsd.org Delivered-To: freebsd-questions@FreeBSD.ORG Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 7974D16A49A for ; Sat, 14 Jul 2007 22:21:19 +0000 (UTC) (envelope-from mi+kde@aldan.algebra.com) Received: from aldan.algebra.com (aldan.algebra.com [216.254.65.224]) by mx1.freebsd.org (Postfix) with ESMTP id 2C85713C4B4 for ; Sat, 14 Jul 2007 22:21:19 +0000 (UTC) (envelope-from mi+kde@aldan.algebra.com) Received: from aldan.algebra.com (localhost [127.0.0.1]) by aldan.algebra.com (8.14.1/8.14.1) with ESMTP id l6EMLH6N055740 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Sat, 14 Jul 2007 18:21:17 -0400 (EDT) (envelope-from mi+kde@aldan.algebra.com) Received: from localhost (localhost [[UNIX: localhost]]) by aldan.algebra.com (8.14.1/8.14.1/Submit) id l6EMLHtZ055739; Sat, 14 Jul 2007 18:21:17 -0400 (EDT) (envelope-from mi+kde@aldan.algebra.com) From: Mikhail Teterin To: Derek Ragona Date: Sat, 14 Jul 2007 18:21:16 -0400 User-Agent: KMail/1.9.6 References: <200707141603.55899@aldan> <6.0.0.22.2.20070714155424.0242a958@mail.computinginnovations.com> In-Reply-To: <6.0.0.22.2.20070714155424.0242a958@mail.computinginnovations.com> X-Face: %UW#n0|w>ydeGt/b@1-.UFP=K^~-:0f#O:D7whJ5G_<5143Bb3kOIs9XpX+"V+~$adGP:J|SLieM31VIhqXeLBli" Cc: questions@freebsd.org Subject: Re: Can cron e-mail HTML? X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 14 Jul 2007 22:21:19 -0000 = To accomplish this I have my cron job run a script like this Sorry, I missed the most important part. Your script just uses /usr/bin/mail, the same way cron does. You are not adding anything, not already present in cron -- your script should simply produce output to stdout. Cron will mail all that to the address specified in MAILTO=... part of your crontab automatically. AFAIK, to make the e-mail message treated as a MIME one, the "MIME-Version: 1.0" and "Content-Type: ..." have to be among _headers_. I'm afraid, it is not possible to directly manipulate the message's headers using mail(1), which is why I asked my question in the first place... -mi