config social api excluded categories not working

September 2015 Joomla Template
GK User
Fri Sep 16, 2016 11:24 pm
I exclude a category in SOCIAL API configurations but it doesn`t change anything and social api is still visible... site: mieroszowdawniej.pl for example: http://mieroszowdawniej.pl/index.php/20 ... 1-13-45-11
User avatar
Expert Boarder

teitbite
Tue Sep 20, 2016 9:14 am
Hi

Please send me an access to joomla panel so I'll be able to check this problem.
User avatar
Moderator

GK User
Wed Sep 21, 2016 7:03 am
access details send in private message (still in outbox??? should not be in send messages???)
User avatar
Expert Boarder

teitbite
Wed Sep 21, 2016 9:29 am
Hi

Yes I got it. Thank You.
I've informed programmers about this issue. Will let You know as soon as they will answer me.
User avatar
Moderator

teitbite
Thu Sep 22, 2016 11:18 am
Hi

Ok. I got the answer. Exclusion for category is only possible when our social icons are used, and since You are using K2 articles, than social icons are also taken from K2 code so it's not possible to restrict that.

Basically, restriction works only with regular joomla articles.
User avatar
Moderator

GK User
Thu Sep 22, 2016 11:30 am
You wrote: "Basically, restriction works only with regular joomla articles."

I am not quite sure if I understand... It means that to exclude categories I need to work only with Joomla articles and I cannot in the same time use K2 articles? Or you trying to tell that it is not working for K2 articles?
Articles which I want to exclude are native Joomla articles so to be honest I do not understand your answer.
User avatar
Expert Boarder

GK User
Fri Sep 23, 2016 6:06 pm
I need to add that for example in template InStyle I have done everything exactly the same and joomla articles are excluded as should be.
User avatar
Expert Boarder

GK User
Sun Sep 25, 2016 9:43 am
Will I get any reply?
User avatar
Expert Boarder

teitbite
Mon Sep 26, 2016 1:10 pm
Hi

Please do not bump Your own thread. Each bump rewrites time of last activity and pushes Your question at the end of the line.

Exclusion build in template only works with regular joomla articles. You still can use K2 articles, but K2 articles has their own social buttons so our buttons are not used there (this is why it cannot be excluded).
User avatar
Moderator

teitbite
Tue Oct 04, 2016 9:38 am
Hi

Wlasnie widzialem Panska wiadomosc w PM. Prosze o przeslanie dzialajacego dostepu do panelu. Ten przeslany wczesniej nie dzialal, wiec przynaleznosc do K2 wywnioskowalem to kodzie zrodlowym strony. Jak widac blednie.
User avatar
Moderator

teitbite
Mon Oct 10, 2016 9:39 am
Hi

Ok. Widze, ze dla tego templatu jest zasadnica zmiana dla wlasnie icon. I rzeczywiscie przypisywana z automatu funkcjonalnosc moze tu nie dzialac. Poprosze programistow o jaka modyfikacje w tym rejonie i odezwe sie jak tylko bede cos wiedzial wiecej.
User avatar
Moderator

teitbite
Wed Oct 12, 2016 8:15 am
Hi

W pliku /html/com_content/article/default.php trzeba dodac przed tym duzym warunkiem:

Code: Select all
<?php
    $excluded_articles = explode(',', $this->parent->API->get('excluded_arts', ''));
    $excluded_categories = $this->parent->API->get('excluded_cats', '');
?>


a do samego warunku dodac 2 linijki:

Code: Select all
!in_array($this->item->id, $excluded_articles) &&
!in_array($this->item->catid, $excluded_categories) &&


jezeli beda z tym problemy prosze podeslac ftp, a wprowadze zmiany.
User avatar
Moderator

GK User
Wed Oct 12, 2016 10:14 am
Wiem, że to troszkę lamerskie ale nie da się tego prościej???

.
.
.

Zastąpić

.
.
.

Nie mam zielonego pojęcia jak się do tego zabrać...
teitbite wrote:Hi

W pliku /html/com_content/article/default.php trzeba dodac przed tym duzym warunkiem:

Code: Select all
<?php
    $excluded_articles = explode(',', $this->parent->API->get('excluded_arts', ''));
    $excluded_categories = $this->parent->API->get('excluded_cats', '');
?>


a do samego warunku dodac 2 linijki:

Code: Select all
!in_array($this->item->id, $excluded_articles) &&
!in_array($this->item->catid, $excluded_categories) &&


jezeli beda z tym problemy prosze podeslac ftp, a wprowadze zmiany.
User avatar
Expert Boarder

teitbite
Wed Oct 12, 2016 10:42 am
Hi

Prosze sprobowac podmienic na ten plik.
User avatar
Moderator

GK User
Wed Oct 12, 2016 1:43 pm
Podmieniłem plik w podanym katalogu template`a i przy artykułach native joomla pojawia się: wystąpił błąd 0 w trakcie wykonywania twojego polecenia

Ikonek udostępniania nie ma ;) więc idziemy w dobrym kierunku...

teitbite wrote:Hi

Prosze sprobowac podmienic na ten plik.
User avatar
Expert Boarder

teitbite
Thu Oct 13, 2016 2:54 pm
Hi

Dlatego bylo by latwiej gdybym mial dostep do ftp. W tej chwili raczej zgadule jak to rozbudowac, bo nie mam pozliwosci przetestowania. Prosze podeslac dostep do ftp.
User avatar
Moderator

teitbite
Mon Oct 17, 2016 1:30 pm
Hi

Widze, ze odwolanie sie do API powoduje ten blad. Musze poprosic programistow o pomoc tutaj. Dam znac jak bede wiedzial jak to rozwiazac.
User avatar
Moderator

teitbite
Sat Oct 22, 2016 1:19 pm
Hi

Bardzo przepraszam, programisci odpisali zaraz po moim pytaniu, ale mam cos z kontem mailowym i nie dostalem potwierdzenia. Problem wymagal podmiany 2 lini z kodu, ktory dalem poprzednio. Teraz dziala.

Code: Select all
<?php
$excluded_articles = explode(',', $templateSettings->get('excluded_arts', ''));
$excluded_categories = $templateSettings->get('excluded_cats', '');
?>
User avatar
Moderator

GK User
Sat Oct 22, 2016 7:46 pm
Hi
Faktycznie nie wyświetla się error ale udostępnianie wciąż jest obecne pomimo wykluczenia kategorii artykułów joomli.

teitbite wrote:Hi

Bardzo przepraszam, programisci odpisali zaraz po moim pytaniu, ale mam cos z kontem mailowym i nie dostalem potwierdzenia. Problem wymagal podmiany 2 lini z kodu, ktory dalem poprzednio. Teraz dziala.

Code: Select all
<?php
$excluded_articles = explode(',', $templateSettings->get('excluded_arts', ''));
$excluded_categories = $templateSettings->get('excluded_cats', '');
?>
User avatar
Expert Boarder

teitbite
Thu Oct 27, 2016 8:58 am
Hi

The part from the condition:

Code: Select all
!in_array($this->item->id, $excluded_articles) &&
!in_array($this->item->catid, $excluded_categories) &&


was gone in code. I've added it back.
User avatar
Moderator

GK User
Fri Oct 28, 2016 9:00 am
THANK YOU :) THANK YOU :) THANK YOU :)
User avatar
Expert Boarder

teitbite
Tue Nov 01, 2016 10:53 am
Hi

Finally :) Happy I could help, sorry for keep You waiting that long.
User avatar
Moderator


cron