CMSimple offers the function printlink() to insert a link to the print view in the template. One can change the link text by changing $tx['menu']['print']. However, a not so uncommon requirement is to use an image instead of a text. It is possible to use the following:
Code: Select all
tx['menu']['print']="<img src="\path/of/image\" alt="print view">";
We may consider offering a function that returns the URL of the print view instead of the complete link additionally. Then it would be possible to write in the template:
Code: Select all
<a href="<?php echo XH_printUrl();?>"><?php tag('img src="' . $pth['folder']['templateimages'] . 'print.png" alt="' . $tx['menu']['print'] . '');?></a>
Code: Select all
$tx['menu']['print']="tag('img src=\"' . $pth['folder']['templateimages'] . 'print.png\");";
Christoph