?
Solved

Trouble with Matt's Message board

Posted on 1998-06-23
9
Medium Priority
?
371 Views
Last Modified: 2013-12-25
I have set up, with the help of my ISP, the message board located at: http://www.spectech.com/mpulse/techsupp/msgboard/index.html
but as you can see if you go there, and post a message, it is duplicating the replies to every message on the board.  This is the final problem...please help!
0
Comment
Question by:Thorin
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 3
  • 3
9 Comments
 
LVL 2

Expert Comment

by:tpryor
ID: 1829923
need to see the code.
is print getting called twice?
0
 
LVL 6

Expert Comment

by:alamo
ID: 1829924
Looking at that URL, it appears your problem was with data.txt and is now fixed... at least i could post Ok.

If there is still a problem then please describe it more precisely and  post the "# Define Variables" at the top of the file, that should be all we need.
0
 
LVL 2

Expert Comment

by:tpryor
ID: 1829925
I thought Matt's Board was in PERL?
0
Google Certified Professional - Cloud Architect

This course (1 of 3) is designed to help students who are interested in Google Cloud Platform (GCP) to become familiar with the platform, navigate the console and learn its capabilities. It will also prepare students for the Google Cloud Architect certification exam.

 
LVL 6

Expert Comment

by:alamo
ID: 1829926
Yes, it is. The problem seemed to be that the script wasn't able to properly update the data.txt file which tracks the highest message number - every message on the page called the same message file. That seems to now be fixed.
0
 
LVL 2

Author Comment

by:Thorin
ID: 1829927
I don't think the problem is fixed.  Go to the page described above and post a reply to any of the messages and then reload the page.  You can even go and look at what at it did to one I posted this morning from 'Joe Blow'.  It repeats the reply after every message that is on the board.  I hope I am explaining this right.  I think the easiest way to show it is just to  go there and try it.

Here is the # Define Variables:

# Define Variables
$basedir = "/var/www/docs/spectech/mpulse/techsupp/msgboard";
$baseurl = "http://www.spectech.com/mpulse/techsupp/msgboard/";
$cgi_url = "http://www.spectech.com/cgi-bin/wwwboard.pl";
$mesgdir = "messages";
$datafile = "data.txt";
$mesgfile = "index.html";
$faqfile = "faq.html";
$ext = "html";
$date_command = "/bin/date";
$title = "WWWBoard Version 2.0 Test";
# Done

Does that help?

-Thorin
0
 
LVL 2

Expert Comment

by:tpryor
ID: 1829928
not me
0
 
LVL 2

Author Comment

by:Thorin
ID: 1829929
tpryor,

what code did you want to see then?
0
 
LVL 6

Accepted Solution

by:
alamo earned 300 total points
ID: 1829930
I can't get to the board any more since you've installed a password, but I'll explain what I observe hapening.

You originally had a problem with the data.txt file, the file which remembers the highest message number. When a new message is entered the script gets the number from data.txt, adds 1, and writes it back to data.txt. This originally was broken  - probably file rights - but was fixed by the time you posted the URL. I know, because I added a new message last night and replied to myself and it worked fine.

Before data.txt was fixed, the highest message number wasn't being properly saved, so each new message was 1.html and was overwriting the last message. The main page showed all the messages entered but the all linked to the *same* file! (Click on one, you'll see all the links suddenly show visited). When you replied to one of those messages you were replying to the message in 1.html, so in a way you *were* replying to every single message, which is why it showed your reply multiple times.

The solution: use the wwwadmin program to delete 1.html. (Or reinitialize the system and add new messages from scratch). Once all the old test messages are deleted replies will not be repeated.

Good luck!

p.s. tpryor, since the script Thorin is using is a standard script you can get off the net, it wasn't that important to me for him to post all 550 lines of it. All he needed to post was the path and filename customization section, and those look fine.
0
 
LVL 2

Author Comment

by:Thorin
ID: 1829931
Ahhhhhh, you are right!  Looks like my ISP did an end run on me and fixed it.  I just didn't understand until you explained it.  
Thanks
-Thorin
0

Featured Post

On Demand Webinar: Networking for the Cloud Era

Ready to improve network connectivity? Watch this webinar to learn how SD-WANs and a one-click instant connect tool can boost provisions, deployment, and management of your cloud connection.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction This tutorial will give you a fast look what you can do with WhizBase. I expect you already know how to work with HTML at least, and that you understand the basics of the internet and how the internet works. WhizBase is a server-s…
A quick Powershell script I wrote to find old program installations and check versions of a specific file across the network.
The viewer will learn how to look for a specific file type in a local or remote server directory using PHP.
The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…
Suggested Courses

718 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question