0

This question will probably get shut down for being too broad...

At my last company, I built a standalone browser based application that allowed my to drag and drop to build emails. (this was before content builder). We used an event calendar module, and for that I popped up a form that allowed user input, then dynamically built the calendar and tagged everything for google Analytics.

I created this because of all of the tagging. I wanted tagging consistent, and I was also tired of manually building UTM strings. The application actually could create emails in Marketing Cloud as well. So the email would be built in this standalone browser based app, then you could hit a button and send it to SFMC.

(see example here http://www.riptide7.com/?work=1)

In any case, I'd like to build something like this again, but for my new company. I've been instructed that I cannot use an outside server for this, that if I want to build something like this, it would have to live in Cloud Pages.

So my question for you is about CloudPages and what is possible, and a brief explanation of how I might accomplish it. I'm not looking for you to post code, but perhaps walk me through the steps I might need to take to build it.

  1. Can I write PHP in CloudPages? I've used AMPScript, but for me PHP would be better
  2. Can I have popup boxes from a CloudPage? I assume that since you can link to JQuery, you can do anything you need to do in a CloudPage
  3. Can I pop up a modal box, allow user input, save that user input, wrap it up with some HTML code, and send it to content builder from CloudPages?

This last one is the part that has me particularly stumped. Using the PHP API I could send code to SFMC and create a new email. I'm not sure how to do that in CloudPages, not unless I can use the PHP API just like I would in a 3rd party server.

1 Answer 1

1

You'd be stuck writing AMPScript or SSJS to interact with the REST API in order to create Content Builder assets. It can be done, but it's a far cry from coding in PHP. SSJS and AMPScript are poorly documented, so expect it to take a while if you haven't built much in the platform.

  1. No, PHP won't work in CloudPages. The only server-side scripting that works is AMPScript and Server-Side JavaScript.
  2. Yes, you can use JQuery in CloudPages. Modals wouldn't be a problem.
  3. You should be able to add/update Content Builder assets in CloudPages, but it'd be a convoluted series of SFMC REST API calls.

Some things to keep in mind:

  • I'd expect the performance of these pages to not be so great -- especially with a bunch of traffic. You're at the mercy of the platform as-is.
  • There are no file paths or folders for Content Builder assets. Any resource will have to be uploaded and referenced by full URL in your code.
  • The filetypes that you can upload are restricted.
3
  • This is exactly what I was looking for. Thank you! Commented Jan 31, 2018 at 13:44
  • So for #3, you're saying I'd have to have some server based PHP code that does NOT live in SFMC and run that from an AMPScript call from my CloudPage? Commented Jan 31, 2018 at 13:45
  • 1
    No. You'd basically use AMPScript or SSJS to build REST API calls to interact with SFMC. Commented Jan 31, 2018 at 14:37

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .