Return to iWEBTOOL

Go Back   iWEBTOOL Talk > The Web and your Website > Programming > PHP
Register FAQ Members List Calendar Search Today's Posts Mark Forums Read
 
Welcome to iWEBTOOL Talk, where you talk about webmaster-related stuff.
 
Discuss topics which interest you.
With over thousands of threads (topics), we're sure you'll find something that'll interest you.
Ask for help whenever you need it.
We have thousands of members who are available to help you if you need it.
It's absolutely FREE!

 1  Register           2  Browse the board           3  Discuss whatever may interest you!
 


Closed Thread
 
Thread Tools Search this Thread Display Modes
Old 12-05-2007, 12:18 AM   #1
aliks0905
Newcomer
 
aliks0905's Avatar
 
Join Date: Dec 2007
Posts: 1
aliks0905 is on a distinguished road
Default Hide function for forum help needed. :)

Hi, I have modified my code for my modded phpbb forum, and I just have a quick question and if its a possible one.

My hide 'hack' currently is set to hide the hidden content (using [hide] tags) from everybody except: admins/mods, and those with over 50 posts. Is it possible to also add to that exceptions list that if someone is referred from a certain site (google.com) then they can see the hidden content as well?

Here is my code:

Code:
1. if($item['iteration'] > 1) 2. { 3. return $error; 4. } 5. global $db, $topic_id, $userdata, $mode; 6. $show = false; 7. if($userdata['session_logged_in']) 8. { 9. $sql = "SELECT p.poster_id, p.topic_id 10. FROM " . POSTS_TABLE . " p 11. WHERE p.topic_id = $topic_id 12. AND p.poster_id = " . $userdata['user_id']; 13. $resultat = $db->sql_query($sql); 14. $show = $db->sql_numrows($resultat) ? true : false; 15. if ( ($userdata['user_level'] == ADMIN) || ($userdata['user_level'] == MOD) || ($userdata['user_posts'] > 50)) 16. { 17. $show = true; 18. }

Thanks
aliks0905 is offline  
 
This is an Ad Revenue Sharing forum Place your advert here
SEO Checklist
Get yourself better ranking with
our "Do-it-Yourself" SEO Checklist.
Click Here
Old 12-05-2007, 02:35 AM   #2
UnKnown
Moderator
 
UnKnown's Avatar
 
Join Date: Aug 2006
Posts: 1,135
UnKnown is just really niceUnKnown is just really niceUnKnown is just really niceUnKnown is just really niceUnKnown is just really nice
Default Re: Hide function for forum help needed. :)

Im sure you would get a better response at the developers site
UnKnown is offline  
 
This is an Ad Revenue Sharing forum Place your advert here
Webmaster Tools Webmaster Tools Click Here
Closed Thread

(Threads which have no activity for more than 30 days are automatically closed.)



Quick Reply
Message:

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Forum Posters needed for new site. midlandi Web Development 11 11-04-2007 06:30 AM
Javascript: return not in function? justravis JavaScript 4 10-02-2007 04:48 PM
Raising SERP for my forum advice needed drumsoloartist Search Engine Optimization (SEO) 6 08-09-2007 03:26 PM
Forum needed bigger King Gareth Web Development 5 10-22-2006 10:03 PM
Tackle this problem...Function jumpenjuhosaphat PHP 8 07-18-2006 07:33 PM


All times are GMT. The time now is 11:38 PM.


Powered by vBulletin v3.6.7 © 2008, Jelsoft Enterprises Ltd. SEO by vBSEO © 2006, Crawlability, Inc.