Add to calendar button in the welcome email after registration - html

I implemented Add to Calendar dropdown button in a web page
<div class="dropdown" style="display: inline;">
<button target="_blank" class="btn btn-default dropdown-toggle" data-toggle="dropdown" style="border: 1px;border-radius: 2px;padding: 5px 10px;max-height: 30px; background-color: #004FBF;"><i class="material-icons" style="color: #FFFFFF">event</i> <span style="font-size: 12px;font-family: RobotoMedium;color:#FFFFFF;line-height:14px;letter-spacing:0px;border:1px;position: relative;top: -8px;">Add to Calendar</span></button>
<ul class="dropdown-menu" style="margin-top: 12px;">
<li style="padding: 5px;"><a target="_blank" href="http://www.google.com/calendar/event?action=TEMPLATE&text={{encode title}}&dates={{calendarFormat sessionStartTime}}/{{calendarFormat sessionEndTime}}&details={{calendarDetail _id}}&location={{location _id}}&trp=false&output=xml" ><i class="fa fa-google" style="color: #000000;padding: 5px;font-size: 18px;"></i><span style="font-size: 14px; font-family: RobotoRegular; color: #464646; letter-spacing: 0;height: 16px;width: 45px; line-height: 16px;">Google</span></a></li>
<li class="addToIcalendar" style="padding: 5px;" ><a target="_blank" href="/ics/{{getOrgId}}/{{getEventId}}/{{getSessionId}}" download><i class="fa fa-apple" style="color: #000000;padding:5px;font-size: 18px;"></i><span style="font-size: 14px; font-family: RobotoRegular; color: #464646; letter-spacing: 0;height: 16px;width: 45px; line-height: 16px;">Apple</span></a></li>
<li class="addToIcalendar" style="padding: 5px;"><a target="_blank" href="/ics/{{getOrgId}}/{{getEventId}}/{{getSessionId}}" ><img src="/images/outlook.png" height="19" width="19"><span style="font-size: 14px; font-family: RobotoRegular; color: #464646; letter-spacing: 0;
height: 16px;width: 45px; line-height: 16px;padding: 5px;">Outlook</span></a></li>
<li class="addToIcalendar" style="padding: 5px;"><a target="_blank" href="/ics/{{getOrgId}}/{{getEventId}}/{{getSessionId}}"><i class="fa fa-yahoo" style="color: #000000;padding:5px;font-size: 18px;"></i><span style="font-size: 14px; font-family: RobotoRegular; color: #464646; letter-spacing: 0;
height: 16px;width: 45px; line-height: 16px;">Yahoo</span></a></li>
</ul>
</div>
In a similar way, I want to create in Welcome email but it is not working as expected.
The output of the Add to Calendar in the email is
The dropdown items are by default displayed not after clicking the button. The icons are not displayed as expected
The same code in the email body is not working. Please help and thank you!

Dropdowns and really anything with a click event are very tricky to code in an email because you can't use JS, plus it may not work in all clients. My suggestion is to use something like AddEvent in particular their Direct URL method as the regular button will only work on a webpage not an email. Using the direct url method you can make a CTA in your email that will link out to a webpage created by AddEvent with info on the event and add to calendar links.

Dropdowns won't work in most emails, but there are several things you can do to explore.
First, you should attach the .ics file. Gmail for example pulls that out and makes it super easy to add to a person's calendar.
Second, you have a default button that goes to the .ics download. This will be so that people don't miss the attached .ics file, and make it clear what it is for.
Third, you may want to include direct calendar links for Gmail and Yahoo. These are specific URLs that will take a user to the webmail versions of their email. This may not be suitable from mobiles - you'll need to test the experience. But seeing as Gmail makes it really easy and visible when you attach the ics file, there's no real reason to muck around with that.
Litmus have a write up on the specific code for that (it's complicated), and some URL generation tools. https://litmus.com/blog/how-to-create-an-add-to-calendar-link-for-your-emails, Gmail: http://kalinka.tardate.com/, ICS generation: https://apps.marudot.com/ical/.

Related

How to retain HTML formatting in GitHub readme file upon upload?

So i formatted the README.md file of a particular GitHub project using HTML as I found markdown to be quite limiting. Maybe I am not quite well versed with markdown or I prefer HTML, I am not sure. So the issue is, I have the README.md file on my local system and when I display it on browser using a Markdown plugin from Sublime Text, it shows up exactly as I want. But when I push the local README.md file to the server and try to view it in website, the formatting is lost completely.
Local formatting -
GitHub website view -
As you can see, the two files are totally different. How can I preserve the formatting once it is uploaded on the GitHub server ?
The following is the spaghetti HTML code. It is very ugly. I was in a hurry and so ended up with such ugly code violating every aspect of DRY. Please excuse that for now.
<div class="header" style="width: 100%; display: flex;">
<div style="font-size: 50px; font-family: arial; width: 50%;"> Blind Reader</div>
<div style="width: 50%; text-align: right; display: table; ">
<span style=" letter-spacing: 5px; padding-left: 150px; font-family: verdana; font-size: 11px; display: table-cell;vertical-align: middle ; width: 20px;"> Developers </span>
<img src="images/dev1.png" style="height: 60px; width: 60px;">
<img src="images/dev2.png" style="height: 60px; width: 60px;">
</div>
</div>
<div class="badges-container">
<div class="badges-body">
[![Ask Me Anything !](https://img.shields.io/badge/Ask%20me-anything-1abc9c.svg?longCache=true&style=plastic)](https://GitHub.com/Naereen/ama) [![made-with-python](https://img.shields.io/badge/Made%20with-Python-blue.svg?longCache=true&style=plastic)](https://www.python.org/) [![GitHub license](https://img.shields.io/github/license/Naereen/StrapDown.js.svg?longCache=true&style=plastic)](https://github.com/Naereen/StrapDown.js/blob/master/LICENSE) ![PyPI - Status](https://img.shields.io/pypi/status/Django.svg?style=plastic) ![Contributor](https://img.shields.io/badge/Contributors-2-orange.svg?longCache=true&style=plastic)
</div>
</div>
<div class="body-content">
<span style="font-size: 25px; font-family: verdana; color: #64686d;"> Welcome to the <span style="color: #18529b;">Blind Reader</span> project !</span>
<br>
<br>
<div style="font-size: 18px; font-family: verdana; text-align: justify;" class="introduction">Blind Reader is a portable, low-cost, reading device made for the blind people. The Braille machines are expensive and as a result are not accessible to many. <strong>Blind Reader </strong>overcomes the limitation of conventional Braille machine by making it affordable for the common masses. The system uses OCR technology to convert images into text and reads out the text by using Text-to-Speech conversion.The system supports audio output via Speakers as well as headphone. The user also has the ability to pause the audio output whenever he desires. It also has the facility to store the images in their respective book folder, thereby creating digital backup simultaneously. With this system, the blind user does not require the complexity of Braille machine to read a book. All it takes is a button to control the entire system !
</div>
<div class="dependency" style="font-family: verdana; font-size: 18px; padding-top: 30px;">
<span style="font-size: 30px; font-family: verdana; font-weight: 500;">Dependency</span>
<div style="background:#757a79;height: 1.2px; width: 100%"></div><br>
<span style="font-size: 18px; font-family: verdana; font-weight: 600;">Hardware Requirements:</span><br>
<ul>
<li>Raspberry Pi 3B.</li>
<li>Pi Camera.</li>
<li>Speakers / Headphones.</li>
<li>Push buttons - 2.</li>
<li>LDR - 1.</li>
<li>LED - 4.</li>
<li>Power supply - 5V,2A.</li>
</ul>
<span style="font-size: 18px; font-family: verdana; font-weight: 600;">Software Requirements:</span><br>
<ul>
<li>Python 3.</li>
<li>Python Dependencies:</li>
<ul>
<li>Rpi.GPIO</li>
<li>Pygame library.</li>
<li>picamera library.</li>
<li>google-cloud.</li>
<li>time.</li>
<li>os.</li>
<li>datetime.</li>
</ul>
<li>Google Cloud API - Vision , Text-to-Speech</li>
</ul>
</div>
<div class="code" style="font-family: verdana; font-size: 18px; padding-top: 30px;">
<span style="font-size: 30px; font-family: verdana; font-weight: 500;">Usage</span>
<div style="background:#757a79;height: 1.2px; width: 100%"></div><br>
</div>
<div class="usage-content" style="font-size: 18px; font-family: verdana; text-align: justify;">
<ul>
<li>
Use the following code to install the Google cloud python dependency.<br><br><code>pip3 install --upgrade google-api-python-client<br>pip3 install --upgrade google-cloud-vision<br>pip3 install --upgrade google-cloud
</code><br><br>
Use : Google CLoud Vision API for further Details.<br><br>
</li>
<li> Activate <strong>Cloud Vision API</strong> and <strong>Google Cloud Text-to-Speech API</strong> by visiting the dashboard and download the Service account credentials (Json file).</li>
<br>
<li>
Connect the hardware as follows:
<ul>
<li>
Pi Camera --> Camera Slot in Raspberry Pi 3.
</li>
<li>
Pair Bluetooth Speaker / Insert headphone into Raspberry Pi 3 audio jack.
</li>
<li>
LDR --> GPIO 37.
</li>
<li>
4 LEDs - GPIO 29 , 31 , 33 , 35 respectively.
</li>
<li>
Push Button 1 ( Camera capture ) --> GPIO 16.
</li>
<li>
Push Button 2 ( Play/Pause audio ) --> GPIO 18.
</li>
</ul>
<br>
<li>
Use the following code to start the system:
<br>
<code>
python3 //path/to/your/final.py/file
</code>
</li>
<br>
<li>
Place the image to be read under the camera and press <code> Button 1 </code> to read out a page.
</li>
</ul>
</div>
<div class="system-images" style="font-family: verdana; font-size: 18px; padding-top: 30px;">
<span style="font-size: 30px; font-family: verdana; font-weight: 500;">Demonstration</span>
<div style="background:#757a79;height: 1.2px; width: 100%"></div>
</div>
<div class="image-cotainer" style="display: flex;">
<div class="image1" style="width: 50%"> <img src="images/system1.jpg" style="width: 80%;"></div>
<div class="image2" style="width: 50%"> <img src="images/system2.jpg" style=" width: 80%; height: 80%; padding-top: 40px;"></div>
</div>
<div class="resources-section" style="font-family: verdana; font-size: 18px;">
<span style="font-size: 30px; font-family: verdana; font-weight: 500;">Resources</span>
<div style="background:#757a79;height: 1.2px; width: 100%"></div>
</div>
<div class="resources-container" style="font-family: verdana; font-size: 18px;">
<ul><br>
<li>
Google Cloud Platform.
</li>
<li>
Pygame python library.
</li>
<li>
Raspberry Pi.
</li>
<li>
Python.
</li>
</ul>
</div>
</div>
I have also takena look at this link. It lists all the tags that are whitelisted by GitHub. And as I can see almost all the tags I have used are present here.
Please help.
GitHub documents there markup filtering in the github/markup repo:
This library converts the raw markup to HTML. See the list of supported markup formats below.
The HTML is sanitized, aggressively removing things that could harm you and your kin—such as script tags, inline-styles, and class or
id attributes. See the sanitization
filter
for the full whitelist.
Syntax highlighting is performed on code blocks. See github/linguist
for more information about syntax highlighting.
The HTML is passed through other filters in the html-pipeline that add special
sauce, such as
emoji,
task
lists,
named
anchors,
CDN caching for
images,
and
autolinking.
The resulting HTML is rendered on GitHub.com.
Note that step 1 is were the Markdown processing happens and that most likely returns the results you expect. The problem starts with step 2. Github takes the HTML returned in step 1 and sanitizes it extensively. This sanitation happens regardless of whether the source was Markdown, rst, texttile, asciidoc, or any number of other source formats.In other words, these filters have no direct relation to Markdown. So your Markdown is probably fine.
Given the extensive sanitation filters, any benefits of using Markdown's raw HTML fallback are almost completely lost. Generally, I stick to plain Markdown in any document I expect to be rendered by GitHub as most anything that gets stripped by the filters would not be possible with plain Markdown anyway.
If you really want to find some workarounds, then you will need to study the sanitation filter yourself to see if there is any way to get what you want. I expect most of what you want will not be possible though.

HTML Email and Google Maps

I'm creating an html email. On Outlook and GMail, the email format is correct. But with Google Inbox the formatting gets messed up. When I inspect the email in Inbox it shows that google adding extra code for google maps. Ive done the research on possible solutions but none seems to work. Here are two samples of what I've done from the research. I replace #ADDRESS1 with the users address before sending out the email.
<td style="width: 45%;">
<span class="" style="color: #000; font-size: 12px; font-family: 'Helvetica Neue',Helvetica,Arial,sans-serif;">
<a rel="nofollow" href="#" style="text-decoration:none; color: #000; border: none;"> #ADDRESS1</a>
</span>
</td>
<td style="width: 45%;">
<span rel="nofollow" class="" style="color: #000; font-size: 12px; font-family: 'Helvetica Neue',Helvetica,Arial,sans-serif; text-decoration:none;">
#ADDRESS1
</span>
</td>
When I inspect the email. This is what is added to the code:
<td style="width:45%">
<span style="color:#000;font-size:12px;font-family:'Helvetica Neue',Helvetica,Arial,sans-serif">
<a rel="nofollow" href="#m_-3542100051568633109_" style="text-decoration:none;color:#000;border:none"> 43478 GOLDEN MEADOW CIRCLE</a><a href="https://maps.google.com/?q=43478+GOLDEN+MEADOW+CIRCLE+%0D%0A%09%09%09%09%09%09%09%09+%0D%0A%09%09%09%09%09%09%09+%0D%0A%09%09%09%09%09%09%09+%0D%0A%0D%0A%09%09%09%09%09%09%09+%0D%0A%0D%0A%09%09%09%09%09%09%09+%0D%0A%09%09%09%09%09%09%09%09+%0D%0A%09%09%09%09%09%09%09+%0D%0A%09%09%09%09%09%09+%0D%0A%0D%0A%0D%0A%09%09%09%09%09%09+%0D%0A%09%09%09%09%09%09%09+%0D%0A%0D%0A%09%09%09%09%09%09%09+%0D%0A%09%09%09%09%09%09%09%09+%0D%0A%09%09%09%09%09%09%09%09%09+ASHBURN+VA+20147&entry=gmail&source=g" data-saferedirecturl="https://www.google.com/url?q=https://maps.google.com/?q%3D43478%2BGOLDEN%2BMEADOW%2BCIRCLE%2B%250D%250A%2509%2509%2509%2509%2509%2509%2509%2509%2B%250D%250A%2509%2509%2509%2509%2509%2509%2509%2B%250D%250A%2509%2509%2509%2509%2509%2509%2509%2B%250D%250A%250D%250A%2509%2509%2509%2509%2509%2509%2509%2B%250D%250A%250D%250A%2509%2509%2509%2509%2509%2509%2509%2B%250D%250A%2509%2509%2509%2509%2509%2509%2509%2509%2B%250D%250A%2509%2509%2509%2509%2509%2509%2509%2B%250D%250A%2509%2509%2509%2509%2509%2509%2B%250D%250A%250D%250A%250D%250A%2509%2509%2509%2509%2509%2509%2B%250D%250A%2509%2509%2509%2509%2509%2509%2509%2B%250D%250A%250D%250A%2509%2509%2509%2509%2509%2509%2509%2B%250D%250A%2509%2509%2509%2509%2509%2509%2509%2509%2B%250D%250A%2509%2509%2509%2509%2509%2509%2509%2509%2509%2BASHBURN%2BVA%2B20147%26entry%3Dgmail%26source%3Dg&source=gmail&ust=1523385602990000&usg=AFQjCNHtFzuxkGzIBkMPomWrrIXWB_iz_w">
</a></span><a href="https://maps.google.com/?q=43478+GOLDEN+MEADOW+CIRCLE+%0D%0A%09%09%09%09%09%09%09%09+%0D%0A%09%09%09%09%09%09%09+%0D%0A%09%09%09%09%09%09%09+%0D%0A%0D%0A%09%09%09%09%09%09%09+%0D%0A%0D%0A%09%09%09%09%09%09%09+%0D%0A%09%09%09%09%09%09%09%09+%0D%0A%09%09%09%09%09%09%09+%0D%0A%09%09%09%09%09%09+%0D%0A%0D%0A%0D%0A%09%09%09%09%09%09+%0D%0A%09%09%09%09%09%09%09+%0D%0A%0D%0A%09%09%09%09%09%09%09+%0D%0A%09%09%09%09%09%09%09%09+%0D%0A%09%09%09%09%09%09%09%09%09+ASHBURN+VA+20147&entry=gmail&source=g" data-saferedirecturl="https://www.google.com/url?q=https://maps.google.com/?q%3D43478%2BGOLDEN%2BMEADOW%2BCIRCLE%2B%250D%250A%2509%2509%2509%2509%2509%2509%2509%2509%2B%250D%250A%2509%2509%2509%2509%2509%2509%2509%2B%250D%250A%2509%2509%2509%2509%2509%2509%2509%2B%250D%250A%250D%250A%2509%2509%2509%2509%2509%2509%2509%2B%250D%250A%250D%250A%2509%2509%2509%2509%2509%2509%2509%2B%250D%250A%2509%2509%2509%2509%2509%2509%2509%2509%2B%250D%250A%2509%2509%2509%2509%2509%2509%2509%2B%250D%250A%2509%2509%2509%2509%2509%2509%2B%250D%250A%250D%250A%250D%250A%2509%2509%2509%2509%2509%2509%2B%250D%250A%2509%2509%2509%2509%2509%2509%2509%2B%250D%250A%250D%250A%2509%2509%2509%2509%2509%2509%2509%2B%250D%250A%2509%2509%2509%2509%2509%2509%2509%2509%2B%250D%250A%2509%2509%2509%2509%2509%2509%2509%2509%2509%2BASHBURN%2BVA%2B20147%26entry%3Dgmail%26source%3Dg&source=gmail&ust=1523385602990000&usg=AFQjCNHtFzuxkGzIBkMPomWrrIXWB_iz_w">
</a></td>
Any suggestions would be appreciated
Update
Just to clear it up. I don't want Google to add map links to my addresses. Because Google is adding the maps, its messing up my formatting in Google Inbox. In fact I don't want any map information at all

How to add an html email signature to outlook 2010

I have created an email signature in HTML and would like to use it in Outlook 2010. However, there are few things I am getting stumped on.
Some preface info:
(I included my logo, and four social media icons with links in my signature. I just uploaded the images to dropbox and linked to them in my code)
My code opened fine and looked as it should it my browser, so I saved the code to the signatures folder. I went to compose a new message and tried inserting my signature, but no dice. Outlook recognizes that the signature exists in the signature folder, but when I click on it, it isn't included in the message.
I read here that Outlook needs 3 different files (in .htm, .txt and .rtf formats). in order for a signature to work. But I'm not convinced that this is the case. To test this theory, I went to htmlsig.com and created a signature. It was just a simple html document. I downloaded the signature and saved it to the signature folder. I then opened Outlook, created a new message, and was able to insert that signature just fine.
I opened up the signature folder to see what kinds of files were in there, and the only file in there was a single Chrome HTML document.
My question:
How can I add my html file to be used as an email signature?
In case you were curious, here is my source code: (Its a work in progress)
<!DOCTYPE html>
<html>
<body>
<p style="font-family: Helvetica, Arial, sans-serif; font-size: 10px; line-height: 12px; margin-bottom: 10px;">
<img src="https://dl.dropboxusercontent.com/s/ccjrncxekbz4k1p/Transparent%20logo.jpg?dl=0" alt="MidWest Quality Gloves" border="0" class="sig-logo" height="115" width="133">
</p>
<p class="social-list" style="font-size: 0px; line-height: 0; font-family: Helvetica, Arial, sans-serif;">
##facebook##
<a style="text-decoration: none; display: inline;" class="social signature_facebook-target sig-hide" href="https://www.facebook.com/MidwestGlove/">
<img width="33" style="margin-bottom:2px; border:none; display:inline;" height="33" data-filename="facebook.jpg" src="https://dl.dropboxusercontent.com/s/42pre6zyk40xa98/Facebook.jpg?dl=0" alt="Facebook">
</a>
<span style="white-space: nowrap; display: inline;" class="signature_facebook-sep social-sep">
</span>
##instagram##
<a style="text-decoration: none; display: inline;" class="social signature_instagram-target sig-hide" href="https://www.instagram.com/midwestglove/">
<img width="33" style="margin-bottom:2px; border:none; display:inline;" height="33" data-filename="instagram.jpg" src="https://dl.dropboxusercontent.com/s/dmrbysqop83moq8/instagram.jpg?dl=0" alt="Instagram">
</a>
<span style="white-space: nowrap; display: inline;" class="signature_instagram-sep social-sep">
</span>
##pinterest##
<a style="display: inline; text-decoration: none;" class="social signature_pinterest-target sig-hide" href="https://www.pinterest.com/mwglove/">
<img width="33" style="margin-bottom:2px; border:none; display:inline;" height="33" data-filename="pinterest.jpg" src="https://dl.dropboxusercontent.com/s/9ejjex9wzksbvy3/pinterest.jpg?dl=0" alt="Pinterest">
</a>
<span style="white-space: nowrap; display: inline;" class="signature_pinterest-sep social-sep">
</span>
##LinkedIn##
<a style="text-decoration: none; display: inline;" class="social signature_linkedin-target sig-hide" href="https://www.linkedin.com/company/midwest-quality-gloves-inc">
<img width="33" style="margin-bottom:2px; border:none; display:inline;" height="33" data-filename="linkedin.jpg" src="https://dl.dropboxusercontent.com/s/b6ceobojyt3zjle/linkedin.jpg?dl=0" alt="linkedin">
</a>
<span style="white-space: nowrap; display: inline;" class="signature_linkedin-sep social-sep">
</span>
</body>
</html>
Back in the time when i used outlook 2010 i remember that i had to go to the Signatures panel and create a new one with some text. Then went to:
C:\Users\MYNAME\AppData\Roaming\Microsoft\Signatures
Edited the .htm signature file that was created and replaced the content with my html code, saved and restarted outlook. Can't really explain for certain why and how.

links in buttons within html email doent redirect

The links in my email buttons don't redirect the user when they are clicked on, even a simple redirect as shown in the code snippet below has no effect when clicked.(tested in hotmail, gmail, yahoo mail so far). Any suggestions?
<p >
If you feel your email account has been compromised please take the appropriate steps to secure your account.<br />
Please click the button below so we can remove this registration request.<br />
<table cellspacing="10" cellpadding="0">
<tr>
<td align="center" width="240 " height="36" bgcolor="#0478db" style="margin-left:15px;-webkit-border-radius: 5px; -moz-border-radius: 5px; border-radius: 5px; color :ghostwhite !important; display: block;">
<a href="http:\\www.google.com" style="color: #ffffff; font-size:16px; font-weight: bold; font-family: Helvetica, Arial, sans-serif; text-decoration: none; line-height:40px; width:100%; display:inline-block">
Delete Registration Request
</a>
</td>
</tr>
</table>
</p>
When clicked on in gmail it takes me to a blank page; about:blank. In hotmail and Yahoo nothing happens
The url syntax you have used is wrong
Urls are supposed to be like http://www.google.com not like http:\\www.google.com
Try updating the URL as below
<p >
If you feel your email account has been compromised please take the appropriate steps to secure your account.<br />
Please click the button below so we can remove this registration request.<br />
<table cellspacing="10" cellpadding="0">
<tr>
<td align="center" width="240 " height="36" bgcolor="#0478db" style="margin-left:15px;-webkit-border-radius: 5px; -moz-border-radius: 5px; border-radius: 5px; color :ghostwhite !important; display: block;">
<a href="http://www.google.com" style="color: #ffffff; font-size:16px; font-weight: bold; font-family: Helvetica, Arial, sans-serif; text-decoration: none; line-height:40px; width:100%; display:inline-block">
Delete Registration Request
</a>
</td>
</tr>
</table>
</p>

Opening hyperlink with target=_blank loads link in source page as well

I have a contact page which has links with target=_blank and they are all opening in new tabs, but also loading in the source page.
Code below - I am stumped, any advice would be appreciated.
<p style="font-size: 1.2em; color: #000; margin-top: 50px;">Contact</p><p class="">+44 7942 062 664<br>info#trentmcminn.com</p><p class="">Follow Trent on Twitter<br>Follow Trent on Tumblr</p><a target="_blank" href="http://eepurl.com/w3sb9" style="line-height: 2;">Subscribe to the newsletter</a>
</div>
<p style="font-size: 14px; position: absolute; bottom: 50px; padding-left: 40px;">All images © Trent McMinn 2013<br></p>
EDIT Page this is occurring is here http://www.trentmcminn.com/dev/contact/
THanks