Error when appending &firstname={leadfield=firstname|true} to email link

When I edit a link in an email to look like this:



Extract



for the purpose of populating form fields on a landing page when they visit the landing page via the email, I get the following error from the mautic:campaigns:trigger cron task (pagelink=2 is definitely correct as I can drag and drop it in the email from the sidebar):



======================================



Triggering events for campaign 1

Triggering first level events

1 total events(s) to be processed in batches of 100

0/1 [>---------------------------] 0%PHP Notice: Undefined index: {pagelink=2}&firstname={leadfield=firstname|true}&email={leadfield=email|true} in /var/www/mautic/app/bundles/PageBundle/EventListener/BuilderSubscriber.php on line 595



[DoctrineDBALDBALException]

An exception occurred while executing ‘INSERT INTO page_redirects (is_published, date_added, created_by, created_by_user, date_modified, modified_by, modified_by_user, checked_out, checked_out_by, checked_out_by_user, redirect_id, url, hits, unique_hits, email_id) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)’ with params [1, “2016-01-11 13:35:02”, null, null, null, null, null, null, null, null, “40dbd3b29463040b1569a626b”, null, 0, 0, 1]:

SQLSTATE[23000]: Integrity constraint violation: 1048 Column ‘url’ cannot be null



[PDOException]

SQLSTATE[23000]: Integrity constraint violation: 1048 Column ‘url’ cannot be null



mautic:campaigns:trigger [-i|–campaign-id[="…"]] [-l|–batch-limit[="…"]] [-m|–max-events[="…"]] [-f|–force]



Script in progress. Use -f or --force to force execution.

Script in progress. Use -f or --force to force execution.

Script in progress. Use -f or --force to force execution.

Script in progress. Use -f or --force to force execution.



==========



Any help please?

When I edit a link in an email to look like this:

Extract

for the purpose of populating form fields on a landing page when they visit the landing page via the email, I get the following error from the mautic:campaigns:trigger cron task (pagelink=2 is definitely correct as I can drag and drop it in the email from the sidebar):

======================================

Triggering events for campaign 1
Triggering first level events
1 total events(s) to be processed in batches of 100
0/1 [>---------------------------] 0%PHP Notice: Undefined index: {pagelink=2}&firstname={leadfield=firstname|true}&email={leadfield=email|true} in /var/www/mautic/app/bundles/PageBundle/EventListener/BuilderSubscriber.php on line 595

[DoctrineDBALDBALException]
An exception occurred while executing ‘INSERT INTO page_redirects (is_published, date_added, created_by, created_by_user, date_modified, modified_by, modified_by_user, checked_out, checked_out_by, checked_out_by_user, redirect_id, url, hits, unique_hits, email_id) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)’ with params [1, “2016-01-11 13:35:02”, null, null, null, null, null, null, null, null, “40dbd3b29463040b1569a626b”, null, 0, 0, 1]:
SQLSTATE[23000]: Integrity constraint violation: 1048 Column ‘url’ cannot be null

[PDOException]
SQLSTATE[23000]: Integrity constraint violation: 1048 Column ‘url’ cannot be null

mautic:campaigns:trigger [-i|–campaign-id[="…"]] [–scheduled-only] [–negative-only] [-l|–batch-limit[="…"]] [-m|–max-events[="…"]] [-f|–force]

Script in progress. Use -f or --force to force execution.
Script in progress. Use -f or --force to force execution.
Script in progress. Use -f or --force to force execution.
Script in progress. Use -f or --force to force execution.

==========

Any help please?

It seems this fix could solve your issue:

https://github.com/mautic/mautic/pull/1310

If you get a chance to test it, write a comment below the PR. I’ll speed up release of the new version.