News:

SMF 2.1.4 has been released! Take it for a spin! Read more.

Main Menu

View Only Boards

Started by Rudolf, January 31, 2007, 10:45:10 AM

Previous topic - Next topic

Manu.G

Line 70 - 84 of our MessageIndex.template.php

Quote/* The board's and children's 'last_post's have:
            time, timestamp (a number that represents the time.), id (of the post), topic (topic id.),
            link, href, subject, start (where they should go for the first unread post.),
            and member. (which has id, name, link, href, username in it.) */
         if (!empty($board['last_post']['id']))
            echo '
               <b>', $txt[22], '</b> ', $txt[525], ' ', $board['last_post']['protected'] ? '<span class="vob_protected">' . $txt['vob_protected'] . '</span>' : $board['last_post']['member']['link'] , '<br />
               ', $txt['smf88'], ' ', $board['last_post']['protected'] ? '<span class="vob_protected">' . $txt['vob_protected'] . '</span>' : $board['last_post']['link'], '<br />
               ', $txt[30], ' ', $board['last_post']['time'];

            echo '</small>
            </td>
         </tr>';

When I installed the Modification, I got the message "Successful".
Version SMF 2.0.8
SimplePortal 2.3.5

Webbyman

What a fantastic mod!

I had put all my boards hidden but showing on index page (via another mod), but yet wanted that extra SEO of guests/bots being able to enter boards but not the topics/posts. The site had suffered ranking since hidden. I figured bots could still grab the titles of topics and see their links if I could find something to do it!

This mod does exactly that!! Full credit to the author, it's really helped.
Allow access to some, disallow access to others. Brilliant!

Running 1.1.4. Had a few edits to two template files (mainly because board redirect mod interfered on a few lines). So installed via package manager, then updated the two files. After 10 mins of working out how to combine it with another mod (name escapes me, but it's the other that shows the forums as opposed to hidding from guests on index), working exactly how I need it too.

Thanks again, really great mod to have.

Webbyman

Anyway of changing it, so the text isn't red on index page where it's set on boards.
They are also unlinked too, which normally goes to login/register, which is normally handy.

Still a good mod.

Rudolf

You can customize it using the style.css. Read here.

I will update all my mods in the next few weeks. Thanks for your patience.

SVG-Collapse (you need an SVG compliant browser)

Webbyman


andrew peacock

Excellent Mod. Very, very helpful. Great work,
Andy

kermitthefrog

Great mod,
however there's something that doesn't work on my board.
in the admin side I cannot see the ling
QuoteShow the message index for "view only" boards'

I have manually checked all the files and all the modifications are there.
What am I missing?

jamesk

In the default theme, it's under Admin->Features & Options-> (about the 3rd line down, right after allow guests to browse the forum)...

Any thoughts on adding a feature to allow stickied topics to override the visibility?  I want guests to be able to read the stickied topics, but only see the titles of the others...


No.Body

Thanks for this Mod... Awesome!!!

But is there a way that guest wont able to see the topics?

M_rTable

Its good!

But they can only see the boards but not the topics or messages?
I mean a certain membergroup can see the certain boasrds, but them cant see the topics inside cause it says "You are not allowed to see the baord". I wanted them to be able to view the topics but not b able to reply to them

thanks

indonesia

please step by step to apply this mod in custom theme.
thanks
WarnetForum.com using SMF since 2007



M_rTable

Quote from: M_rTable on February 13, 2008, 06:36:06 PM
Its good!

But they can only see the boards but not the topics or messages?
I mean a certain membergroup can see the certain boasrds, but them cant see the topics inside cause it says "You are not allowed to see the baord". I wanted them to be able to view the topics but not b able to reply to them

thanks

ekfaysal

will u update this mod for smf 2 beta 3?

Rudolf

I will update it for smf 2, but probably for the RC or the next beta.
I will update all my mods in the next few weeks. Thanks for your patience.

SVG-Collapse (you need an SVG compliant browser)

cellax

something is not working on my forum, when a user has one or more board on only view, all child boards with new posts are RED written

on BoardIndex.template.php and MessageIndex.template.php
Code (original) Select
$children[] = $child['new'] ? '<b>' . $child['link'] . '</b>' : $child['protected'] ? '<span class="vob_protected">' . $child['link'] . '</span>' : $child['link'];

Code (mine) Select
if($child['protected'])
          $children[] = '<span class="vob_protected">' . $child['link'] . '</span>';

else
         $children[] = $child['new'] ? '<b>' . $child['link'] . '</b>' : $child['link'];


with my code it seems to be fixed

Rudolf

Indeed this is a small bug in the code, thanks for reporting it.

The code should be:
$children[] = $child['new'] ? '<b>' . $child['link'] . '</b>' : ($child['protected'] ? '<span class="vob_protected">' . $child['link'] . '</span>' : $child['link']);

But your code is good too.
I will update all my mods in the next few weeks. Thanks for your patience.

SVG-Collapse (you need an SVG compliant browser)

bassbass

i am getting the red colors too, and when i replaced the code with the one you are showing something went wrong.  maybe i modified the wrong files, where can i find these files, in the default theme?  i am using a default theme 1.1.4

BoardIndex.template.php and MessageIndex.template.php

Thanks

cellax

for me the code is working good, the Rudolf's one.

attach your BoardIndex.template.php and MessageIndex.template.php

Advertisement: