Tutorial for plugin ?
54 posts by 11 authors in: Forums > CMS Builder: Plugins & Add-ons
Last Post: November 30, 2011 (RSS)
By Djulia - April 10, 2010
You can check if the email of the administrator is correct in CMSB ( General Settings > Email Settings) ?
You can also check that the function mail works correctly ?
http://www.php.net/manual/en/function.mail.php
Djulia
Re: [Djulia] Tutorial for plugin ?
Thanks for your help
Mike
www.graphiclingoes.com
Re: [GraphicLingoes] Tutorial for plugin ?
By Djulia - September 8, 2010
It is not preferable to create your function with (in) the Membership plugin ?
If not, you can detail your approach ?
Thanks,
Djulia
Re: [Djulia] Tutorial for plugin ?
By GraphicLingoes - September 8, 2010 - edited: September 8, 2010
Hi [font "Verdana"]Mike,
It is not preferable to create your function with (in) the Membership plugin ?
Hi Djulia,
I'm not creating a function in the Membership Plugin, I have created my own plugin and uploaded it to the plugins folder and activated it. My question is, is there a function that I can call that will allow me to reproduce a confirmation alert such as the "Record saved." alert that shows at the top of the screen when a record is saved. I know what css class is being used to create the look and feel of the alert and I have been able to echo html code with the css class applied to a div to show my alert at the bottom of the screen, but I would rather show the alert at the top. Any ideas on how to do this, right now in my custom plugin I'm using applyFilter to "execute_econds" hook so html I echo shows in the footer.
Does this make sense?
Thanks
www.graphiclingoes.com
Re: [GraphicLingoes] Tutorial for plugin ?
www.graphiclingoes.com
Re: [GraphicLingoes] Tutorial for plugin ?
By Djulia - September 8, 2010 - edited: September 8, 2010
if (!$mailResult) { _displayNotificationType('attention', 'Mail Error:' .$php_errormsg);
else { _displayNotificationType('information', 'Send Email Ok');}
But, I do not know how to obtain positioning in top of the page.
I think that it is possible to use addFilter.
Perhaps what interactivetools can help us ?
Re: [Djulia] Tutorial for plugin ?
By GraphicLingoes - September 8, 2010 - edited: September 8, 2010
I came up with something very similar, but have also been stumped as to how to get it to show at the top of the screen. Logic would tell me that if I use the notice($message) approach that the displayAlertsAndNotices() function should know what to show, but my guess is the clearAlertsAndNotices() function is being called somewhere after I set the message with notice($message).
www.graphiclingoes.com
Re: [GraphicLingoes] Tutorial for plugin ?
addFilter('viewer_postinit', ena_setEmailSentNotice);
function ena_setEmailSentNotice() {
if(isset($_GET['_pluginAction']) && $_GET['_pluginAction'] == 'sendEmail') {
return notice('Email sent.');
}
This will not be the final code, but this is how I got the notice to show at the top of the page.
www.graphiclingoes.com
Re: [GraphicLingoes] Tutorial for plugin ?
By Djulia - September 8, 2010
Your plugin seems interesting ! It will be public ?
There is a filter for record_saved_message (?).
Djulia
Re: [Djulia] Tutorial for plugin ?
www.graphiclingoes.com