Simple Machines Community Forum

Customizing SMF => Graphics and Templates => Topic started by: faliro on February 24, 2017, 06:56:36 PM

Title: How to tighten up mini Profile
Post by: faliro on February 24, 2017, 06:56:36 PM
I want this gap gone:

https://i.snag.gy/C5driS.jpg

So it is like this:

https://i.snag.gy/Pos5lF.jpg

Any ideas? I am not sure how to close the gap.
Title: Re: How to tighten up mini Profile
Post by: Kindred on February 24, 2017, 07:05:22 PM
Use a different theme? ;)
Title: Re: How to tighten up mini Profile
Post by: faliro on February 24, 2017, 08:39:52 PM
The theme has it all together. It only changed when I added the alerts mod. It made a gap. I know it can be remedied, but just dont know how.
Title: Re: How to tighten up mini Profile
Post by: Steve on February 24, 2017, 09:31:33 PM
Quote from: faliro on February 24, 2017, 08:39:52 PMIt only changed when I added the alerts mod. It made a gap.

Then you would need to ask in the support thread for that mod. :)
Title: Re: How to tighten up mini Profile
Post by: faliro on February 24, 2017, 10:10:15 PM
Quote from: Steve on February 24, 2017, 09:31:33 PM
Quote from: faliro on February 24, 2017, 08:39:52 PMIt only changed when I added the alerts mod. It made a gap.

Then you would need to ask in the support thread for that mod. :)

:D I knew that was coming Steve!
Title: Re: How to tighten up mini Profile
Post by: faliro on February 25, 2017, 07:01:34 AM
I did ask and the response I got was nothing could be done about this. However, I am member of another forum that managed it so there must be a way.
Title: Re: How to tighten up mini Profile
Post by: Dzonny on February 25, 2017, 07:34:27 AM
Which exact "Alerts mod" are you using, can you post a link to that mod here?
Title: Re: How to tighten up mini Profile
Post by: faliro on February 25, 2017, 08:21:14 AM
Quote from: Dzonny on February 25, 2017, 07:34:27 AM
Which exact "Alerts mod" are you using, can you post a link to that mod here?

Sure.

https://www.smfpacks.com/alertmod

:)
Title: Re: How to tighten up mini Profile
Post by: Illori on February 25, 2017, 08:24:24 AM
can you provide a link to your forum so we can see the issue and possibly provide a fix?
Title: Re: How to tighten up mini Profile
Post by: faliro on February 25, 2017, 08:29:28 AM
Of course.

http://greek-football.com/index.php?action=forum
Title: Re: How to tighten up mini Profile
Post by: Shambles on February 25, 2017, 10:57:45 AM
Can you provide a test account?
Title: Re: How to tighten up mini Profile
Post by: Dzonny on February 26, 2017, 03:11:37 PM
There seems to be an extra "<br class="clear">" somewhere inside the "<li class="greeting">" and it's causing the rest of the text to move in the new line. Can you try to find and remove it, or to attach your index.template.php (just guessing it's there though)?
Title: Re: How to tighten up mini Profile
Post by: Illori on February 26, 2017, 03:12:42 PM
no it is display.template.php not index.template.php.
Title: Re: How to tighten up mini Profile
Post by: faliro on February 26, 2017, 05:22:04 PM
Quote from: Illori on February 26, 2017, 03:12:42 PM
no it is display.template.php not index.template.php.

Think this is it attached.
Title: Re: How to tighten up mini Profile
Post by: Dzonny on February 26, 2017, 05:28:07 PM
Quote from: Illori on February 26, 2017, 03:12:42 PM
no it is display.template.php not index.template.php.
Hows that so, shouldn't it be index.template where <li class="greeting"> content is?
In attached file, I don't see relevant code that should be removed though, faliro, can you attach index.template.php, just to take a look at it?

I was thinking that this mod is free on our site, and considering it's paid mod we can't see the changes its performing to core code, so can't exactly tell where the code is though.
Title: Re: How to tighten up mini Profile
Post by: faliro on February 26, 2017, 06:09:53 PM
Quote from: Dzonny on February 26, 2017, 05:28:07 PM
Quote from: Illori on February 26, 2017, 03:12:42 PM
no it is display.template.php not index.template.php.
Hows that so, shouldn't it be index.template where <li class="greeting"> content is?
In attached file, I don't see relevant code that should be removed though, faliro, can you attach index.template.php, just to take a look at it?

I was thinking that this mod is free on our site, and considering it's paid mod we can't see the changes its performing to core code, so can't exactly tell where the code is though.

Do you want the index.template on the theme I currently using or the one in 'default' theme (excuse my severe ignorance).
Title: Re: How to tighten up mini Profile
Post by: Dzonny on February 26, 2017, 06:39:21 PM
Your current theme that you're using (on which you're experiencing the problems described in your first message).
Title: Re: How to tighten up mini Profile
Post by: Illori on February 26, 2017, 06:47:29 PM
Quote from: Dzonny on February 26, 2017, 05:28:07 PM
Quote from: Illori on February 26, 2017, 03:12:42 PM
no it is display.template.php not index.template.php.
Hows that so, shouldn't it be index.template where <li class="greeting"> content is?
In attached file, I don't see relevant code that should be removed though, faliro, can you attach index.template.php, just to take a look at it?

I was thinking that this mod is free on our site, and considering it's paid mod we can't see the changes its performing to core code, so can't exactly tell where the code is though.

the issue is in the mini profile right? so that is in display.template.php not in the header. unless we are talking about something other then what i think we are.
Title: Re: How to tighten up mini Profile
Post by: faliro on February 26, 2017, 06:52:23 PM
Quote from: Dzonny on February 26, 2017, 06:39:21 PM
Your current theme that you're using (on which you're experiencing the problems described in your first message).

Here we are:

Title: Re: How to tighten up mini Profile
Post by: Kindred on February 26, 2017, 07:41:02 PM
Illori,   You didn't view the picture .  He didn't mean the in-post mini profile... he means the user info section in the header
Title: Re: How to tighten up mini Profile
Post by: Dzonny on February 26, 2017, 07:46:20 PM
faliro, you attached index.php, while we need Themes/your-theme/Index.template.php file. Please re-check that and upload that file :)
Title: Re: How to tighten up mini Profile
Post by: faliro on February 26, 2017, 07:58:00 PM
Quote from: Dzonny on February 26, 2017, 07:46:20 PM
faliro, you attached index.php, while we need Themes/your-theme/Index.template.php file. Please re-check that and upload that file :)

Appologies: Here we go. Hope this is the one!
Title: Re: How to tighten up mini Profile
Post by: Dzonny on February 26, 2017, 08:33:05 PM
Great, let's try to replace it with this one and see how it goes. Please let us know what happen.
Title: Re: How to tighten up mini Profile
Post by: faliro on February 26, 2017, 08:51:25 PM
Just tried it with a clean cache.
Nothing changed:

(https://i.snag.gy/G1pckY.jpg)
Title: Re: How to tighten up mini Profile
Post by: Dzonny on February 26, 2017, 09:05:21 PM
Oh, gotcha, seems like that br code is from the show_alerts() function, so can't really remove it from this file itself.

What you may be able to do though is to just trick the thing with css, open Themes/yourtheme/index.css file, and add this at the very end of the file:
.greeting br {
    display: none;
}
Title: Re: How to tighten up mini Profile
Post by: br360 on February 26, 2017, 11:47:04 PM
Actually it looks like you have the alerts mods code in the wrong place and that could be the issue you are having. Back up your index.template.php first and then try this-

Find-

<a href="', $scripturl, '">', empty($context['header_logo_url_html_safe']) ? $context['forum_name'] : '<img src="' . $context['header_logo_url_html_safe'] . '" alt="' . $context['forum_name'] . '" />', '</a>

Replace with-

<a href="', $scripturl, '">', empty($context['header_logo_url_html_safe']) ? $context['forum_name'] : '<img src="' . $context['header_logo_url_html_safe'] . '" alt="' . $context['forum_name'] . '" />', '</a>', function_exists('show_alerts') && show_alerts(), '

Then Find-

<li class="greeting">', $txt['hello_member_ndt'], ' <span>', $context['user']['name'], '</span> ', function_exists('show_alerts') && show_alerts(), '</li>

Replace with-

<li class="greeting">', $txt['hello_member_ndt'], ' <span>', $context['user']['name'], '</span></li>

Once agin; back up your file first, just in case
Title: Re: How to tighten up mini Profile
Post by: faliro on February 27, 2017, 05:02:48 PM
Quote from: br360 on February 26, 2017, 11:47:04 PM
Actually it looks like you have the alerts mods code in the wrong place and that could be the issue you are having. Back up your index.template.php first and then try this-

Find-

<a href="', $scripturl, '">', empty($context['header_logo_url_html_safe']) ? $context['forum_name'] : '<img src="' . $context['header_logo_url_html_safe'] . '" alt="' . $context['forum_name'] . '" />', '</a>

Replace with-

<a href="', $scripturl, '">', empty($context['header_logo_url_html_safe']) ? $context['forum_name'] : '<img src="' . $context['header_logo_url_html_safe'] . '" alt="' . $context['forum_name'] . '" />', '</a>', function_exists('show_alerts') && show_alerts(), '

Then Find-

<li class="greeting">', $txt['hello_member_ndt'], ' <span>', $context['user']['name'], '</span> ', function_exists('show_alerts') && show_alerts(), '</li>

Replace with-

<li class="greeting">', $txt['hello_member_ndt'], ' <span>', $context['user']['name'], '</span></li>

Once agin; back up your file first, just in case

Before I try this - wont this just move the alerts away from the profile name. The mod salesman (for want of a better phrase) stated the mod can only go two places - either behind the header or after the user name.  :o
Title: Re: How to tighten up mini Profile
Post by: faliro on February 27, 2017, 05:03:29 PM
Quote from: Dzonny on February 26, 2017, 09:05:21 PM
Oh, gotcha, seems like that br code is from the show_alerts() function, so can't really remove it from this file itself.

What you may be able to do though is to just trick the thing with css, open Themes/yourtheme/index.css file, and add this at the very end of the file:
.greeting br {
    display: none;
}


To the very end of everything - last thing typed?
Title: Re: How to tighten up mini Profile
Post by: Dzonny on February 27, 2017, 06:11:32 PM
Quote from: faliro on February 27, 2017, 05:03:29 PM
Quote from: Dzonny on February 26, 2017, 09:05:21 PM
Oh, gotcha, seems like that br code is from the show_alerts() function, so can't really remove it from this file itself.

What you may be able to do though is to just trick the thing with css, open Themes/yourtheme/index.css file, and add this at the very end of the file:
.greeting br {
    display: none;
}


To the very end of everything - last thing typed?
Yes :)
Title: Re: How to tighten up mini Profile
Post by: faliro on February 27, 2017, 06:29:32 PM
Quote from: Dzonny on February 27, 2017, 06:11:32 PM
Quote from: faliro on February 27, 2017, 05:03:29 PM
Quote from: Dzonny on February 26, 2017, 09:05:21 PM
Oh, gotcha, seems like that br code is from the show_alerts() function, so can't really remove it from this file itself.

What you may be able to do though is to just trick the thing with css, open Themes/yourtheme/index.css file, and add this at the very end of the file:
.greeting br {
    display: none;
}


To the very end of everything - last thing typed?
Yes :)

Hahaha. It worked!

You knew this one would work didn't you!  :laugh:
Title: Re: How to tighten up mini Profile
Post by: Dzonny on February 27, 2017, 07:02:02 PM
Always a pleasure to help! :)