Landing page What's possible with a custom landing page? | Community
Skip to main content
April 27, 2015
Question

Landing page What's possible with a custom landing page?

  • April 27, 2015
  • 3 replies
  • 1504 views
Hi Marketo Community,

I'm working on a first Marketo Landing Page Template, and I'm having a hard time with two things:

1. PHP statements
In other templates (e.g. imported from http://templates.marketo.com) I've seen PHP statements like: <?php echo $mContext['headElements']; ?> or <?php echo $mContext['bodyAttributes'] ?> etc. 
However, when I put them in my template it doesn't go through the validation process: http://inco.re/1z5Nnbk. When I click 'repair' it removes php statements, but I'm not sure if that's desired outcome.

What is the best practice here?
 
2. Editable content
So far I know to make content editable developers should use "mktEditable" class for a given html tag. However, it only allows to change look and style of that element. How do I make content (text) or link inside a given element editable? (e.g. http://inco.re/1bwuP9k).

Is it possible or drag and drop is the only option to change content of a page?

Any help greatly appreciated,
Thanks
This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.

3 replies

Level 10
May 4, 2015
Hi Tomasz

1. PHP statements: Marketo has this rule to not allow any other PHP tag to be placed in your Landing Page template. It already has two PHP statements as you've mentioned, but it wouldn't allow even an empty PHP tag in the Template edit section.

2. Editable content: Every element that contains the class: "mktEditable", becomes editable in the edit section of the Landing Page or email. In case of the image example that you've mentioned, just right click the H1#lpTitle element (as shown in the image) in the Template Elements panel and select "Edit". A new window will pop-up, where you can edit the Title of the Landing Page. You can do the same by double clicking the title area
May 4, 2015
Hi Alok,
I appreciete your answer.

1. PHP statements:
I'm not trying to put there any custom PHP code. 'Repair' button removes the whole PHP code, including Marketo tags like <?php echo $mContext['headElements']; ?>.

2. Editable content
Right click on "Tempalte Elements" doesn't show any context menu. Is there any other requirement to make a template element editable other than using "
mktEditable" class"?

Thanks,
Tomasz
Level 10
May 5, 2015
Hi

1. PHP statements:
After Jan'15 release, Marketo will not accept any custom PHP code for new responsive templates. But you will be able to repair old non-responsive templates. If you will use new code, the template will not function in the desired manner and it will break.

2. Editable content:
Using
"mktEditable" class, you can make an element editable (For an Email). For LPs "mktoContent" is used. nFor editing template elements, please refer the screenshot below