view html attachment using macro

Andrzej Popielewicz <[email protected]>
Newsgroups gmane.mail.mutt.user
Message-ID <Zpp5Q/[email protected]>
As a comment to recent discussion about viewing html attachments.
For some time I have used pipe command and lynx to view html attachments.
I wanted to automate this trick and here is the result


macro index,attach <f5> '<view-attachments>/html<enter>| "/usr/bin/lynx0"<enter>' 'display html attachment'

macro index,attach <f6> '<view-attachments>/html<enter>| "/usr/bin/lynx1"<enter>' 'display html attachment'

# Below content of /usr/bin/lynx0
#!/bin/sh
/usr/local/281/bin/lynx -stdin -dump -force_html | less 

# Below content of /usr/bin/lynx1
#!/bin/sh
cat > i.html
/usr/local/281/bin/lynx i.html 

macros should be placed in /.muttrc of course.
Using F6 offers full access to html attachment.

HTH

-- 
Andrzej Popielewicz
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.