php sort array of version strings : <p>I would like to sort an array of version strings in php.</p>

<p>Input would be something like this:</p>

<pre><code>["2019.1.1.0", "2019.2.3.0", "2019.2.11.0", "2020.1.0.0", "2019.1.3.0", "2019.3.0.0"]
</code></pre>

<p>What is the easiest way to sort this? Sorting the strings as is does not work, because that would put the "2019.2.11.0" before "2019.2.3.0" and that is of course not what I want.</p>

<p>Result should be</p>

<pre><code>["2019.1.1.0", "2019.1.3.0", "2019.2.3.0", "2019.2.11.0", "2019.3.0.0", "2020.1.0.0"]
</code></pre>
