- Create Newsletter Page: MailingList (without the class style, using Gulp tasks)#94

This commit is contained in:
Paolo Arena
2019-11-21 00:18:40 +01:00
parent 20a3120054
commit f7fa0c4909
54 changed files with 675 additions and 51 deletions

View File

@@ -0,0 +1,141 @@
-function prettyDate(dateString){
//if it's already a date object and not a string you don't need this line:
-var date = new Date(dateString);
-var d = date.getDate();
-var monthNames = [ "Gen", "Feb", "Mar", "Apr", "Mag", "Giu", "Lug", "Ago", "Set", "Ott", "Nov", "Dic" ];
-var m = monthNames[date.getMonth()];
-var y = date.getFullYear();
-return d+' '+m+' '+y;
-}
- var urlweb = 'http://www.prova.it'
- var urlevent = 'http://www.evento.it'
- var urlunsibscribe = ''
- var urltwitter = ''
- var urlfb = ''
- var imgtwitter = 'https://associazioneshen.it/statics/images/logo.png'
- var imgfb = 'https://associazioneshen.it/statics/images/logo.png'
- var baseurl = 'https://associazioneshen.it/'
- var baseimg = baseurl + 'statics/'
doctype html
html
head
title One | Email template!
//- import css/scss stylesheets
//- these file names will be replace by gulp with proper css file paths
link(rel="stylesheet", href="../sass/basic.scss")
link(rel="stylesheet", href="../sass/one/styles.scss")
//- embdedded css allowed, but not sass
style.
.red {
background-color: #E84C50;
}
.full-width {
width: 100%;
}
body(yahoofix)
span(id='body_style', style='display:block')
table(class="preheader", cellpadding="0", cellspacing="0", width="100%")
tr
td.preheaderContent
p Preloader
td.webversion
p non vedi le immagini? 
a(href=urlweb) Apri la pagina qui
table(class="topHeader", cellpadding="0", cellspacing="0", width="100%")
tr
td
table(cellpadding="0", cellspacing="0", width="300", align="center", summary="")
tr
td.logoContainer
a(href=urlweb, title='logo')
img.logo(src="https://associazioneshen.it/statics/images/logo.png")
table(cellpadding="0", cellspacing="0", width="640", align="center")
tr
td(class="whitespace", height="10")
p  
tr
td(class="emailContainer", valign="top")
each event in arrevents
- var urlevent = baseurl + 'event/' + event.typol + '/' + event._id
- var imgev = event.img_small
- var mydate = prettyDate(event.dateTimeStart)
unless (imgev)
- var imgev = event.img
table(cellpadding="0", cellspacing="0", width="100%", summary="", border="0", align="center")
tr
td(class="column sectionArticleImage", valign="top")
img(src=baseimg + imgev, alt="", width="150")
td(class="column", valign="top")
table(cellpadding="0", cellspacing="0", summary="", border="0")
tr
td(class="sectionContentTitle", valign="top")
p #{event.title}
tr
td(class="sectionContentSubTitle", valign="top")
p(style='color:blue;') #{mydate}
tr
td(class="sectionContent", valign="top")
p!= event.details
tr
td(class="buttonContainer")
table(width="50%", cellpadding="0", cellspacing="0", summary="", border="0")
tr
td(class="button")
a(href=urlevent, title='Evento') Apri l'Evento
tr
td(class="whitespace", height="20")
p  
tr
td(class="whitespace", height="20")
p  
// Social Media
table.socialMedia(cellpadding="0", cellspacing="0", width="100%", summary="", border="0", align="center")
tr
td(class="whitespace", height="20")
p  
tr
td
table(width="120", cellpadding="0", cellspacing="0", summary="", border="0", align="center")
tr
td(width="32", align="center")
a(href=urltwitter, title='Twitter')
img(src=imgtwitter, alt="Twitter", width="29")
td(width="32", align="center")
a(href=urlfb, title='Facebook')
img(src=imgfb, alt="Facebook", width="29")
tr
td(class="whitespace", height="20")
p  
// Footer
table.footer(cellpadding="0", cellspacing="0", width="100%", summary="", border="0", align="center")
tr
td(class="whitespace", height="10")
p  
tr
td.whitespace
table(width="50%", cellpadding="0", cellspacing="0", summary="", border="0")
tr
td(class="footNotes", align="center")
a(href=urlunsibscribe, title='Disiscriviti') Disiscriviti
td(class="footNotes", align="center")
a(href="#", title='Lorem') Lorem
td(class="footNotes", align="center")
a(href="#", title='Dolor') Lorem
tr
td(class="whitespace", height="10")
p  

View File

@@ -0,0 +1 @@
=`Newsletter `

View File

@@ -0,0 +1,27 @@
doctype html
html
head
title One | Email template!
//- import css/scss stylesheets
//- these file names will be replace by gulp with proper css file paths
link(rel="stylesheet", href="../../sass/basic.scss")
link(rel="stylesheet", href="../../sass/one/styles.scss")
//- embdedded css allowed, but not sass
style.
.red{
background-color: #E84C50;
}
.full-width{
width: 100%;
}
body
table.table(cellpadding="0", cellspacing="0")
tr
td.red
h3(style="color: white;") Gulp & Pug is awesome
tr
td
a(href="/")
img.full-width(src="https://media.giphy.com/media/6o9Q2WehOHWI1QGO08/giphy.gif")