Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Email & XHTML

Status
Not open for further replies.

eyetry

Programmer
Oct 2, 2002
560
US
I've tried emailing an XHTML file a few diff ways.... no luck....

DSTX6.7 WinXP

XHTML output card set to
target = email
command =
-T -PROTO INET -SERVER email.server -user eyetry -pw 123xxx -from sender.email -to recipient.email -sub test

I also attempted to send the email witht he following rule:

=put("email"," -T -PROTO INET -SERVER email.server -user eyetry -pw 123xxx -from sender.email -to recipient.email -sub test ", package(xhtml:eek:utput:file))

=put("email"," -T -PROTO INET -raw -SERVER email.server -user eyetry -pw 123xxx -from sender.email -to recipient.email -sub test ", package(xhtml:eek:utput:file))

=put("email"," -T -PROTO INET -SERVER email.server -user eyetry -pw 123xxx -from sender.email -to recipient.email -sub test -att '" + substitute(getresourcename(xhtml:eek:utput:file), getdirectory(xhtml:eek:utput:file), "") + "'"
, package(xhtml:eek:utput:file))

Anyone know what I'm missing? Seems to work if the file is text with no XHTML.

XHTML doc looks something like....

<?xml version="1.1" encoding="utf-8"?>
<!DOCTYPE xhtml PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "
<html XMLNS="<body>
<head>
<title>
PAYER NAME
</title>
<style>
@MEDIA PRINT { DIV.PAGEBREAK {PAGE-BREAK-BEFORE: ALWAYS}}
</style>
</head>
<center><h1><GROUPNAME>INSURED GROUP NAME</GROUPNAME></h1></center><br>
<GROUPINFO><pre>
<B>FILE CREATED: </B><FILEDATE>06/08/2004</FILEDATE>
<B>FILE PROCESSED: </B><PROCESSDATE>06/08/2004</PROCESSDATE>
<B>GROUP NAME: </B>Wellmark
</pre>
</GROUPINFO>
<hr><hr><p>
<pre><SUBSCRIBER><h4><b>SUBSCRIBER COUNT</b><blockquote><SUBSCRIBERCNT>242</SUBSCRIBERCNT></blockquote>
</SUBSCRIBER></pre>
</p>
<p>
<pre><DEPENDENT><h4><b>DEPENDENT COUNT</b><blockquote><DEPENDENTCNT>187</DEPENDENTCNT></blockquote>
</DEPENDENT></pre>
</p>
<DIV CLASS="PAGEBREAK" ><hr></DIV>
<body>
</html>

I don't know anything about HTML, XML or XHTML so perhaps the problem is less the put cmd than the XHTML.

Eyetry
 
#1, what is in the trace file?
#2, What is the problem? E-mail not arriving at destination?
#3, Can you send the actual data via another e-mail program? (forget about PUT, make the card target file and use that as the data to put into your other e-mail).
#4, Tried to open the file as XML and it failed.



BocaBurger
<===========================||////////////////|0
The pen is mightier than the sword, but the sword hurts more!
 
It opens as htm/html.

It's an initial stab at an email report. It's formated poorly in this draft. In reality there will be more detail. I just wanted something to start with.

with 'raw' before 'subject and server the message is..

...Run Started at 07:02:28.405 on 03/30/06.
RAW specified with -subject.
Run Terminated at 07:02:28.421 on 03/30/06.

with it before 'proto' it is...

...Run Started at 07:02:28.405 on 03/30/06.
RAW specified with -attach.
Run Terminated at 07:02:28.421 on 03/30/06.


without raw but using '-att test.html' in stead of just '-att'

Run Started at 07:06:02.890 on 03/30/06.
Options used: trace,name,login,subject,attach,server,to,name,from,name,proto
Unrecognized protocol 'INET-SERVER' ignored; SMTP will be used.
SMTP Gateway 'pword' will be used.
Mercator e-mail Adapter, Version 6.7(306)
Copyright © 1997-2000, TSI International Software, DBA Mercator Software
Built for WIN32 - INTEL on Jun 25 2003 at 20:38:50 by bocabuild.
Retry Count is 0. Retry Interval is 0. OnFailure is Rollback.
Fetch Unit is 0. Card Mode is Integral.
Will process 913 bytes of data.
Run Started at 07:06:02.905 on 03/30/06.
GetMailCoreInfo: Successful.
Sockets Client ID 6 enabled.
Wrote 913 bytes to C:\DOCUME~1\eyetry\LOCALS~1\Temp\285.tmp.
Rollback specified; returning to map engine.
Wrote 0 bytes to C:\DOCUME~1\eyetry\LOCALS~1\Temp\286.tmp.
Filename 'test.html' will be used in the outbound message.
Originator is eyetry@email.com.
Originator 'eyetry@email.com' ignored (only one originator is allowed).
Recipient #1 is Utry@email.com.
Rollback specified; returning to map engine.
Cleanup call from prior Rollback; re-initializing instance storage.
Mercator map return is 0.
Wrote Header: Date: Thu, 30 Mar 2006 7:6:3 -0600 (CST)
Wrote Header: X-Mailer: Mercator e-mail Adapter 1.0.6
Local host is 'pc0000001'.
Client host is 'email.server'.
Server host is '123xxx'.
Couldn't locate host information.
WSAHostData: No host data available for 'HSD29559' (authoritative host not found).
Cannot deliver to any recipients.
WSASelect: One of the descriptor sets contains an entry which is not a socket (internal error).
WSASelect: One of the descriptor sets contains an entry which is not a socket (internal error).
WSACloseSocket: Invalid socket descriptor.
Sockets Client ID 6 disabled.


Under various conditions the log file states 'target not avail' or 'adapter failed to put data on output'

 
Ok, part of it is a DUH! 'Raw' is only for input. I'm was trying to use it for output.
 
Also: 'INET-SERVER' looks like a space is missing on command line.

BocaBurger
<===========================||////////////////|0
The pen is mightier than the sword, but the sword hurts more!
 
I was able to send the email with a text attachment but not with an xHTML attachment.

Had really wanted to use the XHTML file format because I can easily post the info the our intranet for internal user reference.

Think the help desk could figure out what's wrong?
 
Sure, send them a test case.



BocaBurger
<===========================||////////////////|0
The pen is mightier than the sword, but the sword hurts more!
 
I tested in 8.0.1, using blob in / out map and a file compiled from the data you posted. Was able to send both in line and as attachment.



BocaBurger
<===========================||////////////////|0
The pen is mightier than the sword, but the sword hurts more!
 
Tested in 6.7.1 on XP, same test. works OK.



BocaBurger
<===========================||////////////////|0
The pen is mightier than the sword, but the sword hurts more!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top