Latest Topic on front page

Started by gffb, 10 years ago

previous topic - next topic

0 Members and 1 Guest are viewing this topic.

gffb

*
10 years ago
Hi Fel,

Where is the code for the latest topic that you have on your front page please :)

Thank you for a great portal.

Feline

*
#1
10 years ago
Board news?  ::)

Fel
Many are stubborn in relation to the way, but less in relation to the target.

gffb

*
#2
10 years ago
Thanks but I have tried this block and no posts are showing?

I have set it to use a board that does have posts in it?
Number of posts to show 10? but still no topics shown?

gffb

*
#3
10 years ago
any ideas on why this is happening?

gffb

*
#4
10 years ago
Used this code.
Code Select

$return=ssi_boardNews(6,10,null,null,'');

foreach ($return as $news)
{
  echo '
     <div>
<a href="', $news['href'], '">', $news['icon'], '<b>', $news['subject'], '</b></a>    <div class="smaller">', $news['poster']['link'], ' - ', $news['time'],'
</div>
     </div>';

  if (!$news['is_last'])
     echo '
     <hr style="margin: 2ex 0;" width="100%" />';
}



That board has 8 topics in it but none of them show up in the block on the front page

Just to clarify I have attached an image of what I am looking for, something that will list the first x number of topics froma board I choose

[attachment deleted by admin]

gffb

*
#5
10 years ago
Quote from: mmostafayousef, 10 years ago
That is the Bord News block. But it is showing the topics in 2 columns which is an option that you can set in the Board News Block.

Thank you but as you can see from my earlier reply I have tried this block but no previous topics are being shown, the board has about 10 topics in it but when I turn on board news and select that board to show topics from none are being shown.

Feline

*
#6
10 years ago
Only boards with Guest access you can use for ssi_boardnews ...

Fel
Many are stubborn in relation to the way, but less in relation to the target.

gffb

*
#7
10 years ago
Quote from: feline, 10 years ago
Only boards with Guest access you can use for ssi_boardnews ...

Fel

Ok this  must be why the topics are not showing even if signed in. Is there a work around so it will work on private/non guest boards?

Feline

*
#8
10 years ago
Please post this question to the SMF Forum ..
I have posted that long time ago, but the answer was .. "works as designed"  :(

Fel
Many are stubborn in relation to the way, but less in relation to the target.

gffb

*
#9
10 years ago
I have done so, and await their reply.

Thanks for the support

gffb

*
#10
10 years ago
Just to give you an update I have found the following temp fix while waiting for SMF to reply.

In SSI.PHP I just commented out the follwing.
Code Select
// Make sure guests can see this board.
//$request = $smcFunc['db_query']('', '
//SELECT id_board
//FROM {db_prefix}boards
//WHERE ' . ($board === null ? '' : 'id_board = {int:current_board}
//AND ') . 'FIND_IN_SET(-1, member_groups)
//LIMIT 1',
//array(
//'current_board' => $board,
//)
//);
//if ($smcFunc['db_num_rows']($request) == 0)
//{
//if ($output_method == 'echo')
//die($txt['ssi_no_guests']);
//else
//return array();
//}
//list ($board) = $smcFunc['db_fetch_row']($request);
//$smcFunc['db_free_result']($request);

* Shouts

Feline
7 months ago
Today we update our Forum to the Version 1.45
Feline
10 months ago
Today we update our Forum to Version 1.4
This release is full compatible with the EU GDPR
Feline
a year ago
Update for PortaMx 1.54 ecl released.
With this updates the Portal works with PHP 7.x and SMF 2.0.15
Feline
a year ago
PortaMx Forum 1.3
released !

*
Feline
a year ago
Today we switched to PHP 7.2 and activate Opcode caching.
Fast .. Very fast *
Feline
2 years ago
Today we upgrade our old SMF 2.0 Forum to PortaMx Forum *

* Calendar

Su
Mo
Tu
We
Th
Fr
Sa
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
HolidaysApr 22: Earth Day (en)
Apr 22: Ostermontag (de)