But again get after w3 validator & did not start a character reference. (& probably should have been escaped as &.)
following my part of url anchor tag codings
<?php
$split_name = explode('and',strtolower($res_cat['cat_name']));
$split_catname = str_replace('',' ',$split_name[0]);
$category_name = str_replace('and','&',$res_cat['cat_name']);
echo "<li><img src='".$res_cat['cat_icon']."' alt='b_icon'/> <a href='catsec.php?act=cat&cat_id=".rtrim($split_catname).''.$res_cat['cat_id']."'>".$category_name."</a></li>";
?>
Example:
http://mydomainname.com/catsec.php?act=cat&cat_id=energy-41.
I am confused. Help me in advance. Thanks.
I check the html you post and below here you find a the replacement that is correct by the W3C
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Test</title>
</head>
<body>
<div id="item-sec-1">
<ul>
<li><img src='assets/images/b2b/energy.ico' alt='b_icon'/> <a href='catsec.php?act=cat&cat_id=energy-41'>Energy & Power</a></li>
<li><img src='assets/images/b2b/elec.ico' alt='b_icon'/> <a href='catsec.php?act=cat&cat_id=electronics-42'>Electronics & Electricals</a></li>
</ul>
</div>
</body>
</html>
The problem with your html is that there where -- in the code. And also you missed the title tag that must be there.
if you want to make a comment you should use <!-- comment here -->
I hope this helps you.