CRM-14696

Improve sold out display for price set options
CRM-14696 - Fix translate string
Clean up output buffers between tests.

Some of the tests I was running were erroring with a deprecation
warning. That was happening inside a Smarty template and the Smarty
stuff makes heavy use of ob_start and friends. When an error happens
inside an ob_start, the corresponding ob_end_clean isn't happening and
somewhere else in phpunit the output gets flushed. This causes the
output to get flushed to the screen which messes up the display of the
results of running phpunit.

This fix has us clear out all of the output buffers (if any) in the
tearDown for every test. That seems to fix this problem.
Fix the bug in CRM_Mailing_BAO_Mailing::add() where the DAO was being instantiated instead of the BAO, as later the create() method expects it to be BAO having getRecipients() method towards the end.
Fix returning to a smart group search after adding an activity.

The previous fix for this did not include the civicrm/group/search url
in the list of possible urls to return to; thus smart groups were still
broken for this workflow.

Signed-off-by: Toke Høiland-Jørgensen <toke@toke.dk>
CRM-15454 - Enable multiple WordPress plugins to receive callbacks from CiviCRM hooks
CRM-15431 - CRM_Core_I18n - Use CRM_Core_DAO::escapeString for typical, runtime escaping

The call from CRM_Core_I18n breaks on systems that use "mysqli" without
"mysql." Such systems cannot be fully supported for development using
current dataflows (i.e.  "GenCode" won't work), but this patch may make them
usable for regular installations.
batch entry for pledges
spacing issues
line and spacing issues
Log fatal errors for AJAX responses. CRM-15560

If you have a fatal error in an AJAX call, then the error doesn't get
logged to ConfigAndLog/Civicrm.*.log. This is because the logging stuff
happens after the call to CRM_Core_Page_AJAX::returnJsonResponse in
CRM_Core_Error::fatal and returnJsonRespons exits php.
CRM-15585 - Call pre hooks from api.setvalue
Add hook_civicrm_preProcess function.

This seems to be a generically useful spot to intercept the form object and
change things before the form is processed. Specifically, we need this hook
for integrating the Event Cart with the CiviDiscount extension.
Add a new findById DAO method.

We have found it very useful to have this simple function, which retrieves a
DAO object of a specific type by ID or throws an exception if one is not
found.

This can be called by using something like
CRM_Contribute_BAO_Contribution::findById(35), which will retrieve a
Contribution Object for that id, if it exists.
Porting over of this patch from another Civi instance failed miserably.

This commit includes the full preProcess hook definition and fixes the syntax
error.
Add unit test for CRM_Core_DAO::findById().
Update the hook invoke method to follow the CiviCRM 4.5 conventions for
invoke.
CRM-15595 - Individual sub-type custom fields don't appear in online event registration

https://issues.civicrm.org/jira/browse/CRM-15595
CRM-15611: fix send copy for case activity
Merge pull request #4576 from yashodha/CRM-15611

Tested, works fine