Author |
Message |
stag
New Member
![New Member New Member](modules/Forums/images/ranks/1star.gif)
![](modules/Forums/images/avatars/gallery/blank.gif)
Joined: Jan 12, 2004
Posts: 22
|
Posted:
Thu Apr 29, 2004 11:32 am |
|
Hi,
Can anyone help me with this silly issue, i want to limit the number of characters in $topic_title in the center forum block to 15, but don't have php knowledge to do that |
Last edited by stag on Mon Sep 27, 2004 10:12 am; edited 1 time in total |
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
Raven
Site Admin/Owner
![](modules/Forums/images/avatars/45030c033f18773153cd2.gif)
Joined: Aug 27, 2002
Posts: 17088
|
Posted:
Thu Apr 29, 2004 1:29 pm |
|
This is just on the fly. After this line of codeCode:$result = sql_query( "SELECT topic_id, forum_id, topic_last_post_id, topic_title, topic_poster, topic_views, topic_replies, topic_moved_id FROM ".$prefix."_bbtopics ORDER BY topic_last_post_id DESC", $dbi );
while( list( $topic_id, $forum_id, $topic_last_post_id, $topic_title, $topic_poster, $topic_views, $topic_replies, $topic_moved_id ) = sql_fetch_row( $result, $dbi ) )
| add this lineCode:$topic_title = substr($topic_title,0,15);
|
|
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
stag
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Thu Apr 29, 2004 1:51 pm |
|
Sorry raven, its not working!
It is showing a blank center forum block. No errors are shown although |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
Raven
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Thu Apr 29, 2004 2:49 pm |
|
Sorry. Place that line of code after thisCode:while( list( $topic_id, $forum_id, $topic_last_post_id, $topic_title, $topic_poster, $topic_views, $topic_replies, $topic_moved_id ) = sql_fetch_row( $result, $dbi ) )
{
|
|
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
stag
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Mon May 17, 2004 4:47 pm |
|
Hi raven, just another help required from your side.
Can you tell me how to make the above center forum block specific to only one category of the forums, i mean so that it shows last ten posts from only one category of forums in all the forums. Your help will be greatly appreciated. |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
stag
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Thu Jul 01, 2004 2:06 am |
|
Hi Raven,
Can you please tell me how to skip the displays from one particular forum in the above script. I want to hide the posts of a single forum (say forum id=1) in the output of the the centre block.
Your help will be appreciated (as always) |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
Raven
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Thu Jul 01, 2004 4:58 am |
|
Assuming this is your select statement[coe]$result = sql_query( "SELECT topic_id, forum_id, topic_last_post_id, topic_title, topic_poster, topic_views, topic_replies, topic_moved_id FROM ".$prefix."_bbtopics ORDER BY topic_last_post_id DESC", $dbi );[/code]change it toCode:$result = sql_query( "SELECT topic_id, forum_id, topic_last_post_id, topic_title, topic_poster, topic_views, topic_replies, topic_moved_id FROM ".$prefix."_bbtopics where forum_id != 1 ORDER BY topic_last_post_id DESC", $dbi );
|
|
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
neophite
Regular
![Regular Regular](modules/Forums/images/ranks/2stars.gif)
![](modules/Forums/images/avatars/Risque/fhf247.jpg)
Joined: Sep 13, 2003
Posts: 56
Location: Virginia
|
Posted:
Thu Jul 01, 2004 10:36 am |
|
I am having a problem with one of my websites showing the recent forum posts on the center block of my main page, I would like to be able to use fiapple recent forum posts block, but it only works on one site and on the other site it only shows the header and frame but NO posts (even your collapsing forums block doesn't show any entries, which worked before).
This is something that I have just decided to run on my websites, in the past couple of days. Each of the various recent forum blocks that I have tried that came with RAVEN's 7.0 distribution (with the exception of the one that currently is working) displays only the frame work and header without any post entries.
I currently am using one of the other forum post blocks in your 7.0 distribution, which works fine...but I rather like the fiapple display better.
What am I missing? I haven't made any changes to my websites.
http://www.bobmiedema.com - fiapple forum post works fine!
http://www.gastricbypasslongtermliving.com - only one forum block displays entrys. |
_________________ Warmest Regards,
Bob Miedema |
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
stag
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Thu Jul 01, 2004 4:02 pm |
|
Thanks raven, it worked like magic! It helped me getting rid of the headache i was getting for past one month in sorting this problem.
Another little request if you have time, can i use a similar hack to show the output of only one forum, say forum id = 1 |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
stag
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Thu Jul 01, 2004 4:08 pm |
|
thanks, i sorted that out myself!
You are educating me well! ![Cool](modules/Forums/images/smiles/icon_cool.gif) |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
stag
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Thu Jul 01, 2004 4:17 pm |
|
now another problem has risen, how to block the output of two forums in center block? |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
Raven
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Thu Jul 01, 2004 5:48 pm |
|
The same principleCode:$result = sql_query( "SELECT topic_id, forum_id, topic_last_post_id, topic_title, topic_poster, topic_views, topic_replies, topic_moved_id FROM ".$prefix."_bbtopics where forum_id NOT IN(1,5) ORDER BY topic_last_post_id DESC", $dbi );
| Of course the 1 and 5 are only examples. |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
stag
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Thu Jul 01, 2004 6:36 pm |
|
please teach me some more,
what if i want to show the output of only two forums? can i use
Code:where forum_id IN(1,5)
|
|
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
Raven
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Thu Jul 01, 2004 6:45 pm |
|
Yes my little weed-hopper ![Image Image](http://www.ravenphpscripts.com/images/mylinks/sifuswordthumb2.jpg) |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
stag
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Mon Jul 19, 2004 6:38 pm |
|
Hi Raven,
Sorry about my obsession with this center forum block, but can you please tell me how to convert this block into a module.
I have added the required code on top and bottom of this block and put it into module/forum/index.php but it is still showing a blank page in middle. |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
stag
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Wed Sep 08, 2004 2:23 am |
|
Hi Raven,
You have been great help in solving my queries above and teaching me some new aspects of php (anyways i am blank for any script including php)
I have been trying to limit the above center forum block so that it shows only the posts which has recieved n (say 10) number of replies. I have been trying for over a week now but with no success. I should admit here that i am still as ignorant as i ever was, so I came back once again to ask you for some more help. Please.
I realise that i am being a pest here, so i will make a contri to speed up ur donateometer.
Thanks |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
stag
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Thu Sep 09, 2004 1:16 pm |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
Raven
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Fri Sep 10, 2004 6:55 am |
|
Can you post your code as it stands right now? |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
stag
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Fri Sep 10, 2004 7:05 am |
|
well, thanks raven |
Last edited by stag on Mon Sep 27, 2004 10:11 am; edited 1 time in total |
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
stag
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Fri Sep 10, 2004 7:08 am |
|
I was trying that the only the popular topics i.e. the topics with "x" number of replies should be shown in this block. |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
stag
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Mon Sep 13, 2004 8:27 am |
|
Raven wrote: | Can you post your code as it stands right now? |
I have tried again to hack the code this weekend, but no success ![Sad](modules/Forums/images/smiles/icon_sad.gif) |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
stag
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Wed Sep 15, 2004 11:47 am |
|
Raven wrote: | Can you post your code as it stands right now? |
please |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
Raven
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Wed Sep 15, 2004 11:54 am |
|
It's on my list but I haven't gotten there as of yet. |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
paradox_h2o
New Member
![New Member New Member](modules/Forums/images/ranks/1star.gif)
![](modules/Forums/images/avatars/gallery/blank.gif)
Joined: Oct 20, 2007
Posts: 8
|
Posted:
Tue Oct 30, 2007 7:36 am |
|
When people make Forum Posts where they copy & past from another source........the whole post shows in the preview.....but when the message finally posts....it only shows the first few sentences...then the rest is cut off........
this has happened to me on the previous versions of nuke also...and it also happens on the universal module.....
does anyone know what is causing this???? And odes anyone know how to fix it? |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
horrorcode
Involved
![Involved Involved](modules/Forums/images/ranks/4stars.gif)
![](modules/Forums/images/avatars/gallery/blank.gif)
Joined: Jan 17, 2009
Posts: 272
Location: Missouri
|
Posted:
Wed Apr 15, 2009 5:57 pm |
|
Nevermind on the question I went ahead and did this:
Code:
$title = stripslashes($title);
$title2 = substr($title,0,37);
|
That way I can still use the first output...
edit: sorry i didnt notice this was originally 5 years old, can someone split this out for me... |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
|