-
-
Save cedricziel/6342199 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Create a Hidden Form Field named recipient | |
Define Recipient Email as: {f:cObject(typoscriptObjectPath:'lib.receiveremail')} | |
Define Recipient Name as: {f:cObject(typoscriptObjectPath:'lib.receivername')} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
plugin.tx_clocations { | |
settings { | |
# cat=plugin.tx_clocations//a; type=string; label=Contact Form PID | |
contactFormPid = | |
# cat=plugin.tx_clocations//a; type=string; label=Contact Form Reciever Field ID | |
contactFormReceiverFid = | |
} | |
} | |
temp.contactFormReceiver = GP:tx_powermail_pi1|field|{$plugin.tx_clocations.settings.contactFormReceiverFid} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[globalVar = TSFE:id = {$plugin.tx_clocations.settings.contactFormPid}] | |
page.config.no_cache = 1 | |
[globalVar = {$temp.contactFormReceiver} != 0] | |
lib.receivername = CONTENT | |
lib.receivername { | |
table = tx_clocations_domain_model_contact | |
select.selectFields = fullname | |
select.pidInList={$plugin.tx_clocations.persistence.storagePid} | |
select.where.data = GP:tx_powermail_pi1|field|{$plugin.tx_clocations.settings.contactFormReceiverFid} | |
select.where.wrap = deleted=0 AND hidden=0 AND uid=| | |
select.where.intval = 1 | |
renderObj = TEXT | |
renderObj.field = fullname | |
} | |
lib.receiveremail = CONTENT | |
lib.receiveremail { | |
table = tx_clocations_domain_model_contact | |
select.selectFields = email | |
select.pidInList={$plugin.tx_clocations.persistence.storagePid} | |
select.where.data = GP:tx_powermail_pi1|field|{$plugin.tx_clocations.settings.contactFormReceiverFid} | |
select.where.wrap = deleted=0 AND hidden=0 AND uid=| | |
select.where.intval = 1 | |
renderObj = TEXT | |
renderObj.field = email | |
} | |
[else] | |
lib.receiveremail = TEXT | |
lib.receiveremail.value = [email protected] | |
lib.receivername = TEXT | |
lib.receivername.value = Codearts | |
[global] | |
[global] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment