I have tried to turn this into a block and I keep getting a complete mess of information. Or I get the results that I want completely above the block it is very weird. Thanks a bunch.
Code:
<?php
//The line below will actually point to an external source but I
//have put a copy of the file it will be parsing in this location for testing.
$lines = file ('http://myrecoveryna.org/nickplus.txt');
$count = count($lines);
if ($count == 1)
{
echo "Total:<br>".$count." user chatting!";
}
else{
echo "Total:<br>".$count." users chatting!</b>";
}
?>
Eventually I would even like to see the OP characters that are in the text file be parsed out and replaced with corresponding icons like a Speaker instead of + sign for Voiced users, a cops badge instead of @ for Channel Operators, etc. But that is the least of my worries right now. If someone could figure out how to make it show in a Block that would be wonderful.
If anyone know how to do the parse for the replacement of images I would be willing to pay for their time, just let me know if you can do it and what it would cost.
I have to admit that when I first looked at what you said this morning I was a little ticked but now that I think about it a little more, if I am not willing to atleast try and solve the problem myself I am not acomplishing anything in life really. I would just be letting everyone else do it for me.
Using the information found on that page I was not only able to make new block with the information I wanted but I was add the information to the existing login block for the chat room module. So I accomplished more out of reading and understanding than just letting someone tell me the code for me to copy into my page. Thank you for your help!!!
Evaders99 Site Admin
Joined: Aug 17, 2003
Posts: 12397
Posted:
Thu Feb 08, 2007 8:35 pm
Hey, I appreciate it. I know I generally give the most sparse response... but it is for a reason.
Your last statement is absolutely correct. You learn by doing.
We'll be here to answer questions when you get stuck or need to be pointed to a proper path
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum