Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replacing template sections does not work #310

Open
Tsjippy opened this issue Apr 8, 2021 · 0 comments
Open

Replacing template sections does not work #310

Tsjippy opened this issue Apr 8, 2021 · 0 comments

Comments

@Tsjippy
Copy link

Tsjippy commented Apr 8, 2021

I have a custom html block in my template with some sample content:

<td class="defaultText" mc:edit="body">
<h2 class="title">Primary Heading</h2>
<p>Sample copy. Lorem ipsum dolor sit amet, consectetuer adipiscing elit.
Morbi commodo, ipsum sed pharetra gravida, orci magna rhoncus neque, id
pulvinar odio lorem non turpis.</p>
<h3 class="subTitle">Subheading</h3>
<p>Lorem ipsum dolor sit amet, consectetuer adipiscing elit.</p>
</td>

Then using the PHP library I try to replace this:

$response = $client->campaigns->setContent(
			$campain_id, 
			[
				"template"	=> [
					"sections"	=> [
						"body"			=> "<p>his is a test</p>",
					],
					"id"		=> $template_id
				],
			]
		);

But this does not work.

Am I right this only works for custom build premium templates?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant