Skip to main content
Recent Posts
41
General ElkArte discussions / Re: Preliminary ElkArte 1.1.10 - Release Notes
Last post by Spuds -
Welp:punch::punch::head_bandage:

Found a couple of more minor things that I have fixed.

Like Stats:
 - Was showing the top 10 most liked posts, but not in 1-N order, was also showing the count wrong due to wrong value used in template
 - Was not formatting numbers so you would end up with 1234 and not 1,234 or 1.234
 - Was showing the wrong number of likes on a topic, it had the right number but wrong value was used in the template

Structured Data
- Saw a google suggestion that the Datetime property was missing a timezone.  In some more reading that should have been set as ISO8601 or YYYY-MM-DDTHH:MM:SS+00:00 so now it will be.
43
Addons / Re: [ADDON] SimplePortal
Last post by Spuds -
That be a bug  :grin: Yeah for 1.0.3

The fix should be to edit
/sources/admin/ManageSPortalModule.controller.php

Find
Code: (find) [Select]
		// Define the new menu item(s), show it for modes 1 and 3 only
$buttons = elk_array_insert($buttons, 'home', array(
'forum' => array(
'title' => empty($txt['sp-forum']) ? 'Forum' : $txt['sp-forum'],
'data-icon' => 'i-spgroup',
'href' => $sportal_url,
'show' => empty($context['disable_sp']),
'sub_buttons' => array(),
),

Code: (replace) [Select]
		// Define the new menu item(s), show it for modes 1 and 3 only
$buttons = elk_array_insert($buttons, 'home', array(
'forum' => array(
'title' => empty($txt['sp-forum']) ? 'Forum' : $txt['sp-forum'],
'data-icon' => 'i-spgroup',
'href' => $sportal_url,
'show' => empty($context['disable_sp']),
'sub_buttons' => array(),
'action_hook' => true,
),
So adding that 'action_hook' => true, to that menu options array
44
Addons / Re: [ADDON] Levertine Gallery
Last post by Burke Knight -
Found an issue that may want to look at.

When have site owned albums, in the LevGal sidebar, it uses the logo image from theme settings.
This can cause not being able to actually see it well, due to many logos being a lot wider than their height.
My suggestion, is either have it where they can select an image for site album image in the settings, or edit LevGal-Album.template.php
and change this:

Code: [Select]
	// a site owned album, use site logo if available.
elseif(!empty($context['header_logo_url_html_safe']))
{
echo '
<div class="posted_by">', $txt['lgal_owned_by'], '</div>
<div class="album_owner">
<span class="user_avatar">
<img class="avatar avatarresize" src="', $context['header_logo_url_html_safe'], '" alt="', $context['forum_name_html_safe'], '" />', '
</span>
<div class="">', $context['forum_name_html_safe'], '</div>
<div class="user smalltext">', sprintf($txt['lgal_see_more'], $scripturl . '?media/albumlist/site/'), '</div>
</div>
<br />';
}

To maybe this:

Code: [Select]
	// a site owned album, use site logo if available.
elseif(!empty($context['header_logo_url_html_safe']))
{
echo '
<div class="posted_by">', $txt['lgal_owned_by'], '</div>
<div class="album_owner">
<span class="user_avatar">
<img class="avatar avatarresize" src="' . $context['favicon'] . '" alt="', $context['forum_name_html_safe'], '" />', '
</span>
<div class="">', $context['forum_name_html_safe'], '</div>
<div class="user smalltext">', sprintf($txt['lgal_see_more'], $scripturl . '?media/albumlist/site/'), '</div>
</div>
<br />';
}

Or possibly, mobile.png
47
Addons / Re: [ADDON] Levertine Gallery
Last post by Spuds -
In LevGal-Item.template.php

Code: (find) [Select]
<a href="' . (!empty($viewInline) ? substr($context['item_actions']['actions']['download'][1], 0, -10) : '') . '">

Code: (replace) [Select]
<a href="' . (!empty($viewInline) ? substr($context['item_actions']['actions']['download'][1], 0, -10) : '') . '" target="_blank">

That will generally affect any non-image files and open them in a new tab ... its that target="_blank" that causes that behavior.  Try that and let me know if that is what you wanted.
49
Addons / Re: [ADDON] Levertine Gallery
Last post by Burke Knight -
@Spuds
Is there a way, when having files, such as pdf, to have them open in new tab when they are clicked?
Right now, when they click in the item list, it opens whatever pdf viewer they have in the same tab.
50
Support / Re: Guest can "Like" posts
Last post by Spuds -
That function is blocked to guests, so you will have to make a couple of file edits.

First you need to add the ability to assign the likes post permission to guests.  In sources/subs/Permissions.class.php towards the top find protected $illegal_guest_permissions = array( in that array find 'like_posts', and comment it out as //'like_posts',

You will then be able to assign that permission to guests

Second in sources\controllers\Likes.controller.php in the private function prepare_like() towards the top of that function find is_not_guest(); and again comment that out as //is_not_guest();

That should be all that is needed ... side effects:man_shrugging: