Code Snippets

Ampscript, SSJS (server-side JavaScript) & SQL code for you to use


  • HTML Table in Ampscript

    HTML Table in Ampscript

    Tabularize all the things! If you find yourself building internal tools like for non-SFMC users, you might need to display some data from SFMC in an table (either on a CloudPage or sent in an email to your team). Rather than reinvent the wheel each time the need arises, I decided to build a reusable…


  • Ampscript Countdown

    I wanted to include a countdown in my Ampscript Wordle clone which would display the remaining time in of the following ways: Seemingly simple this one piece of information required a lot more code than I expected at first as we need to: Note I’ll admit this normally should be done with client-side JavaScript displaying…