Remove unused class

Change-Id: I64dae977deb24d83d3ddde30b3df503c346495bf
Prevent double escaping of urls for text fields

First part to fix the requests #5986

Change-Id: Idd045f876f4a865dd91ef4f2305622d7acd91102
Refactoring: better readability of pattern matching

Use named subpatterns since after a preg_match, $matches[2] means
nothing comparing to $matches['project_name']. Furthermore it will now
be easier to add subpatterns to the regexp without having to shift every
index usages of $matches.

Change-Id: I9cea709c1b97b0cf8fd5c85342f6ebbc09325517
Do not double escape urls in html text

There is a side effect. If the text is already containing a link to a
reference:

    <a href="…">art #123</a>

then the link to the reference will be injected inside the existing <a>:

    <a href="…"><a href="…">art #123</a></a>

The browser will interpret it as the following:

   <a href="…"></a><a href="…">art #123</a>

The first empty link will be hidden from the user, therefore we assume
that it is a good compromise instead of having either no links or
crappiness: fix request #5986 - URLs are corrupted by a double escape.

Change-Id: I2f46bcf14c5ea941ff807673ad41f416f48ac686
Remove usage of tmp var when unecessary

This fix an issue when you have a ref to an artifact v3 in another
project, followed by a ref to an artifact v5 in the current project
 => the link to the v5 were not inserted.

Change-Id: Ib5bc5f1b4366c4946d15b11dcc4daa049b75ce2c
Merge remote-tracking branch 'gerrit/5986_urls_corrupted_by_double_escape' into tuleap-stable-master

* gerrit/5986_urls_corrupted_by_double_escape:
  Remove usage of tmp var when unecessary
  Do not double escape urls in html text
  Refactoring: better readability of pattern matching
  Prevent double escaping of urls for text fields
  Remove unused class

Change-Id: I1776daf511c917badaf4a8a283cbc04a5ddb16d0
Tuleap 6.9.99.33

Change-Id: Id73a43a333d041651c5ec0b0b025cb5650ab092b