If I understand your problem, you just want to have a single file on your server that will open in the popup window, and you want to be able to tell that file which news story to "include" into itself.
If you had a file called: "top_story.html" that you wanted to open in the popup window, and you wanted that file to include a news story content file called "story3.html" then first, you could reference the "top_story.html" file like this:
top_story.html?story=story3.html
In your javascript function call, it would look like this:
javascript:openAWindow('news/top_story.html?story=story3.html','top_story',500,500,1)
Now, assuming that the two files were in the same directory (recommended for simplicity) you could put a PHP include statement like this within the <body> tag of "top_story.html"
<? include($story); ?>
This would include the file "story3.html" into the "top_story.html" file at the spot where you had the include statement. So, you see that be adding "?story=story3.html" to the page name, we are basically creating a variable called "$story" with a value of "story3.html". So you can do whatever you want to that variable... use and abuse it! 🙂
Now, if you want to include files into "top_story.html" that are in a different directory than top_story.html" (such as a directory called "news" sitting in the root of the web site) your include statement should probably look like this:
<? include($DOCUMENT.ROOT."news/$story"); ?>
If that doesn't work, then you should use this:
<? include($DOCUMENT.ROOT."/news/$story"); ?>
Note that those two are exactly the same except that the second one contains a slash in front of "news". Whichever one you use just depends on how Apache is configured, but it's no big deal. Generally, the 1st one will be more common, but neither is incorrect. the "$DOCUMENT_ROOT" variable is just a global PHP constant that equates to the root directory of your website from the SERVER root. On some servers it will have a slash at the end, and on others it may not.
I hope that helps! This is really one of the most powerful, easy concepts that you can put to use immediately. Good luck!
-THEO-