Kunena 7.0.4 Released

The Kunena team has announce the arrival of Kunena 7.0.4 [K 7.0.4] in stable which is now available for download as a native Joomla extension for J! 5.4.x/6.0.x. This version addresses most of the issues that were discovered in K 6.2 / K 6.3 / K 6.4 and issues discovered during the last development stages of K 7.0

Question Images viewable only of registered?

More
17 years 2 months ago - 17 years 2 months ago #6602 by kingbt
Hi, I want to ask how do I make that pictures should be viewable only by redistered members, and so not indexed by google :)

Or even better pictures from external hosts should be hidden from guests, and not indexed by google.

Is there a posibily to do this the easy way?

Nasul is my site.
Last edit: 17 years 2 months ago by kingbt.

Please Log in or Create an account to join the conversation.

More
17 years 2 months ago #6725 by Matias
Currently there is no easy way for doing this. It should be quite easy to implement, though..

Vote for it in UserVoice. :)

Please Log in or Create an account to join the conversation.

More
17 years 2 months ago - 17 years 2 months ago #6745 by rinuccio
Insert B)
Code:
[hide][img]link image[/img][/hide]
Last edit: 17 years 2 months ago by rinuccio.

Please Log in or Create an account to join the conversation.

More
17 years 2 months ago - 17 years 2 months ago #6756 by roland76
If you want it for every new image automatic change in kunena.image.upload.php line 102:
Code:
$code = '[img]' . KUNENA_LIVEUPLOADEDPATH. '/images/' . $newFileName . '[/img]'; } else { $code = '[img size=' . $width . ']' . KUNENA_LIVEUPLOADEDPATH. '/images/' . $newFileName . '[/img]';
into
Code:
$code = '[hide][img]' . KUNENA_LIVEUPLOADEDPATH. '/images/' . $newFileName . '[/img][/hide]'; } else { $code = '[hide][img size=' . $width . ']' . KUNENA_LIVEUPLOADEDPATH. '/images/' . $newFileName . '[/img][/hide]';
Last edit: 17 years 2 months ago by roland76.

Please Log in or Create an account to join the conversation.

More
17 years 1 month ago - 17 years 1 month ago #6786 by roland76
Here is a other way which works also with old posts:

Change in kunena.parser.php on line 324:
Code:
case 'img': if($between) { $task->autolink_disable--; # continue autolink conversion // Make sure we add image size if specified and while we are // at it also set maximum image width from text width config. // // NOTICE: image max variables from config are not intended // for formating but to limit the size of uploads, which can // be larger than the available post area to support super- // sized popups. $imgmaxsize = (int)(($GLOBALS["fbConfig"]->rtewidth * 9) / 10); // 90% of text width $imgtagsize = isset($tag->options["size"]) ? (int)htmlspecialchars($tag->options["size"]) : 0; if($imgtagsize>0 && $imgtagsize<$imgmaxsize) { $imgmaxsize = $imgtagsize; } // Need to check if we are nested inside a URL code if($task->autolink_disable == 0) { $tag_new = "<a href='".$between."' rel=\"lightbox\"><img src='".$between.($imgtagsize ?"' width='".$imgmaxsize:'')."' style='max-width:".$imgmaxsize."px; ' alt='' /></a>"; } else { $tag_new = "<img src='".$between.($imgtagsize ?"' width='".$imgmaxsize:'')."' style='max-width:".$imgmaxsize."px; ' alt='' />"; } return TAGPARSER_RET_REPLACED; } return TAGPARSER_RET_NOTHING; break;
into
Code:
case 'img': if($between) { if ($my->id==0) { // Hide between content from non registered users $tag_new = '<b>' . _KUNENA_BBCODE_HIDEIMG . '</b>'; } else { $task->autolink_disable--; # continue autolink conversion // Make sure we add image size if specified and while we are // at it also set maximum image width from text width config. // // NOTICE: image max variables from config are not intended // for formating but to limit the size of uploads, which can // be larger than the available post area to support super- // sized popups. $imgmaxsize = (int)(($GLOBALS["fbConfig"]->rtewidth * 9) / 10); // 90% of text width $imgtagsize = isset($tag->options["size"]) ? (int)htmlspecialchars($tag->options["size"]) : 0; if($imgtagsize>0 && $imgtagsize<$imgmaxsize) { $imgmaxsize = $imgtagsize; } // Need to check if we are nested inside a URL code if($task->autolink_disable == 0) { $tag_new = "<a href='".$between."' rel=\"lightbox\"><img src='".$between.($imgtagsize ?"' width='".$imgmaxsize:'')."' style='max-width:".$imgmaxsize."px; ' alt='' /></a>"; } else { $tag_new = "<img src='".$between.($imgtagsize ?"' width='".$imgmaxsize:'')."' style='max-width:".$imgmaxsize."px; ' alt='' />"; } } return TAGPARSER_RET_REPLACED; } return TAGPARSER_RET_NOTHING; break;

I have included a additional language string which was shown for guests. You can here define your own text like "This image is only seen for registered users".

You have to insert _KUNENA_BBCODE_HIDEIMG in your language file or change this line:
Code:
$tag_new = '<b>' . _KUNENA_BBCODE_HIDEIMG . '</b>';
into
Code:
$tag_new = '';
Last edit: 17 years 1 month ago by roland76.

Please Log in or Create an account to join the conversation.

More
17 years 1 month ago #6795 by kingbt
ok, roland76, thank you very much

Nasul is my site.

Please Log in or Create an account to join the conversation.

Time to create page: 0.249 seconds