Quantcast
Channel: PHP Freaks: PHP Help
Viewing all articles
Browse latest Browse all 13200

Display row where strpos 0,1 are matched

$
0
0

I'm looking to only return rows where the first two letters of $_attributeSelection["backp1"] are GB

I'm sure I need to use strpos somehow, but Im not sure how to use it with my code can anyone show me how?





 

<?php
foreach ($selections as $_selection) {
$_attributeSelection = $_selection->attributes();
?>
<tr>
<td>
<?php echo $_attributeSelection["name"] ?> 
</td> 

<td>
<b><?php echo $_attributeSelection["backp1"] ?></b><br/> 
</td>

</tr>
 

 


Viewing all articles
Browse latest Browse all 13200

Trending Articles