Hey,
if you think of using Foo Gallery for your website, you’ll soon find out there’s no way to put the custom links on the images you’re using on Nofollow. Furthermore, the opening in a new tab is not possible without further settings, not settable by default.
The following Hardcode Fix changes this for all Foo Galleries regardless of settings and plugins!
In the file class-foogallery-attachment.php in the folder / wp-content / plugins / foogallery / includes / after
Code: [Select]
foreach ( $attr as $name => $value ) {
$html .= ” $name=” . ‘”‘ . $value . ‘”‘;
}
$html .= ‘>’;
search and replace with
Code: [Select]
foreach ( $attr as $name => $value ) {
$html .= ” $name=” . ‘”‘ . $value . ‘”‘;
}
$html .= ‘rel=”nofollow”>’;
For Nofollow
and if you also want to standardize the opening in a new tab at the same time, replace it with the following snippet instead:
Code: [Select]
foreach ( $attr as $name => $value ) {
$html .= ” $name=” . ‘”‘ . $value . ‘”‘;
}
$html .= ‘rel=”nofollow” target=”_blank”>’;
Then overwrite the old file and lo and behold, everything as you like. 😉