GK5 Top Banner - Title limit doesn't seem to work

October 2015 Joomla Template
Rate this topic: Evaluations: 1, 1.00 on the average.Evaluations: 1, 1.00 on the average.Evaluations: 1, 1.00 on the average.Evaluations: 1, 1.00 on the average.Evaluations: 1, 1.00 on the average.1.00 out of 6 based on 1 vote(s)
GK User
Sat Dec 19, 2015 12:19 pm
Reply with quote
Report this post
Hello,
I am not sure if this problem is related to the template or to the GK5 module...
So, I can't put a limit at the title. I have tried both "words" or "characters" limit, but this doesn't seem to have effect.
Can you please help me?

PS. Site is under construction and it is located here : www.zantepress24.gr/test24
User avatar
Fresh Boarder

GK User
Sun Dec 20, 2015 2:15 am
Reply with quote
Report this post
While waiting for your answer, please allow me to ask one more question.

What determines the height of the header module (New news header)? In your demo the module is taller than in mine site.

Thank you
User avatar
Fresh Boarder

GK User
Sun Dec 20, 2015 1:57 pm
Reply with quote
Report this post
Sorry for posting again, but I can't find how to edit my previous post :(

So, I noticed another one issue (for me). I placed a banner at sidebar position, and the whole page lost the "responsiveness". Please look at the attached image to understand what I am trying to say..

site.jpg


The truth is that this banner is big (about 480px), but I thought that it could automatically resized (as most templates do). Maybe I am wrong but that's what I allready know, so far...

Please advise.
User avatar
Fresh Boarder

teitbite
Mon Dec 21, 2015 11:32 am
Reply with quote
Report this post
Hi

This image has a fixed dimentions set in code: "<img width="480" height="335". Add this to override.css to make it force to be responsive:

Code: Select all
#gkSidebar .box img {
max-width: 100% !important;
height: auto !important;
}


for text/title limit You need to tell me which module exactly You have in mind. Some module styles may have this option disabled, but I'm not 100% sure.
User avatar
Moderator

GK User
Mon Dec 21, 2015 1:08 pm
Reply with quote
Report this post
Thank you.
For the title limit issue,I was talking about the gk5 news show module, which is located at the top-banner position, right after the menu. It is using the mode "new news slider".

Also I would like to know What determines the height of the header module (New news header)? In your demo the module is taller than in mine site. Is it related to the images that are being used? Sorry for this silly question.
User avatar
Fresh Boarder

teitbite
Thu Dec 24, 2015 11:33 am
Reply with quote
Report this post
Hi

Height of the header module is determined by the dimentions of the biggest picture. I think You can set the dimentions in thumbnails settings options, but You need to try that, I'm not 100% sure.

For title limit I can see in code that it's not implemented for this style. Try edit file /modules/mod_news_pro_gk5/tmpl/portal_modes/new_news_header/controller.php and in line 64:

Code: Select all
echo '   <h2 class="gkTitle"><a href="'.strip_tags($this->get_link($i)).'">'.strip_tags($this->parent->content[$i]['title']).'</a></h2>';


make a change to:

Code: Select all
            echo '   <h2 class="gkTitle"><a href="'.strip_tags($this->get_link($i)).'">'.mb_substr( strip_tags($this->parent->content[$i]['title']), 30 ).'</a></h2>';


Play with the 30 value I set as an example to get the desired number of characters.
User avatar
Moderator

GK User
Mon Jan 04, 2016 10:40 pm
Reply with quote
Report this post
Happy New Year!
Sorry for the late response....
But you gave me code for "new news header"
As I told you I need to trim the titles on "new news slider". As I understand I have to edit this /modules/mod_news_pro_gk5/tmpl/portal_modes/new_news_slider/controller.php

Can you guide me please?
User avatar
Fresh Boarder

teitbite
Wed Jan 06, 2016 2:00 pm
Reply with quote
Report this post
Hi

Please edit /tmpl/portal_modes/new_news_slider/controller.php and add this line:

Code: Select all
     echo '   <h2 class="gkTitle"><a href="'.strip_tags($this->get_link($i)).'">'.mb_substr( strip_tags($this->parent->content[$i]['title']), 30 ).'</a></h2>';


to level 60. Right under the line:

Code: Select all
         echo '<h2 class="gkTitle"><a href="'.strip_tags($this->get_link($i)).'">'.strip_tags($this->parent->content[$i]['title']).'</a></h2>';

User avatar
Moderator

GK User
Wed Jan 06, 2016 2:27 pm
Reply with quote
Report this post
What this does, is to trim (cut) the first letters and not the last!
User avatar
Fresh Boarder

teitbite
Sun Jan 10, 2016 11:20 am
Reply with quote
Report this post
Hi

You are right :) My mistake. Here is a correct code:

Code: Select all
echo '   <h2 class="gkTitle"><a href="'.strip_tags($this->get_link($i)).'">'.mb_substr( strip_tags( $this->parent->content[$i]['title']), 0, 30 ).'</a></h2>';
User avatar
Moderator

GK User
Sun Jan 10, 2016 9:51 pm
Reply with quote
Report this post
Thank you.
I will apply it later.
Now it's time to open another thread!
User avatar
Fresh Boarder

teitbite
Wed Jan 13, 2016 11:43 am
Reply with quote
Report this post
Hi

Please let me know if it worked, so i will be able to close the thread.
User avatar
Moderator

GK User
Wed Jan 13, 2016 11:45 am
Reply with quote
Report this post
Sorry I was extemely busy and I didn't checked it. Will do that ASAP!
User avatar
Fresh Boarder

GK User
Wed Jan 13, 2016 12:15 pm
Reply with quote
Report this post
Yes! It did it!

Actually before closing this thread I would like to ask how to put dots after the cutting words. (....)
Hope you understand my english
User avatar
Fresh Boarder

teitbite
Sat Jan 16, 2016 12:26 pm
Reply with quote
Report this post
Hi

Simple :) A small modification to this code:

Code: Select all
echo '   <h2 class="gkTitle"><a href="'.strip_tags($this->get_link($i)).'">'.mb_substr( strip_tags( $this->parent->content[$i]['title']), 0, 30 ).'....</a></h2>';
User avatar
Moderator

GK User
Sat Jan 16, 2016 6:10 pm
Reply with quote
Report this post
Thank you!
I discoverd another one problem with the new news slider module.
It doesn't animate.
I have set it to autoanimate but with no luck.
The strange part is that I don't see any errors in console....
anim.JPG
User avatar
Fresh Boarder

teitbite
Wed Jan 20, 2016 6:17 pm
Reply with quote
Report this post
Hi

I do not think autoanimation is implemented for this style, but You may achieve same look using Normal Mode and then autoanimation will work.
User avatar
Moderator


cron