Pass through correct parameter for user paging to work
Autocomplete email addresses on Forward page

Resolves [issues #28441]
Refactor Results.tsv to allow export of arbitrary collections to TSV
Move esacping closer to where it is relevant
Stop caring about word boundaries during ticket autocompletion

Rather than use \b to help split on what to search for, use a greedy
regex that matches as many space-separated ticket numbers as possible.
This solves problems with autocompleting "4.2.0", for instance.

Resolves issues #25755.
Abort if there is nothing to search for

It is now possible for $term to be empty -- for instance, when
autocompleting "1 2 3 ".  In such cases, don't search at all, merely
abort.
check both of "-Values" and "-Value" to find default values in ValidateCustomFields

in 4b21442, we refactored cf input name into a sub, which caused select cf
current values "not selected" when cloning a ticket. see also #29751.

turned out that we hardcoded "-Value" in the clone code before, which is not
consistent with the cf default name. 4b21442 reveals a potential bug that we
missed to check "-Values" in ValidateCustomFields.  this commit completes the
check(i.e. to check both "-Values" and "-Value"), like what we do for
$DECODED_ARGS in EditCustomField.
Prevent run-ons in fields with newlines

Replace newlines with spaces, to prevent content wrapped across lines
from running together when exported as TSV.
refactor "prevent double submission" js code to not disable submit buttons

if you are going back to a page which contains those disabled buttons, they
stay disabled and clicking them results nothing.  see also #27489

this commit makes sure the forms in page(even if you are going back to it)
could be submitted
explicitly set contentsCss in ckeditor config

ckeditor figures basePath from the location of ckeditor.js specified in
<script>'s src by default, but if we are in production mode ($DevelMode is
false), since ckeditor.js is also appended into /NoAuth/js/squished-...js,
ckeditor fails to find the correct basePath.

though we also set basePath before calling ckeditor, it's too late for
contentsCss url, which is a bug of ckeditor and fixed in 4.3.2

see also #29780 and http://dev.ckeditor.com/ticket/11350
fix owner dropdown warning for ticket search without queue clause

3056568 introduced switching to autocompleter if we have more than 50 owners.
The commit missed that Search/Build.html (Search/Elements/PickBasics) also use
the SelectOwner element and pass an empty Queues hash, if the query doesn't have
a queue clause (which is the case if you create a new ticket search).
In the above case the SelectOwner element pass an empty queue object as Objects
to the SelectOwnerDropdown which results in loading every user with OwnTicket
rights.

This commit fixes "Use of uninitialized value in concatenation" warnings on
ticket search without a queue clause in the query.
It also avoids the "More than 50 possible Owners found ..." notice on new
ticket search if you have more than 50 users with the OwnTicket right.
Collections - Align the attr label with row data

Respect the "align" attribute, but to also fall back to the "align"
value provided by the columnmap in cases where the format does not
explicitly define one.

This fixes especially the user collection listing page, but the other
types searches will reap the benefits of the fix.
Fix SetDisabled's warning message and return value on failure

Fixes I#29802.
Merge branch '4.2/users-collection-header' into 4.2-trunk
Allow global default search result sorts

Users could define these from Logged in -> Settings -> Search options
basically forever, but you couldn't set a global default.

We keep the old hard-coded-default of id, ASC despite it being one of
those "almost never what you want" since it means you always see your 5
year old bugs first. Let admins give their users a saner sort
(especially helpful on links in Quick Search).

When setting your user search prefs or creating a new search from
scratch, use the defaults rather than id/ASC.
wrap with <pre> so HTML::FormatText::WithLinks::AndTables can recognize it

in 6b117af, we replaced <pre> with "<div style='white-space: pre-wrap; font-family: monospace;'>
so long lines can wrap when converting plain text to html.

this brings another problem when downgrading html to text back(this happens
when the email template is html): HTML::FormatText::WithLinks::AndTables
doesn't recognize the div, so the whitespaces in the plain text are not
preserved.

this commit wraps the "<div>" with "<pre>" so long lines can wrap and also
HTML::FormatText::WithLinks::AndTables can recognize and make the right
conversion.  (thanks to trs++)

see also #29185
There is no threat to allowing the "color" attribute; it is allowed via CSS

Resolves I#28389.
Merge branch '4.2/configurable-search-order' into 4.2-trunk
Merge branch '4.2/avoid-disabling-submit-buttons' into 4.2-trunk
Merge branch '4.2/ckeditor-contents-css' into 4.2-trunk