Code works on page-example.php by not category-example.php

Code works on page-example.php by not category-example.php

tech