I had to use a WP-Print for a recent WordPress project and, because the way i work, i started to search for plugins AFTER the psd was converted into html and a big part of code was already up & running. So, i downloaded latest version of WP-Print and I tried to use a basic setup:
The problem is that the plugin display the whole link tag (a href="...") and I only needed the href value. I edited wp-print.php (which is inside of you wp-content/plugins/wp-print folder) and i looked for print_link() function.
I saw the function accept three parameters: with first two you can set some extra text and the third (which is boolean) is for setting the way how function behave. So, you can call the function like the previous example or like this:
For showing the way you want. But, because i wanted only the link to that page, i edited wp-print.php and i changed the return of the function when the last parameter was boolean:
if($echo) {
echo $output."\n";
} else {
return $output;
}
Became:
if($echo) {
echo $output."\n";
} else {
return $print_link;
}
So now, i can use it like this:
Easy, isn’t it?