TP-Docs
HTML5 Icon HTML5 Icon HTML5 Icon
TP on Social Media

Recent

Welcome to TinyPortal. Please login or sign up.

July 05, 2024, 03:54:44 PM

Login with username, password and session length
Members
Stats
  • Total Posts: 195,298
  • Total Topics: 21,230
  • Online today: 120
  • Online ever: 3,540 (September 03, 2022, 01:38:54 AM)
Users Online
  • Users: 1
  • Guests: 89
  • Total: 90
  • @rjen

[BLOCK] Unanswered Topics Block

Started by shengton, September 26, 2008, 09:26:11 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

JPDeni

Thank you for posting it! Now I can access the topic, but I appreciate your passing on the information when I couldn't.

alhaudhie

One thing..

when i change $number_to_display = 2; // Change this if you want a different number to display. Use 0 to list all of them.

The number 2 to 1 - thats give me soo much topics iin block. not only 1

JPDeni

Rather than using the variables, just use the values in the code:


$query = db_query(
"SELECT m.subject, t.ID_TOPIC
FROM {$db_prefix}topics as t, {$db_prefix}messages as m, {$db_prefix}boards AS b
WHERE t.numReplies = 0
AND t.ID_FIRST_MSG = m.ID_MSG
AND t.ID_BOARD = b.ID_BOARD
AND $user_info[query_see_board]
ORDER BY RAND()
LIMIT 1", __FILE__, __LINE__)

shengton

I have "Reported Posts" and "Reported Messages" sections. All reported posts and messages are included in the block. What code should I add so that it won't be included anymore in the block.

Hope you can help me with this.

Thanks and God bless.

JPDeni

I just looked over the SMF code and when a post is reported to a moderator, nothing is written to the database. If the information isn't stored, it can't be retrieved, so what you're asking for isn't possible without a substantial modification to SMF. That would be beyond my ability.

alhaudhie

tq.. nice work.

How about we add overflow sroll.

Like i want to put 50 posts but i want it show only 5 post. Others 45 post we must scroll it down to look it.

JPDeni

You can probably work out how to do that if you investigate css. Lots and lots of stuff about that on the 'net.

alhaudhie

Can we use like useronline code...

<div style="width: 100%; ' , $online['num_users']>14 ? 'height: 23ex;overflow: auto;' : '' ,'">';

JPDeni


alhaudhie

i try this... but not success...

echo   ' <div style="width: 100%; ' ' <img src="http://tbn0.google.com/images?q=tbn:pQBIIcIWd2dZQM:http://i.pbase.com/u16/sutha/upload/5123820.bullet.jpg" /> <a href="' . $scripturl . '?topic=' . $row['ID_TOPIC'] . '">' . $row['subject'] . 'height: 23ex;overflow: auto;' : >';