ajax.php
changeset 593 4f9bec0d65c1
parent 592 27377179fe58
child 685 17ebe24cdf85
equal deleted inserted replaced
592:27377179fe58 593:4f9bec0d65c1
   434       $n = Array();
   434       $n = Array();
   435       
   435       
   436       $name = sanitize_page_id($name);
   436       $name = sanitize_page_id($name);
   437       $name = str_replace('_', ' ', $name);
   437       $name = str_replace('_', ' ', $name);
   438       
   438       
   439       for($i=0;$i<sizeof($paths->pages)/2;$i++)
   439       foreach ( $paths->pages as $i => $_ )
   440       {
   440       {
   441         if( ( 
   441         if( ( 
   442             preg_match('#'.preg_quote($name).'(.*)#i', $paths->pages[$i]['name']) ||
   442             preg_match('#'.preg_quote($name).'(.*)#i', $paths->pages[$i]['name']) ||
   443             preg_match('#'.preg_quote($name).'(.*)#i', $paths->pages[$i]['urlname']) ||
   443             preg_match('#'.preg_quote($name).'(.*)#i', $paths->pages[$i]['urlname']) ||
   444             preg_match('#'.preg_quote($name).'(.*)#i', $paths->pages[$i]['urlname_nons']) ||
   444             preg_match('#'.preg_quote($name).'(.*)#i', $paths->pages[$i]['urlname_nons']) ||