<?xml version="1.0" encoding="UTF-8" ?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
  <title>Latest snippets tagged array</title>
  <link rel="alternate" href="http://snippets.prendreuncafe.com/snippets/tagged/array/order_by/date"></link>
  <id>http://snippets.prendreuncafe.com/snippets/tagged/array/order_by/date</id>
  <updated>2006-11-23T19:18:47Z</updated>
  <author>
    <name>Symfony</name>
    <author_email>noreply@symfony-project.com</author_email>
  </author>
<entry>
  <title>Foreach et les variables passées en référence</title>
  <link href="http://snippets.prendreuncafe.com/snippet/21"></link>
  <updated>2006-11-23T19:18:47Z</updated>
  <id>21</id>
  <summary type="html">Merci Thibs ;)

[code]
$arr = array(1, 2, 3, 4);
foreach ($arr as &amp;$value) 
{
  $value = $value * 2;
}
print_r($arr); // $arr vaut maintenant array (2, 4, 6, 8)
[/code]</summary>
</entry>
<entry>
  <title>Obtenir un tableau de caractères depuis une chaîne en PHP4</title>
  <link href="http://snippets.prendreuncafe.com/snippet/2"></link>
  <updated>2006-10-11T15:43:04Z</updated>
  <id>2</id>
  <summary type="html">En php5 on a str_split : http://fr.php.net/manual/fr/function.str-split.php

Et en PHP4 :

[code]
$chars = preg_split('#(?&lt;=.)(?=.)#s', $string);
[/code]</summary>
</entry>
</feed>