<?php
$a = [];
$a[0] = "<table style='color:; text-align: left;'>
<tr>
<td>Processor";
$a[1] = "</td>
<td> Intel Core 2 Duo - E8400";
$a[2] = "</td>
</tr>
<tr>
<td> Clockspeed";
$a[3] = "</td>
<td> 3.0 GHz";
$a[4] = "</td>
</tr>
<tr>
<td> Memory";
$a[5] = "</td>
<td> 4 GB";
$a[6] = "</td>
</tr>
<tr>
<td> Harddisk";
$a[7] = "</td>
<td> 250 GB";
$a[8] = "</td>
</tr>
<tr>
<td> Video-adapter";
$a[9] = "</td>
<td> VGA, Display";
$a[10] = "</td>
</tr>
<tr>
<td> Netwerkcard";
$a[11] = "</td><td> 1000 mbps LAN";
$a[12] = "</td>
</tr>
<tr>
<td> Optical drive";
$a[13] = "</td><td> DVD-Rewriter";
$a[14] = "</td>
</tr>
<tr>
<td> Operating system";
$a[15] = "</td><td> Windows7 or 10 Pro";
$a[16] = "</td>
</tr>
<tr>
<td> Warranty";
$a[17] = "</td><td> 2 years</td></tr></table>";
foreach ($a as &$e) {
$e = trim($e);
}
$joined = join($a);
$stripped = strip_tags($joined,"<td>");
$replaced = str_replace(["<td>","</td>"],["*",""],$stripped);
$arr = explode("*",$replaced);
array_shift($arr);
print_r($arr);
- Output for 7.0.0 - 7.0.26, 7.1.0 - 7.1.20, 7.2.0 - 7.2.33, 7.3.16 - 7.3.33, 7.4.0 - 7.4.33, 8.0.0 - 8.0.30, 8.1.0 - 8.1.28, 8.2.0 - 8.2.18, 8.3.0 - 8.3.4, 8.3.6
- Array
(
[0] => Processor
[1] => Intel Core 2 Duo - E8400
[2] => Clockspeed
[3] => 3.0 GHz
[4] => Memory
[5] => 4 GB
[6] => Harddisk
[7] => 250 GB
[8] => Video-adapter
[9] => VGA, Display
[10] => Netwerkcard
[11] => 1000 mbps LAN
[12] => Optical drive
[13] => DVD-Rewriter
[14] => Operating system
[15] => Windows7 or 10 Pro
[16] => Warranty
[17] => 2 years
)
- Output for 8.3.5
- Warning: PHP Startup: Unable to load dynamic library 'sodium.so' (tried: /usr/lib/php/8.3.5/modules/sodium.so (libsodium.so.23: cannot open shared object file: No such file or directory), /usr/lib/php/8.3.5/modules/sodium.so.so (/usr/lib/php/8.3.5/modules/sodium.so.so: cannot open shared object file: No such file or directory)) in Unknown on line 0
Array
(
[0] => Processor
[1] => Intel Core 2 Duo - E8400
[2] => Clockspeed
[3] => 3.0 GHz
[4] => Memory
[5] => 4 GB
[6] => Harddisk
[7] => 250 GB
[8] => Video-adapter
[9] => VGA, Display
[10] => Netwerkcard
[11] => 1000 mbps LAN
[12] => Optical drive
[13] => DVD-Rewriter
[14] => Operating system
[15] => Windows7 or 10 Pro
[16] => Warranty
[17] => 2 years
)
preferences:
315.34 ms | 403 KiB | 185 Q