Skip navigation
All Places > New York User Group > Blog > 2017 > November

File under Things You Thought Already Worked.

For awhile, I too thought multiple Marketo forms on the same page worked as long as they had different form IDs (though I always knew there was a problem with 2 or more of the same form).

But no, even different forms don't really work. The only multi-form scenario that works out-of-the-box is different forms that have zero visible fields in common. Since Email Address is found on almost all forms, it's almost certain that multiple forms won't be fully functional without the fix below.

The problems with multiple forms all relate to the HTML ID attribute.



Read the full post on TEKNKL :: Blog →

    With an assist from Velocity, your emails can have time-responsive content.  (And I don't just mean Happy ${day_of_week}, ${first_name}!)

  • When the same email is resent with different primary content (e.g. a weekly newsletter) Velocity can customize secondary content based on the day: like reader PW, you can show a special promo only in the first send of the month, every month.
  • Like user GM, you can pre-create a series of different content blocks, in effect creating a drip campaign from just one asset.
  • If a triggered email is sent off-hours, you can notify the recipient that they'll hear from Sales on the next business day.
  • Or lots of other adventures!

    To run the snippets below, set common variables at the top of the script (or in a global script) like so:

#set( $defaultTimeZone = $date.getTimeZone().getTimeZone("America/New_York") )
#set( $defaultLocale = $date.getLocale() )
#set( $calNow = $date.getCalendar() )
#set( $ret = $calNow.setTimeZone($defaultTimeZone) )
#set( $calConst = $$calNow) )
#set( $ISO8601 = "yyyy-MM-dd'T'HH:mm:ss" )



Read the full post on TEKNKL :: Blog →

     Since version 1.6 (i.e. a long time ago) Java has had a built-in JavaScript engine. Called Rhino in Java 1.6-1.7 and replaced by Nashorn in 1.8, the JS engine has always been reliable (it’s the user-facing script language of numerous Java-based commercial apps) even if its function set and performance lags behind browsers’ JS engines.

This means if you have a ready-made JS snippet that does what you want, and you don't want to learn Velocity and/or translate your JS into native Java methods (hint: you eventually should learn how to tie Velocity in with raw Java, you'll be more productive for it) then you can sneak JS inside your Velocity token and get your cool email personalizations out the door.

You'll be running JavaScript, inside Velocity, inside Java, all inside Marketo: it's pretty darn cool, even if not something to lean on permanently.

Here's an example Velocity script which has JS do the heavy lifting…



Read the full post on TEKNKL :: Blog →