Icy Phoenix

     
 


Post new topic  This topic is locked: you cannot edit posts or make replies. 
Page 1 of 1
 
 
Reply with quote Download Post 
Post Hide Code Request 
 
Hi guys,

I wanted to know if it's possible to set a limit for the reply that needs to be posted in order to see the hiden text?

I want to avoid replies with just a "smiley, or thnx". Can it be done and how if so?

Code: [Download] [Hide]
  1. Sorry, but you must be registered and also must post a reply to view this message. 


thank you in advance
 



 
jzSend private message  
Back to topPage bottom
Icy Phoenix is an open source project, you can show your appreciation and support future development by donating to the project.

Support us
 
Reply with quote Download Post 
Post Re: Hide Code Request 
 
but how can a user post a reply if the post text is hidden?
 



 
z3d0Send private messageVisit poster's website  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Hide Code Request 
 
the whole idea of this is that: if you post say a link to download a movie, you'd like them to thank the poster before they can see that link.

I wanted to make certain users a little more active rather than passive
 



 
jzSend private message  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Hide Code Request 
 
mmm
try this
i''m not sure that this will work  

open BBcode.php

find

Code: [Download] [Hide] [Select]
            if($userdata['session_logged_in'])
            {
                $sql = "SELECT p.poster_id, p.topic_id
                    FROM " . POSTS_TABLE . " p
                    WHERE p.topic_id = $topic_id
                    AND p.poster_id = " . $userdata['user_id'];
                $resultat = $db->sql_query($sql);
                $show = $db->sql_numrows($resultat) ? true : false;
                if ( ($userdata['user_level'] == ADMIN) || ($userdata['user_level'] == MOD))
                {
                    $show = true;
                }
            }


replace with

Code: [Download] [Hide] [Select]
if (  (($userdata['session_logged_in']) || ($userdata['user_posts'] < 200) && ( $userdata['user_level'] = ADMIN && $userdata['user_level'] = MOD ) )
                    {
                    $show = true;
                }


I've set 200 as an example

 
 




____________
? Zuker - EDDB - LPM - Sharefields
 
ZukerSend private messageVisit poster's website  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Hide Code Request 
 
No working..

Parse error: parse error, unexpected '{'
 



 
jzSend private message  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Hide Code Request 
 
woo.. its work
 



 
cubanoSend private messageVisit poster's website  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Hide Code Request 
 
cubano wrote: [View Post]
woo.. its work


where?
 



 
jzSend private message  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Hide Code Request 
 
replace with this ando should work. There was a ( that mustn't be there

Code: [Download] [Hide]
  1.             if(($userdata['session_logged_in']) || ($userdata['user_posts'] < 200) && ( $userdata['user_level'] = ADMIN && $userdata['user_level'] = MOD ) )  
  2.             {  
  3.                     $show = true;  
  4.             } 

 




____________
? Zuker - EDDB - LPM - Sharefields
 
ZukerSend private messageVisit poster's website  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Hide Code Request 
 
Fixed the error, but I can still post a single letter  and the text is not hidden anymore..
 



 
jzSend private message  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Hide Code Request 
 
($userdata['user_posts'] < 200)

there you set the ammount of post needed to show the code
 




____________
? Zuker - EDDB - LPM - Sharefields
 
ZukerSend private messageVisit poster's website  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Hide Code Request 
 
I understand that,

but if you at the code you suggested changing is a little longer than the one you replaced it with..  

I'm sure there's a way, but I'm not that good at php.  
 



 
jzSend private message  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Hide Code Request 
 
i don't understand what you say jz
 




____________
? Zuker - EDDB - LPM - Sharefields
 
ZukerSend private messageVisit poster's website  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Hide Code Request 
 
hahaha,

sorry... my fingers are not keeping up with my brain

I was trying to say if you look at the part of the code you said to change is longer than the code you said to replace it with, so that's why I think is not working.  any other ideas
 



 
jzSend private message  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Hide Code Request 
 
yes this is exactly what i want....
 



 
fidundergroundSend private message  
Back to topPage bottom
Post new topic  This topic is locked: you cannot edit posts or make replies.  Page 1 of 1
 


Display posts from previous:    

HideWas this topic useful?

Link this topic
URL
BBCode
HTML




 
Permissions List
You cannot post new topics
You cannot reply to topics
You cannot edit your posts
You cannot delete your posts
You cannot vote in polls
You cannot attach files
You can download files
You cannot post calendar events