I was wondering if someone could help me "reverse engineer" the user block available in Tinyportal. What I mean is that I want to build a custom PHP block and make it similar to the default TP User block, so I need the coding to the default block so I can add it in to my custom one. The only reason I am posting this is because I have no knowledge of the PHP language. However, I have been able to successfully reverse engineer parts of both SMF and TP's coding, and make a working custom User block.
Basically, I am interested in the coding for the TP User block. My main concern at this moment is the coding that will show "Awaiting Activation: x" on the default User block whenever there are un-activated members. I am also interested in the code for the total time logged in counter. I have been able to reverse engineer the rest of the links in the block fortunately.
Thanks.
The userbox block is in the TPSubs.template.php file. You'll find it by searching for "function TPortal_userbox()"
Where is TPSubs.template.php located? I found TPSubs.php in the Sources folder, but it didn't contain the right info. I also looked in the default theme directory, but could not find it.
Edit: I think I found it in TPBlocks.template.php.
Edit: I got it all working. Thanks!
FYI for future reference:
All files that have .template. in them are located in the Themes directory. Most likely the default.
Quote from: darkspreader on March 24, 2010, 08:49:45 PM
Where is TPSubs.template.php located? I found TPSubs.php in the Sources folder, but it didn't contain the right info. I also looked in the default theme directory, but could not find it.
Edit: I think I found it in TPBlocks.template.php.
Edit: I got it all working. Thanks!
Ah... well that code in beta 5 is moved to the file I mentioned. :) Just an FYI for the next version.
Is there a reason this topic is locked? OP marked solved. O0
ZarPrime
Oh sorry. I thought locking the topic was TP's form of solved, haha. I'm used to SMF's forum having a dedicated solved topic button.
Nah, to mark a topic solved we modify the icon on the original post to make it the green checkmark, or you can do it. ;)
ZarPrime
I have to say, TP's support team is a lot more responsive than SMF's. I posted a problem with their phpbb3 to SMF converter, they said that they'll "take a look", but then just ended up saying "we didn't find anything." I had to figure out the problem myself, lol.
Yeah, SMF is going through a rough time right now. Hopefully they can pull out of it and get some more people on the team to help out.