Headlines displayed on all pages

  mackaycc 20:00 08 Jun 2004

On my site I am hoping to put the latest headlines on each page which when clicked would take the user to the news page (I don't need each headline linking to a new page). However, I would like this to pick up the headlines from another file so I only have to keep the one file updated.

What would be the best solution for this? Would I be best using an iframe in my pages or would I be better off using javascript to read the file and display the headlines? If neither of these seem viable, does anyone have any other suggestions of how I could do it?

Any help greatly appreciated.

  Baledor 09:18 09 Jun 2004

to read a text file, if you do a search on the web there are quite a few freely available scripts which would achieve this for you.

  Taran 12:25 09 Jun 2004

If you have PHP support I'd opt for a PHP solution.

There are lots of readily available PHP scripts that do this sort of thing, but I'm a bit at a loss as to why you'd want to manually assign a textfile to the system to read from. Most such systems run off an information feed, often leveraging an RSS feed from a news site.

Have a look at these links:

click here

click here

click here

They will give the an idea of what you can do, but you don't say what sort of headlines you want to present.

If it is current news and affairs there are ways and means of integrating this into your site but I always suggest that people stay clear of JavaScript where possible. If your visitor has JavaScript disabled or not even installed they won't be able to use your system and some browsers will fail to process the script properly even with JavaScript installed. This is a bugbear with JavaScript - it's great when it works but you can never guarantee its results because of browser problems.

This thread is now locked and can not be replied to.

Elsewhere on IDG sites

Xiaomi Mi Mix 2 review

See mcbess's iconic style animated for Mercedes-Benz

iPhone X news: Release date, price, new features & specs

Black Friday 2017 : date, sites participants & bonnes affaires