Some time ago I posted an article describing the manner in which one can send custom email messages via a logic hook. Since then, several folks have asked if it is possible to leverage the email template system built into SugarCRM for generating the actual message.
It is certainly possible and that is exactly what we will cover in this post.
To save ourselves some time, we will simply modify the script from the previous post and change the relevant portions so as to cause it to use an e-mail template instead of the file based template it previously used. But before that, we need to create the e-mail template.
Create your e-mail template as you would any other, following these steps:
1. Select Emails > Create Email Template within SugarCRM
2. Compose your message and click Save when done
Next, we need the ID of the email template you just created. This will allow us to leverage it within the script, giving us our desired result.
To retrieve the ID:
1. Select Emails > View Email Templates
2. Click on the email template you just created
3. Copy the content from the address field in your web browser to your clipboard
4. Paste the content to Notepad or other format where it can be easily inspected
Once pasted, you should find that the address field contains something similar to the following:
&record=9940c799-359b-f2fb-2943-4c619dfc696f
The portion to the right of the equal sign is what we will need.
With the preliminary work out of the way, we can proceed to modify the script that sends the message. If you want to see the original script, take a look at the original post.
Thursday, June 9, 2011
Thursday, May 19, 2011
SugarCRM 101: 10 Questions for Hosting Providers
![]() |
Photo by ivanpw/Flickr |
Due to the extensive amount of hosting providers that are available today, building and maintaining a comprehensive list of all those compatible for use with SugarCRM is a daunting and difficult task for any single individual such as myself. However, it is also not necessary to do so, as the answers to a few questions should suffice in determining the suitability of any provider.
Before you sign up, ask these questions:
1. Which version of PHP is installed?
An answer such as PHP 5 will not suffice. It needs to be exact, such as PHP 5.3.1. While there are many versions of PHP that are compatible with SugarCRM, there are also a number of them that are not. It is worth noting that many hosting providers have a tendency to use the latest versions of PHP. This is sometimes a problem for SugarCRM as said versions may not yet have thoroughly tested. One should not assume that SugarCRM will work because the server is using the latest release.
2. How often is PHP updated and can I revert to an older version if necessary?
One common problem SugarCRM users encounter on shared hosting providers is that the provider will at random update the version of PHP in use. That action unto itself is not a problem, except that sometimes the update is to a version of PHP that is not supported by SugarCRM. The ability to switch to a different version (one supported by SugarCRM) would be a helpful capability.
3. What is the memory limit for PHP?
This is one of the most important factors. Anything below 64MB is unusable for SugarCRM. If it is less than 128MB, you will only be able to run SugarCRM Community Edition. For this scenario, the higher the number, the better.
Friday, May 13, 2011
SugarCRM Troubleshooting: Formatting Woes
Does the image below look familiar?
It is the default login screen for SugarCRM Community Edition, but as one can see, the formatting is not quite right. This, unfortunately, is a common occurrence and worse yet, it usually occurs immediately following the install process.
Fortunately, the solution is rather simple. But before we get into the solution, let us spend just a couple of minutes reviewing the source of the problem so that we have a better understanding of the SugarCRM internals, which may come in handy at a later time.
Subscribe to:
Posts (Atom)