![]() |
Eva, I do not see your .txt file anywhere in these posts that show what you have here:
The Center Links Displaying Actual tables I want to display the actual tables of last 5 posts like you did in http://animeboards.net/index4.php3 Also forgot.. For y our top posters, I did what you have, but how can I put the number of posts next to it like in yours? i.e. : Top 25 Posters ? eva2000 (4571) ? Commander Atomic (3594) ? Oogami Ichirou (3076) ? Ko Hakaisha (2263) ? fireguy (2132) ? Wolfpac (2104) thanks I would really appreciate it if you can post the code for this. Thanks A BUNCH! |
note these were not written by me but techtalk, and others... you're need to include these into the non vb page i.e.
<?php include("/path/to/activetopics.php"); ?> <?php include("/path/topposters.php"); ?> last 5 active topics code: Code:
<? Code:
<?php |
Hi, Eva2000
Can I get http://animeboards.net/index3.php3 source? I couldn't find this source. The source link doesn't exist. Please.... :) |
Eva, I installed successfully the active topics hack, but I see that there is not the last time of update in each thread.
The same updated time in active topics is missing in http://www.animeboards.net Thanks [Edited by sinotto on 12-02-2000 at 02:22 PM] |
I've sort of tidied it up a bit. And mine only displays the news (1st post of thread) from the news forum. If I wanted to do all forums, and mask off I would use forumid != whatever.
I've put the values in variables, which I then use in print(), rather than having to concatenate long strings and using printf() which I don't like. Also a few additions: comment count, user email link. So here goes: Code:
<? |
I'm not sure, but there might be something wrong with the code in the Top Posters code above by eva2000. I keep getting this error message:
Quote:
Code:
echo "<FONT SIZE=\"1\" FACE=\"Verdana, Arial, Helvetica, sans-serif\"> ? |
Actually, I've tried several of the scripts in here, and I get a similar error message each time.
|
Your problem is most probably something completely different, as I found out first-hand.
If you are including theses scripts in home.php for example, then right at the top of home.php, you need to do an include(/homes/whatever/public_html/forum/global.php); if you don't do it, then your passing it a non-existing servername, so it doesn't return a handle, so everything breaks. Please note that if you are using lots of these scriptlets (funny word :)) on one page, then you only need the one include at the top of the page that includes all the scriptlets. Also, if you put the global include anywhere else in the file (ie. not top), you'll get a horrible header error. That's my 2p's worth (UK Sterling you see!) |
OK, thanks! It works now.
Now I have another question: When a user starts a post with no icon, this script tries to display icon0.gif, but because that file doesn't exist, I get a broken-image symbol. Can you write something to insert into the code, and show me what and where, that checks to see if the icon is icon0.gif, and if so, not try to display it? Thanks! |
Did somebody find out how to get the current active users on a non-vB page hack yet?
|
With a little trial-and-error, I've answered my own question. I wrote a little if-else statement that tests if the iconid is 0, and if it is, returns an empty string to a new variable; if it is not 0, an image tag is returned to the new variable.
I also noticed that, at least in Saracen's version, it has a bit at the bottom that is a hyperlink to the thread. The link says "xx comments...", where xx is the number of comments. What I didn't like is that it always says "comments", even if the number is 1, so it would read "1 comments...". I could have changed it to "comment(s)", but I went for a more sophisticated approach. Again, I wrote a little if-else statement, that tests if the number of replies is 1, and if so, returns the text "reply" to a new variable. If it isn't 1, it returns the text "replies" to the new variable. (I changed the word "comment" or "comments" to "reply" or "replies", for my own personal preference.) You can see how both these work below. Note that this has pretty much no formatting, but thanks to Saracen's use of defining variables and calling them in the generated HTML, it is much easier to add whatever formatting you want. Code:
<? This is my first real attempt at making such big changes to a hack for php/mysql. If anyone has any suggestions on improving what I did, I'd love to hear them! :) [Edited by JJR512 on 12-15-2000 at 12:24 AM] |
Well, although that runs fine when I run the file activetopics.php by itself, I seem to be having trouble including it. Sacremen, I stuck that include statement at the top of the main file, tried it various other places, tried it inside the activetopics.php file. I tried it with full absolute path, relative path, or URL to the file global.php. I always seem to get the "Warning: Supplied argument not a valid etc.".
If I put it anywhere inside the activetopics.php file, I get the msg "Warning: Cannot add header information - header already sent etc.". I've also tried it both with the path in the include statement, or with the separate line with the chdir statement. Obviously, I'm missing something. Can you explain it to me, please? Thanks! |
Could somebody help me make 2 hacks like the one's TechTalk made earlier in this thread?
1 for showing the current active users (xx members online... xx guests online...) & 1 for checking if the user has logged in or not, if logged in, then show the "welcome back _____", if not, then show the log in text boxes. Please & thanks a lot ;) |
LOL JJr...you tried too hard with that.....I just made a 1x1 pixel transparent gif and named it icon0.gif and uploaded it into the images/icons folder. :)
|
I considered that option, but decided against it. The reason was that, no matter what size you made the transparent icon, the size of the icon is defined in the image tag, so it gets stretched to full icon size. Well, you might say that doesn't matter, since it's transparent. True, but you do see an empty space. With the way I did it, if there is no icon, the text aligns to the edge of the table cell, rather than to the edge of an empty space. In my opinion, it just looks better.
But I'm still looking for help with the include global.php statement! |
funny, it didn't on our page did it? http://www.friendswithoutfaces.com I don't see blank space where a posting icon would be. We're having trouble with the includes for top 25 posters, too. I can't seem to get it to work. But Kathy's already asked that question. <G>
|
:D
Just call me desparate. I want that TOP 25 POSTERS list on my main page. I think a little competition and reward is a good thing to help encourage posting.... maybe? :lol: Someone help us out? |
OK, I've gotten the results to show up. Now I have another question, about long text strings breaking the tables. Since I have this hack displaying in a table that is only 155 pixels wide, this can be a problem with even a simple URL. Is there a way to force it to split a line apart rather than let the table get wider?
|
Quote:
I dont know the answer but sure hope you get one, I figured I asked enough questions so I wasnt going to ask - I just could not get teh dang thing to work. But if I took the hack for most posts in the last 24 hours it worked fine, and you can change the time to go back a long times and giving you the same results as the top 25 hack - BUT in my case I cant use it because of a wierd glitch somewhere I had to prune a lot of messages and it will not count pruned messages in the persons post count. |
OK, I've gotten it all worked out, with much help from Menno! This time, with the part that Menno added, if there is a URL that is so long that it would stretch the table, you don't have to worry. The part by Menno looks in the message text that would be displayed, and looks for the URL tags, and if it sees it, replaces the text of the hyperlink with the text (hyperlink). For an example, please look at my working test file, http://www.jjr512.com/newer.html
Code:
<? Please note that because I could never get the global.php file to properly include, I just ended up replacing the four variables at the top for server, username, PW, and db name with the actual values. (Of course, I replaced them back before posting it here for you! ;)) |
This took a little figgerin' so I thought I'd post it so others wouldn't have to. This snippet is for non-VB pages, it will show the thread posted within the last 24 hours that has the most views.
If you change $daysback to something else, you can pull from the last week, etc. Code:
require("/full/path/to/admin/config.php"); |
Oh yea.. I also run this piece of code on any thread title I pull-- if it's too long it will truncate it and add ...
Code:
if (strlen($latest_array["title"]) > 40) { |
Hi,
I'm sorry to bring this up now, but I need help. I want to display the ten latest topics on mymessage boards automatically. I read many of the above posts and didn't find exactly what I'm looking for, that's why I'm posting here. I have little knowledge of PHP and MySQL, so don't confuse me too much. :) I want to exclude posts from a few boards and I just wanted to list them on my main page. It is my assumption that if I use a PHP code, I can modify my .htaccess file to read the PHP on my main page and make it not require the .shtml extension to be changed to .php3. Any help would be appreciated. |
Quote:
Code:
AddType application/x-httpd-php3 .shtml Script for Active topics, anumber of people have worked on this including Dark_Wizard. BTW... Has anyone added vB templates to this script, if so could you share or tell me how to do it. Code:
<? |
Is there a way to use an SSI to include this script? Does it have to be called with a php include?
|
Can anyone post the code for displaying currently logged on members in a non-vb page?
Thanks a lot, Jeff Croft newBeetle.org |
All times are GMT. The time now is 09:57 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:
|