Kurt Tan writes:

« HTML content follows »

Please don't send HTML content to this mailing list.

Hi,

     After I set up SQWEBMAIL for my use, I found that it has no the
RECEIPT feature.

Yes, it does. See “/usr/local/share/sqwebmail/nodsn” in INSTALL.

This is not the same “return receipt” functionality you're talking about,
though.  You are referring to a non-standardized return receipt
functionality that's not universally supported.  Sqwebmail implements RFC
1891-based DSN's.  The catch is that the local mail server must implement
DSNs.  Qmail doesn't, so if you're running Qmail you can't use it.  All
other mainstream mail servers do, so removing
“/usr/local/share/sqwebmail/nodsn” will enable a “return receipt” function
on the compose message screen.

                 That is, I want the man receive my mail can auto-reply a
mail to inform me that he has receipt my mail and are reading it.

     I modified the newmsg_create.c, newmsg.c, folder.c to implement the
feature.Please see the attachment.

1) The code that sends the return receipt is ugly.

2) The code that sends the return receipt appears to be trivially hackable,
permitting shell access to your web server box.

     But one thing is, I want the user can be informed that the mail he is
reading required a receipt. That should be done when he open the receipt
required mail. I want to add such html code in the page opened:

     printf("The mail you're reading is required a receipt, click the
following button to send the receipt.<input type=\"submit\" name="send
receipt" value=\"SEND RECEIPT\"> );

 

     But I don't know where to add these code. In which file and which
function? Where? I guess it should be in folder.c and in the function
showmsgrfc822_body().But I'm not sure. And how to write the code when the
user click the SEND RECEIPT buttion? That is, where the SEND RECEIPT
button link to? Anyone can help? Any suggestion is appreciated!

You need to generate a URL that points back to the sqwebmail binary, and includes the parameters that identifies the folder, the message number, and a new function name. Then, you will have to write the code that receives and validates these arguments, opens the message file, and sends the reply.

This cannot be easily explained in a few sentences.  For an example how to
do that, look at how the “Reply” links are handled, and just base your code
off that.  What you want to do is very similar to the reply function, so you
can use that code as your guide.


Attachment: pgp00000.pgp
Description: PGP signature

Reply via email to