collapse

* Simple Portal Archived Forum

This is an Archive Forum.

The content in this forum may be out-of-date or have been superseded by newer information, and links in forum pages to other sites may not work.
This forum contains archives for future reference.

Visit our thread at Simple Machines Forum for current support.

SMF 2.1 users: EhPortal is a ported version of Simple Portal specifically designed for the SMF 2.1 branch.
Please visit web-develop.ca to download EhPortal and for its support.

* User Info

 
 
Welcome, Guest. Please login or register.

* Who's Online

  • Dot Guests: 368
  • Dot Hidden: 0
  • Dot Users: 0

There aren't any users online.

* Shoutbox

Refresh History
  • Shoutbox is not for support!
  • {OCS}MasterSeal: Yup, Still adore SP
    April 21, 2019, 07:08:06 PM
  • {OCS}MasterSeal: STILL love SP :)
    November 24, 2018, 05:05:50 AM
  • ♦ Ninja ZX-10RR ♦: <3 aegersz
    September 13, 2018, 03:36:09 PM
  • aegersz: I STILL <3 LOVE SimplePortal
    September 13, 2018, 07:11:39 AM
  • aegersz: o LOVE you guys - Simple Portal rocks !
    May 09, 2018, 05:18:59 AM
  • Chen Zhen: our apologies for the site being down.. please read server issues topic
    March 22, 2018, 05:32:38 AM
  • {OCS}MasterSeal: LOL PLEASE forget I just posted that. I found the answer in my own dang post back in 2015. lol sorry!
    July 04, 2017, 10:47:55 PM
  • {OCS}MasterSeal: I know this SB isnt' for support, but I just have a general question. Who would I contact to find out where SP stores its block info? Is it DB driven or files? I searched the site but came up with nothing. probably my fault any insight is appreciated.
    July 04, 2017, 10:43:36 PM
  • ♦ Ninja ZX-10RR ♦: Excuse me but what does Simpleportal have to deal with that?
    February 05, 2017, 08:21:14 PM
  • WhiteEagle: of course IMHO that site appears to be dead :(
    February 04, 2017, 01:08:05 PM
  • WhiteEagle: If I can get that, then I'll use it for that site...
    February 04, 2017, 01:07:35 PM
  • WhiteEagle: decided to not use SMF for any projects, unless I can get a copy of the premium version of the fanfiction archive plugin
    February 04, 2017, 01:06:54 PM
  • expertdecisions: cloudflare
    January 28, 2017, 08:01:47 AM
  • aegersz: SM release 2.0.13 !
    January 12, 2017, 06:00:13 AM
  • raffo: Tks Emanuele, even if I didn't understand the fix :D
    November 07, 2016, 02:01:20 AM
  • emanuele: [link]
    November 01, 2016, 12:43:50 PM
  • emanuele: raffo: the English support board is a good place. ;)
    November 01, 2016, 12:43:38 PM
  • raffo: Where can I find the fix for the shoutbox?
    November 01, 2016, 05:06:09 AM
  • {OCS}MasterSeal: To the SP team, I make a point to come here and thank you as much as possible for your work.  so again, THANK YOU!
    October 28, 2016, 10:38:05 AM
  • emanuele: That's indeed funny, the limit is present only in the patch and not the full install.
    October 22, 2016, 06:14:58 PM

* Recent Posts

Adding Forums Button to Nav bar by jirapon
[August 01, 2019, 09:07:12 AM]


Re: Board Icons by ♦ Ninja ZX-10RR ♦
[July 30, 2019, 04:03:41 PM]


MOVED: Czech translation???? by ♦ Ninja ZX-10RR ♦
[July 30, 2019, 03:04:51 PM]


Board Icons by jirapon
[July 30, 2019, 07:28:44 AM]


Re: Thankyou Simpleportal, by ♦ Ninja ZX-10RR ♦
[July 29, 2019, 09:41:29 AM]

Blocks speak! Do you have an interest in getting more blocks - or even making your own? The Blocks Board is for you!

Author Topic: Title Class and Png  (Read 9832 times)

0 Members and 1 Guest are viewing this topic.

Offline dirtymind

  • Semi Newbie
  • *
  • Posts: 26
  • SMF Version: 1.1.11
  • SP Version: 2.3.1
Title Class and Png
« on: February 10, 2010, 01:04:53 PM »
Hi,
I have a problem about "Default Title Class".

Into the forum, with CSS i have setted borders (top-margin-left-right) for classes (catbg titlebg ecc).
But in Portal this border are differents to my setting in forum.
I don't try where i can set the borders in Portal.

The other question is about image .PNG. I don't find them. I find just .gif, but i try .PNG, like expand and collapse.

Someone who can help me?

Thank you  :D

Offline Nathaniel

  • Comrade
  • *
  • Posts: 5203
  • Gender: Male
    • Verbtest.com
  • SMF Version: 2 RC4
  • SP Version: 2.3.3
Re: Title Class and Png
« Reply #1 on: February 10, 2010, 05:46:17 PM »
Could you please either post a screenshot of your issue or a link to your forum?
SMF Friend (Former Support Specialist) | SimplePortal DeveloperMy SMF Mods | SimplePortal"Quis custodiet ipsos custodes?" - Who will Guard the Guards?Please don't send me ANY support related PMs. I will just delete them.

Offline dirtymind

  • Semi Newbie
  • *
  • Posts: 26
  • SMF Version: 1.1.11
  • SP Version: 2.3.1
Re: Title Class and Png
« Reply #2 on: February 10, 2010, 06:20:51 PM »

Offline dirtymind

  • Semi Newbie
  • *
  • Posts: 26
  • SMF Version: 1.1.11
  • SP Version: 2.3.1
Re: Title Class and Png
« Reply #3 on: February 12, 2010, 06:11:20 AM »
news?  :0

Offline dirtymind

  • Semi Newbie
  • *
  • Posts: 26
  • SMF Version: 1.1.11
  • SP Version: 2.3.1
Re: Title Class and Png
« Reply #4 on: February 15, 2010, 07:36:54 PM »
Nothing?   :'(

Offline [SiNaN]

  • Mr. SimplePortal
  • Developer
  • *
  • Posts: 6782
  • SMF Version: 2.0.15
  • SP Version: 2.3.7
Re: Title Class and Png
« Reply #5 on: February 27, 2010, 05:58:32 AM »
Go to Admin > SimplePortal > Blocks and edit each of yours and set Title Default Class to "catbg". Currently it seems like they are all set to "catbg3".
And slowly, you come to realize... It's all as it should be...

Offline dirtymind

  • Semi Newbie
  • *
  • Posts: 26
  • SMF Version: 1.1.11
  • SP Version: 2.3.1
Re: Title Class and Png
« Reply #6 on: February 27, 2010, 08:14:17 AM »
That's the problem!  :D

Now is setted "catbg3" in Portal, but is not "catbg3" of Forum.

So also "catbg" is not "catbg" of Forum.

Example:

« Last Edit: February 27, 2010, 08:16:20 AM by dirtymind »

Offline dirtymind

  • Semi Newbie
  • *
  • Posts: 26
  • SMF Version: 1.1.11
  • SP Version: 2.3.1
Re: Title Class and Png
« Reply #7 on: March 02, 2010, 05:10:44 AM »
news?

Offline [SiNaN]

  • Mr. SimplePortal
  • Developer
  • *
  • Posts: 6782
  • SMF Version: 2.0.15
  • SP Version: 2.3.7
Re: Title Class and Png
« Reply #8 on: March 09, 2010, 11:58:48 AM »
Change Title Default Class for all your blocks to catbg. Then apply this edit:

Themes/default/portal.css

Code: (Find) [Select]
table.sp_block
{
border-collapse: collapse;
border-spacing: 0;
width: 100%;
}

Code: (Replace) [Select]
table.sp_block
{
width: 100%;
}
And slowly, you come to realize... It's all as it should be...

Offline dirtymind

  • Semi Newbie
  • *
  • Posts: 26
  • SMF Version: 1.1.11
  • SP Version: 2.3.1
Re: Title Class and Png
« Reply #9 on: March 09, 2010, 12:07:56 PM »
it was not necessary, for me, to change in catbg cause i want ctbg3  :D

but it is great! the problem is resolved!  :nervous-happy:

so... it seems that the problem was that "collapse"  :0

anyway..... thank you very very very very much!  ;D

Offline [SiNaN]

  • Mr. SimplePortal
  • Developer
  • *
  • Posts: 6782
  • SMF Version: 2.0.15
  • SP Version: 2.3.7
Re: Title Class and Png
« Reply #10 on: March 09, 2010, 12:09:22 PM »
You're welcome. I'm glad I could be of help. ;)
And slowly, you come to realize... It's all as it should be...

Offline dirtymind

  • Semi Newbie
  • *
  • Posts: 26
  • SMF Version: 1.1.11
  • SP Version: 2.3.1
Re: Title Class and Png
« Reply #11 on: March 09, 2010, 12:24:09 PM »
oh sorry... there is yet the problem for PNG  :0


The other question is about image .PNG. I don't find them. I find just .gif, but i try .PNG, like expand and collapse.

Thank you  :D

Well.... Now it is visibile just a couple of buttons for show/hide blocks.

But I Would 2 couple of buttons, cause i would something like:

at left: the "hide/show left block" button

at right: the "hide/show right block" button

So now instead i have two equal button "show/hide" for both of columns

Offline [SiNaN]

  • Mr. SimplePortal
  • Developer
  • *
  • Posts: 6782
  • SMF Version: 2.0.15
  • SP Version: 2.3.7
Re: Title Class and Png
« Reply #12 on: March 09, 2010, 12:29:31 PM »
Sorry, I missed that.

So you want a single button to hide/show both (left and right) columns?
And slowly, you come to realize... It's all as it should be...

Offline dirtymind

  • Semi Newbie
  • *
  • Posts: 26
  • SMF Version: 1.1.11
  • SP Version: 2.3.1
Re: Title Class and Png
« Reply #13 on: March 09, 2010, 12:40:16 PM »
if it is possibile, yes.

if is not a problem i can link my space so you can better understand that i mean  :nervous-happy:

Offline [SiNaN]

  • Mr. SimplePortal
  • Developer
  • *
  • Posts: 6782
  • SMF Version: 2.0.15
  • SP Version: 2.3.7
Re: Title Class and Png
« Reply #14 on: March 09, 2010, 12:49:17 PM »
Sources/Subs-Portal.php

Code: (Find) [Select]
function sp_collapseSide(id)
{
var sp_sides = new Array();
sp_sides[1] = "sp_left";
sp_sides[4] = "sp_right";
mode = document.getElementById(sp_sides[id]).style.display == "" ? 0 : 1;' . ($context['user']['is_guest'] ? '
document.cookie = sp_sides[id] + "=" + (mode ? 0 : 1);' : '
smf_setThemeOption(sp_sides[id], mode ? 0 : 1, null, "' . $context['session_id'] . '");') . '
document.getElementById("sp_collapse_side" + id).src = sp_images_url + (mode ? "/collapse.png" : "/expand.png");
document.getElementById(sp_sides[id]).style.display = mode ? "" : "none";
}';

Code: (Replace) [Select]
function sp_collapseSide()
{
mode = document.getElementById("sp_left").style.display == "" ? 0 : 1;' . ($context['user']['is_guest'] ? '
document.cookie = "sp_side_collapse=" + (mode ? 0 : 1);' : '
smf_setThemeOption("sp_side_collapse", mode ? 0 : 1, null, "' . $context['session_id'] . '");') . '
document.getElementById("sp_collapse_side").src = sp_images_url + (mode ? "/collapse.png" : "/expand.png");
document.getElementById("sp_left").style.display = mode ? "" : "none";
document.getElementById("sp_right").style.display = mode ? "" : "none";
}';

Code: (Find) [Select]
$context['SPortal']['sides'][$side['id']]['collapsed'] = $context['user']['is_guest'] ? !empty($_COOKIE['sp_' . $side['name']]) : !empty($options['sp_' . $side['name']]);
Code: (Replace) [Select]
$context['SPortal']['sides'][$side['id']]['collapsed'] = $context['user']['is_guest'] ? !empty($_COOKIE['sp_side_collapse']) : !empty($options['sp_side_collapse']);
Themes/default/Portal.template.php

Code: (Find) [Select]
if (!empty($modSettings['showleft']) && !empty($context['SPortal']['blocks'][1]))
echo '
<a href="#side" onclick="return sp_collapseSide(1)">', sp_embed_image($context['SPortal']['sides'][1]['collapsed'] ? 'expand' : 'collapse', '', null, null, true, 'sp_collapse_side1'), '</a>';

if (!empty($modSettings['showright']) && !empty($context['SPortal']['blocks'][4]))
echo '
<a href="#side" onclick="return sp_collapseSide(4)">', sp_embed_image($context['SPortal']['sides'][4]['collapsed'] ? 'expand' : 'collapse', '', null, null, true, 'sp_collapse_side4'), '</a>';

Code: (Replace) [Select]
echo '
<a href="#side" onclick="return sp_collapseSide()">', sp_embed_image($context['SPortal']['sides'][1]['collapsed'] ? 'expand' : 'collapse', '', null, null, true, 'sp_collapse_side'), '</a>';
And slowly, you come to realize... It's all as it should be...

Offline dirtymind

  • Semi Newbie
  • *
  • Posts: 26
  • SMF Version: 1.1.11
  • SP Version: 2.3.1
Re: Title Class and Png
« Reply #15 on: March 09, 2010, 01:24:51 PM »
SiNaN I'm very very afraid....  :'(

I don't mean that....

it is cause my english is very bad....

you have write

So you want a single button to hide/show both (left and right) columns?

and i understand just now....   :(


i try to explain......

now there are 2 png (collpase and expand) and 4 button.

i would 4 different png, so it can show

hide left column
show left column
hide right column
show right column

now it show for right and left columns the same 2 buttons.

and if it is possibile i would the couple of buttons for left column, aligned to left. now both of couple of buttons are aligned to right.....

if there is a problem i canlink my space in PM. i believe tha i can be clearer.

anyway, sorry.... and thank you

Offline [SiNaN]

  • Mr. SimplePortal
  • Developer
  • *
  • Posts: 6782
  • SMF Version: 2.0.15
  • SP Version: 2.3.7
Re: Title Class and Png
« Reply #16 on: March 10, 2010, 04:57:16 AM »
Oh, I see. Revert that back and try this:

Sources/Subs-Portal.php

Code: (Find) [Select]
document.getElementById("sp_collapse_side" + id).src = sp_images_url + (mode ? "/collapse.png" : "/expand.png");
Code: (Replace) [Select]
document.getElementById("sp_collapse_side" + id).src = sp_images_url + (mode ? "/collapse" + id + ".png" : "/expand" + id + ".png");
Themes/default/Portal.template.php

Code: (Find) [Select]
sp_embed_image($context['SPortal']['sides'][1]['collapsed'] ? 'expand' : 'collapse', '', null, null, true, 'sp_collapse_side1'), '</a>';
Code: (Replace) [Select]
sp_embed_image($context['SPortal']['sides'][1]['collapsed'] ? 'expand1' : 'collapse1', '', null, null, true, 'sp_collapse_side1'), '</a>';
Code: (Find) [Select]
sp_embed_image($context['SPortal']['sides'][4]['collapsed'] ? 'expand' : 'collapse', '', null, null, true, 'sp_collapse_side4'), '</a>';
Code: (Replace) [Select]
sp_embed_image($context['SPortal']['sides'][4]['collapsed'] ? 'expand4' : 'collapse4', '', null, null, true, 'sp_collapse_side4'), '</a>';
Then you can have expand1.png and collapse1.png for left side and expand4.png and collapse4.png for right side. We don't have collapse option for top and bottom sides.
And slowly, you come to realize... It's all as it should be...

Offline dirtymind

  • Semi Newbie
  • *
  • Posts: 26
  • SMF Version: 1.1.11
  • SP Version: 2.3.1
Re: Title Class and Png
« Reply #17 on: March 10, 2010, 12:03:57 PM »
Thank you so much!

It is not important for me collapse option for top and bottom side  ;D

Offline [SiNaN]

  • Mr. SimplePortal
  • Developer
  • *
  • Posts: 6782
  • SMF Version: 2.0.15
  • SP Version: 2.3.7
Re: Title Class and Png
« Reply #18 on: March 10, 2010, 02:40:07 PM »
So should I mark this as solved?
And slowly, you come to realize... It's all as it should be...

Offline dirtymind

  • Semi Newbie
  • *
  • Posts: 26
  • SMF Version: 1.1.11
  • SP Version: 2.3.1
Re: Title Class and Png
« Reply #19 on: March 10, 2010, 03:16:43 PM »
So should I mark this as solved?

Yes, absolutely!

Thank You so much!  :D