Web Analytics Made Easy -
StatCounter html page to update news scroller content - CodingForum


No announcement yet.

html page to update news scroller content

  • Filter
  • Time
  • Show
Clear All
new posts

  • html page to update news scroller content

    I'm lost...
    I have a Java news scroller that pulls content from an html page. code format looks like this:
    <table border="0" cellpadding="2" style="border-collapse: collapse" class="scroller"  >
    		<hr width="80%" size="1">
    <p align="center">"The difference in Martial Arts" 
    <p align="justify"><span style="font-size: 8pt">This scrolling news wire will have tournament listings,
    promotion test dates, and any other updated information related to our Schools.
    An easy way to quickly see what is going on not only on this site but at each location. If you have news that you 
    would like posted on this crawler feel free to email the webmaster!</p>
    <p align="justify"><span style="font-size: 8pt">Chung Ma's Taekwondo Tournament Saturday, Nov 11 2006
    at John F. Kennedy High School in Somers, New York...<br> See the Events page for more info</p>
    <p align="justify"><span style="font-size: 8pt">Black Belt Promotion Test at the Mahopac School Saturday,
    Oct 21 2006...<br> See the Events page for more info</p>
    <p align="justify"><span style="font-size: 8pt">Color Belt Promotion Test Friday, Nov 17 2006
    for the Kingston Chung Ma's Students...<br> Test starts at 5:30PM</span></font></td></p>
    I would like to create an html page where other users could update or edit this content, with something nicer than just editing the raw code. I have no idea even where to start; can some one give me some guidance? I'm not even sure if this needs some sort of server side stuff!

  • #2
    I dont know what server side scipting programs you have on your server, but when you have found out go to the relavent forum and post this question. Because you will need a form to allow your users to edit the news then a script to process it and convert it to raw text. You will need a file handling procedure that rewrites the html page with the new content. I dont know if you are considering a comment system or a just edit system or even want to allow users to add new news item. Each will have differnet implications on your design. Hope this helps
    You can not say you know how to do something, until you can teach it to someone else.


    • #3
      Hey TimGolding,
      yup, questions by the millions...
      Our server side supports just about everything current (cgi,perl,php,etc.), so I suppose any one will perform satifactory. I was thinking along the lines of allowing authorized users to go to this page and enter/delete/edit new bits directly; but after some thought this may not be such a good idea. Perhaps having them email me the news and then posting it would be better. Gives a little more control over what actually shows up! What do you think?


      • #4
        Sounds easier that way you can moderate it. I dont know how your Javasrcipt code works, what I would do is store the news items as standard text files and write a little code to display them independently. You could store or your news items in a folder with your doc root and name each news txt file cronilogically. You would then need a script to count all the files in the folder and store the paths in some sort of array or something. You would need a paging system to show the news items in cronoligical order and show a set amount per page. Finally a file handler to read all appropriate news files for current page and eacho back the text. If I was doing this I would have a readmore link.
        You can not say you know how to do something, until you can teach it to someone else.