![]() |
Later today (hopefully) after I add the code to check if threads or invisible or unavailable to a user. The scenario is possible that a user adds a thread and then loses access to the forum the thread lives in or the thread is moved to a forum the user doesn't have access to.
|
Ok I hacked the hack so that if a thread is "invisible" it will not be shown in the users favorites.
Also it nows checks if a user has access to a thread before showing it in their favorites. The idea is that a user may have added a thread and now has lost access to it for reasons shown in my previous post. The thread isn't actually removed from his/her list but is just not shown to them. This will allow it to "re-appear" to them if they are again given access to it. The thread table is very small as it only contains 3 id fields, the thread id, the id of the folder it goes in (if it has one) and the id of the field itself. Below is my access checking code. My main goal has been as little database access as possible and I believe John needs to do this sort of thing in other places to help the optimization. I could have queried the database for every thread to decide to post it or not but that is bad design and something vB is very guilty of doing. My way of doing it is to build parts of your query using logic and then put your constructed query to work in the main query: Code:
// These usergroups really need to be re-done, this is a nightmare! Let me put in page breaks for long pages and I will be done (which isn't easy as I like to make sure to return you to the page you were on from any function you may access) [Edited by rangersfan on 10-24-2000 at 01:12 PM] |
Ok I do believe the hack is finished. Pageing is in place and no problems so far. Give me time to convert the templates to the proper vB format and I will release it. (My templates are different as I put all the links and graphics in an include file so I can use them across other pages outside the actual forum)
|
glad its working ok :)
|
This is really cool.. I think though that TWTCommish deserves at least partial credit. If at least only for the Idea.. I can use this for another feature I wanted to do as well... Very Very Nice.
|
Wow! This is great! I feel like a kid on Christmas morning waiting to see what the great Rangersfan is gonna bring for presents!
Great job on the hack so far Rangersfan, and thanks for invoking the inspiration TWTCommish...You deserve a great deal of credit indeed. Thanks for making a great product better guys! This hack should definately be looked at for inclusion in the default code. Bravo for the reduction in sql queries as well, mySQL DB would not be able to handle much more than she is. rick |
Please close this thread Ed.
|
Who install this hack ?
i want to see other demo . cos i am worry about editing the database . Thank you :) |
I installed it and it was simple to work.
Not much editing to your database as it adds a few tables. |
Quote:
|
All times are GMT. The time now is 05:04 AM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|