Answer the question
In order to leave comments, you need to log in
How to display all elements starting with a certain letter?
There is such a pointer. Below it is a list of all factories. It is necessary to make such functionality that when clicking on a letter, all factories whose names begin with this letter are displayed from the list.
Answer the question
In order to leave comments, you need to log in
1) first select all the elements to find out which letters make links and which do not.
2) When clicking on a letter, select elements by the filter "%NAME" => 'letter'
<?php
$arr = array("mike", "kate", "john", "michele", "paul", "samanta", "stella");
$res = array_filter($arr, function($d) {
return mb_substr($d, 0, 1) == 'j';
});
var_dump($res);
array(1) { [2]=> string(4) "john" }
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question