• Hello Fabrik Community

    Fabrik is now in the hands of the development team that brought you Fabrik for Joomla 4. We have recently transitioned the Fabrik site over to a new server and are busy trying to clean it up. We have upgraded the site to Joomla 4 and are running the latest version of Fabrik 4. We have also upgraded the Xenforo forum software to the latest version. Many of the widgets you might have been used to on the forum are no longer operational, many abandoned by the developers. We hope to bring back some of the important ones as we have time.

    Exciting times to be sure.

    The Fabrik 4.0 Official release is now available. In addition, the Fabrik codebase is now available in a public repository. See the notices about these in the announcements section

    We wish to shout out a very big Thank You to all of you who have made donations. They have really helped. But we can always use more...wink..wink..

    Also a big Thank You to those of you who have been assisting others in the forum. This takes a very big burden off of us as we work on bugs, the website and the future of Fabrik.

Form Email Plugin

Status
Not open for further replies.

stevelis

Member
Is it possible to insert the current date into the message text box of this plugin and have it formatted just for the year.
 
hi, the complete timestamp can be done with:
PHP:
{mysql_date}
Now how to limit it on just the year? Maybe someone else can give you a better answer.
 
thanks wuschel_lux
Yes the {MySQL_date} worked and displayed the full time stamp.
I had a few minutes to spare before work at the formatting (current year only, 2019) but none were successful so far.
Will keep trying and welcome any formatting suggestions.
Steve
 
Thanks for the suggestions but I am not sure whether this can be achieved in the Email Form Plugin, Options tab > Message Text box.
Note: the {mysql_date} placeholder does insert the full timestamp. Not sure what code will split the year from the timestamp in the message box.
Here is the part of text using the element placeholders and where I am trying to insert the 'year' part of the timestamp.

<div><span style="font-family: arial,helvetica,sans-serif; font-size: 12pt;"><strong>{calendar___Event}</strong> being conducted at<strong> {calendar___Location}</strong></span>
</div>
<div><span style="font-family: arial,helvetica,sans-serif; font-size: 12pt;">and commencing on the<strong> {calendar___StartDate} </strong>and finishing on the<strong> {calendar___enddate},
$date = '{mysql_date}'; $year = explode("-",$date) [0]; return $year; </strong></span>
</div>

Steve
 
Hi troester
I have manually added 2019 into the message for the time being whilst I work on a PHP template as you have suggested.
Steve
 
Status
Not open for further replies.
We are in need of some funding.
More details.

Thank you.

Members online

No members online now.
Back
Top