Escape term values by using QueryParser.escape.

Otherwise searches with reserved characters end up in parser errors.
Fix function docstring.
Fix typo in attribute name
Specify encoding.
Test for multiline contexts.
Fix msgctxt multiline test
Wrap long lines for improved readability.
Added docstring.
Be explicit about the merging criterion to use.

This adds support for a new custom header, 'X-Merge-On', that specifies
the type of matching that will be used when merging units. For now it
accepts two values ('location', 'id'), being 'id' the default when the
custom header is absent.

Prior to this, the 'X-Accelerator-Marker' was used doing wild guesses
about the matching criterion to use when merging. This has lead to
confusion and issues with PO files generated at LibreOffice for instance
(bug 2587), where the desired behavior was merging based on IDs
(combination of msgid and msgctxt) rather than on location, and this
resulted in lots of units being marked as fuzzy.
Remove unneeded line continuation.
Added missing commas.

Thanks ChrisOelmueller :)
Fix typo.
Fix reST markup and adapt grammar
Added support for php translation files which use the defines syntax. This fixes bug 2238

	modified:   translate/storage/php.py
Added support for saving the comment lines that start with // in a php translation file

	modified:   translate/storage/php.py
Add test for php simple definition with spaces before the end delimiter

	modified:   translate/storage/test_php.py
Added several tests for php translation files with define syntax in its miscellaneous flavors

	modified:   translate/storage/test_php.py
Added support for blank spaces before the end delimiter in php translation files. Includes changes in tests for checking that it works fine. Fixes bug 1898

	modified:   translate/storage/php.py
	modified:   translate/storage/test_php.py
Minor fix in php2po tests docstring

	modified:   translate/convert/test_php2po.py
Remove unused method.