How do I remove the link function from:
<? php echo '<a href="' . zen_href_link(FILENAME_DEFAULT, 'cPath=' . $_GETcPath, 'NONSSL') . '">' . $category_icon_display_name . '</a>'; ?>
How do I remove the link function from:
<? php echo '<a href="' . zen_href_link(FILENAME_DEFAULT, 'cPath=' . $_GETcPath, 'NONSSL') . '">' . $category_icon_display_name . '</a>'; ?>
Back up a bit ... what business issue brings you to the place of asking that specific technical question?
What's the problem you're trying to solve? and why?
.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole
Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.
Nothing complicated. I just don't want the category name at the top of the product page to function as a link, that being - I thought - the easiest way to apply css to that alone. I've spent half the day trying to work that out. The other half trying to get the category name to site next to the category icon, rather than below it. Failed on both counts!
If your root purpose is to style the category name, that can be done without touching its link code. Seeing the page live will let us advise on the best way to move/style it.
Try just changing a setting:
Admin->Configuration->Product Info->Previous Next - Navigation Includes Category Position ... set it to Off
.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole
Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.
That leaves me neither icon or category name. I want to use both, with category name to the right of the icon, vertically aligned half way down the image, or thereabouts, and without the category name functioning as a link.
Odd ... but ... whatever ...
Assuming the PHP code you quoted in your first post is indeed the correct code to deal with what you want to change (I've NOT checked that), then you would change it as follows ...
It's basic HTML inside a PHP statement, so removing the <a href>...</a> bit would become this:Code:<?php echo $category_icon_display_name; ?>
.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole
Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.
Here is my tpl_modules_category_icon_display.php
<div align="<?php echo $align; ?>" id="categoryIcon" class="categoryIcon"><?php echo '<a href="' . zen_href_link(FILENAME_DEFAULT, 'cPath=' . $_GET['cPath'], 'NONSSL') . '">' . $category_icon_display_image . $category_icon_display_name . '</a>'; ?>
<?php echo $category_icon_display_name; ?></div>
My original post was code I had having separated the image from the name, but here, I revert to the whole thing. When I add the basic echo, as above, nothing at all appears!
Same with original code removed.