Pulling Drupal content to normal .shtml webpage

Events happening in the community are now at Drupal community events on www.drupal.org.
amax's picture

Hi Everyone,
We have used drupal for blogging and a forum for our local newspaper site (drupal 6) and I have finally got the editors to start posting in it, but problem is we ONLY use it for blogging and a forum. Our weekly newspaper news gets updated on a plain .shtml website by a third party. Is it possible to pull the content e.g. Daily blog post from the drupal site and have it automatically appear within a DIV on the static .shtml pages of the original. I was thinking I could do this possibly in some way with the RSS feeds but maybe this isnt the way to go. Would love some advice here if anyone has done it before with their newspaper. I dont think I will ever be able to make the full switch to drupal for all the news sections but as the editors are getitng more comfortable with it, its really starting to kick off

Comments

Just save the page?

eli's picture

Well, all the content is "static" when it leaves the web server, so if you can set up a page in Drupal to look exactly the way you want the .shtml, you just have to set up a script to save that file. In UNIX-type servers, you can use the curl command like:

sounds cool

amax's picture

Eli, thanks a million for getting back to me. This sounds cool but im but am totally clueless when it comes to unix / linux. That curl command looks powerful stuff though, looked it up and read all about it.
In the meantime, Ive had great success following tutorial at www.lib.umich.edu/tools/feed2js.html. Its gave me exactly the result I needed on my static site and only took me about ten minutes if anyone else is trying to do the same. I have given one of the editors of the newspaper his own blog and just using the feed from that to power the front page of the static site for now
I wish they would just let me switch the whole thing over to drupal though. If anyone else can recommend anything else cool I can do with the drupal feed please let me know

Module

coderintherye's picture

One possible solution is a module I've written that saves Drupal nodes into static pages using FTP. I'm still waiting for it to get approval, so if you would like a copy then send me a message. You can just adjust the surrounding html tags in the module code to whatever you want your page to look like. Currently, it works by clicking a save to ftp button, but I wrote another code snippet that will automatically export the page as well if you want.

Drupal evangelist.
www.CoderintheRye.com

excellent

amax's picture

sounds excellent anarchman, would love to play with these. Will PM you

Just to note

coderintherye's picture

This project is now published at http://www.drupal.org/project/savetoftp It works as is, but still could use some comments and such to refine it and make it better.

Drupal evangelist.
www.CoderintheRye.com

As it just so happens...

chrisyates's picture

This was the same situation I dealt with at McClatchy. Our main CMS used cached pages generated from a perl/mason/mysql app, and for everything dynamic, we used Drupal.

There are a number of javascript tools for ingesting RSS feeds, including jQuery plugins. When I left McClatchy, we were using a PHP feed parsing tool to transform feeds into javascript, but now they're using jquery.jfeed.js.

For other dynamic elements, we used JSONP to deliver content from Drupal and ingested with jQuery. See the carousels on beaufortgazette.com.

I also developed a module to associate Drupal nodes with stories on a 3rd party site/cms, but I've never bothered to update it to 6.x.

Newspapers on Drupal

Group organizers

Group categories

Topics - Newspaper on Drupal

Group notifications

This group offers an RSS feed. Or subscribe to these personalized, sitewide feeds: