News and updates about the River2 aggregator.
I’ve long felt that HTML should have an “include file” mechanism similar to the one that many programming languages have. When I lobbied for it in the early days of the web, the people at Netscape and Microsoft said they feared it would we abused. I didn’t think that was much of an argument because people were copying HTML anyway. View-source was one of the best things about the web. If you wanted to understand how something worked, it was always just a matter of looking to see how they did it.
I wanted to show the members of the Thursday evening group how this works, because we’re going to use this technique in nyblogs.org, to allow us to include the result of the aggregator inside a WordPress blog. But first a simpler example.
Create a text file on your hard disk, and call it test.html. Add this code to the file:
Save it, then drag the file’s icon onto Firefox (or whatever browser you use) and you should see an image on the page. If you click the image it’ll take you to the full version of the page. And if you wait a few minutes and refresh the page, the image will be different.
This is how the random image in the right margin on scripting.com is implemented.
I have a process on one of my servers that generates the randomThumb.js file and puts it in the same place every time. Try entering the URL of the script into the address bar of your browser.
And do a View Source.