Support Forum

Advanced Search
Forum Scope


Match



Forum Options



Minimum search word length is 3 characters - maximum search word length is 84 characters
general-topic
Modding question
Avatar
Alex T
Member
sp_UserOfflineSmall Offline
Mar 27, 2015 - 4:47 pm

Would I be able to add the icon in the picture below right where it is?  I changed the way the avatars show to the user who created the post, though that gets rid of when someone posts something new.  Would it be possible to do what I want in this screen shot?  

Image Enlarger

Avatar
Mr Papa
Simi Valley, CA
SP Master
Free Members
sp_UserOfflineSmall Offline
Mar 27, 2015 - 5:52 pm

what do you want to add???  the +1 image?  just the image?

if so yes..  just add another column in your forum view template...

Avatar
Alex T
Member
sp_UserOfflineSmall Offline
Mar 27, 2015 - 7:24 pm

Mr Papa said
what do you want to add???  the +1 image?  just the image?

if so yes..  just add another column in your forum view template...

I want that image to show up there any time someone posts a new message in that thread. 

Avatar
Mr Papa
Simi Valley, CA
SP Master
Free Members
sp_UserOfflineSmall Offline
Mar 27, 2015 - 8:45 pm

that is what we did in the icon that you replaced with the avatar...

my comment still holds, add another column for that icon... you will have to check the unreads your self for displaying similar to what our template tag did... $spThisForum->unreads will give you the number of unread posts...

Avatar
Alex T
Member
sp_UserOfflineSmall Offline
Mar 27, 2015 - 9:02 pm

Mr Papa said
that is what we did in the icon that you replaced with the avatar...

my comment still holds, add another column for that icon... you will have to check the unreads your self for displaying similar to what our template tag did... $spThisForum->unreads will give you the number of unread posts...

The problem is that I really don't know how to do that.  I can follow directions well, but not a coder.  

Avatar
Mr Papa
Simi Valley, CA
SP Master
Free Members
sp_UserOfflineSmall Offline
Mar 28, 2015 - 1:00 pm

in your forum view template file,  you will see something like this:

                                sp_ColumnStart('tagClass=spColumnSection spLeft&width=48%&height=50px');

that starts the column for the topic name...  so just add a new column after that:

                                sp_ColumnStart('tagClass=spColumnSection spLeft&width=6%&height=50px');
                                    if ($spThisForum->unreads > 0) sp_AddIcon('tagClass=spRowIcon spRight&icon=xxxx');
                                sp_ColumnEnd();

where xxxx is the name of the image file you want to display... it will need to be located in your sp theme images folder... 

I havent actually tested this but should get you close...

Avatar
Alex T
Member
sp_UserOfflineSmall Offline
Mar 30, 2015 - 1:36 pm

I tried to figure this out but there's many areas that start with this?

Do I place that somewhere inside of this:

# Column 1 of the forum row
# ----------------------------------------------------------------------
sp_ColumnStart('tagClass=spIconColumnSection spLeft&width=5%&height=0px');
sp_SubForumIndexIcon('tagClass=spRowIcon spLeft');
sp_ColumnEnd();
sp_InsertBreak('tagClass=groupBreak');

# Column 2 of the forum row
# ----------------------------------------------------------------------
sp_ColumnStart('tagClass=spColumnSection spLeft&width=49%&height=0px');
sp_SubForumIndexName('tagClass=spRowName', __sp('Browse topics in %NAME%'));
sp_InsertBreak('direction=left');
sp_SubForumIndexDescription('tagClass=spRowDescription');
sp_SubForumIndexPageLinks('tagClass=spInRowPageLinks spLeft', __sp('Jump to page %PAGE% of topics'));
sp_ColumnEnd();
sp_InsertBreak('tagClass=groupBreak');

# Column 3 of the forum row
# ----------------------------------------------------------------------
sp_ColumnStart('tagClass=spColumnSection spLeft&width=39%&height=0px');
sp_SubForumIndexTopicCount('tagClass=spInRowCount spLeft', __sp('Topics:'));
sp_SubForumIndexPostCount('tagClass=spInRowCount spLeft', '  '.__sp('Posts:'));
sp_InsertBreak('direction=left');
sp_SubForumIndexLastPost('tagClass=spInRowPostLink&order=UTLD&nicedate=0&date=1&time=1&stackdate=0&itemBreak= - ', __sp('Last Post'), __sp('No Topics'));
sp_ColumnEnd();
sp_InsertBreak('tagClass=groupBreak');

Avatar
Mr Papa
Simi Valley, CA
SP Master
Free Members
sp_UserOfflineSmall Offline
Mar 30, 2015 - 9:07 pm

no, thats subforums... you want after forums...  after this

                                # Column 2 of the topic row
                                # ----------------------------------------------------------------------
                                sp_ColumnStart('tagClass=spColumnSection spLeft&width=48%&height=50px');
                                    sp_TopicIndexName('tagClass=spRowName', __sp('Browse the thread %NAME%'));
                                    if (function_exists('sp_TopicDescription')) sp_TopicDescription();
                                    sp_TopicIndexPostPageLinks('tagClass=spInRowPageLinks spLeft', __sp('Jump to page %PAGE% of posts'));
                                    if (function_exists('sp_TopicIndexTagsList')) sp_TopicIndexTagsList('tagClass=spTopicTagsList spButton spLeft', __sp('Tags'), __sp('Show the tags for this topic'));
                                    if (function_exists('sp_TopicIndexTopicStatus')) sp_TopicIndexTopicStatus('tagClass=spTopicIndexStatus spButton spLeft', __sp('Search for other topics with this status'));
                                sp_ColumnEnd();

around line 163...  in that section, you will need to make sure all the column width dont exceed 100%...  the above has a width of 68%..  you should see 5 columns...

Avatar
Alex T
Member
sp_UserOfflineSmall Offline
Mar 31, 2015 - 11:12 am

Is this for Reboot?  Mine looks different?

# Column 2 of the topic row
# ----------------------------------------------------------------------
sp_ColumnStart('tagId=spColForum2&tagClass=spColumnSection spLeft&width=0&height=0px');
sp_TopicIndexName('tagClass=spRowName', __sp('Browse the thread %NAME%'));
if (function_exists('sp_TopicDescription')) sp_TopicDescription();
sp_TopicIndexFirstPost('iconClass=spIcon spLeft&icon=sp_ArrowRightSmall.png&nicedate=0&date=1&time=1&stackdate=0&stackuser=0&stackdate=0&itemBreak= - ', __sp('Started By'));
sp_InsertBreak();
if (function_exists('sp_TopicIndexTagsList')) sp_TopicIndexTagsList('tagClass=spTopicTagsList spLeft&delimiter=|&delimiterClass=spTagsDelimiterForum&collapse=0&iconClass=spIcon', __sp(''), __sp('Show the tags for this topic'));
if (function_exists('sp_TopicIndexRating')) sp_TopicIndexRating('tagClass=spStatusIcon&spRight&skipZero=1');
sp_ColumnEnd();

sp_InsertBreak('tagClass=groupBreak');

Here's how I added the code, however it didn't work.  I put the image in the main Reboot image folder, not in the pack folder.

# Column 2 of the topic row
# ----------------------------------------------------------------------
sp_ColumnStart('tagId=spColForum2&tagClass=spColumnSection spLeft&width=0&height=0px');
sp_TopicIndexName('tagClass=spRowName', __sp('Browse the thread %NAME%'));
if (function_exists('sp_TopicDescription')) sp_TopicDescription();
sp_TopicIndexFirstPost('iconClass=spIcon spLeft&icon=sp_ArrowRightSmall.png&nicedate=0&date=1&time=1&stackdate=0&stackuser=0&stackdate=0&itemBreak= - ', __sp('Started By'));
sp_InsertBreak();
if (function_exists('sp_TopicIndexTagsList')) sp_TopicIndexTagsList('tagClass=spTopicTagsList spLeft&delimiter=|&delimiterClass=spTagsDelimiterForum&collapse=0&iconClass=spIcon', __sp(''), __sp('Show the tags for this topic'));
if (function_exists('sp_TopicIndexRating')) sp_TopicIndexRating('tagClass=spStatusIcon&spRight&skipZero=1');
sp_ColumnEnd();
sp_ColumnStart('tagClass=spColumnSection spLeft&width=0%&height=50px');
if ($spThisForum->unreads > 0) sp_AddIcon('tagClass=spRowIcon spRight&icon=sp_Unread.png');
sp_ColumnEnd();
sp_InsertBreak('tagClass=groupBreak');

 

Avatar
Ike
Sawtry, UK
Member
Free Members
sp_UserOfflineSmall Offline
Mar 31, 2015 - 11:48 am

In Reboot the column widths work differently to allow the columns to use different widths for different mobile / tablet viewport sizes:

The column's in the template have the tagId=spColForumX,

The #Id in the stylesheet references a variable in the overlay:

div#spColForumX { width: <?php echo($ColForum_X[0]); ?>; }

So being as the widths are controlled through the overlay, in whatever overlay you are using - see the variable $ColForum_1[0], $ColForum_2[0] etc.. where [0] is with no media rule applied i.e desktop.

As you can see, all the widths add up to 97%, so if you want to make a new one, copy one of the blocks and rename all to $ColForum_5[0], $ColForum_5[800], $ColForum_5[720] etc..

Then you will want to reduce one of the other columns to make some space, and give $ColForum_5[0], a width.

As Steve said - don't exceed 100%, and try and keep it below 99% if possible.

Forum Timezone: Europe/Stockholm
Most Users Ever Online: 1170
Currently Online:
Guest(s) 1
Currently Browsing this Page:
1 Guest(s)
Top Posters:
Mr Papa: 19448
Ike: 2086
Brandon: 864
kvr28: 804
jim: 650
FidoSysop: 577
Conrad_Farlow: 531
fiddlerman: 358
Stefano Prete: 325
Member Stats:
Guest Posters: 619
Members: 17361
Moderators: 0
Admins: 4
Forum Stats:
Groups: 7
Forums: 17
Topics: 10127
Posts: 79625