views:

26

answers:

1

Company I work for have a site developed 6-8 years ago by a team that was enthusiastic enough to use their own private PHP-based CMS. I have to put dynamic data from one intranet company database on this site in one week: 2-3 pages. I contacted company site administrator and she showed me administrative part - CMS allows only to insert html blocks & manage site map (site is deployed on machine that is inside company & fully accessible & upgradeable).

  • I'm not a PHP-guy & I don't want to dive into legacy hardly-who-ever-heard-about CMS engine
  • I also don't want to contact developers team, 'cos I'm not sure they are still present and capable enough to extend this old days site and it'll take too much time anyway.

I am about to deploy helper asp.net site on IIS with 2-3 pages required & refer helper site via iframe from present site. New pages will allow to download some dynamic content from present site also.

Is it ok and what are the pitfalls with iframe approach?

+3  A: 

This is the second "I'm stuck with a legacy CMS, and fixing it would be too hard" question I've seen here in the last day. I really don't see what the problem is -- I've done this in less than a day:

  1. Pick any modern CMS and see what tools it provides for importing pages. Spend a little time learning how it stores pages. (I chose Wordpress).
  2. Backup the CMS database.
  3. Run a web-spider through the old system and dump all of the pages to disk as plain HTML.
  4. For each page that you saved:
    • Run HTML Tidy on each HTML page to make it more uniform.
    • Run it through sed or perl or write a custom program (say, python with BeautifulSoup) to separate out the page content from the (no longer needed) navigational cruft.
    • Insert the content into a new CMS-managed page (ideally by inserting a new row in the CMS database).
  5. Review the site and manually clean up anything that wasn't caught in the conversion.

A little bit of shell scripting can automate most of this -- just keep refining your scripts until you get most of it 'right'. If you backup the CMS database before you run your script, you can reset the site to 'empty' for each import.

(In my case, the site in question had been in use for ~10 years, with a succession of webmasters, each who used different tools and techniques for managing content, and had been hacked a couple of times by spamvertisers.)

Admittedly, this isn't a science, and it may require you to learn some new tools. Go for it -- learning new stuff is good for you, and you won't have to keep that old server running for the next 10 years, just so you can wrap its content in an iframe.

Craig Trader
Andrew Florko
@Andrew, you might want to try this anyways in your spare time -- like I said, it doesn't have to take a lot of time to do, and a working prototype is a lot easier to get approved than an idea on a whiteboard. Good Luck.
Craig Trader
Prototype is a wonderful idea, it'll help, but what about one week solution? I claim I will migrate site till autumn but not this month :)
Andrew Florko