This sounds like something that needs to be scripted, and not something you would want to do manually. Seriously.
'Beneath You'
Buffistechnology 3: "Press Some Buttons, See What Happens."
Got a question about technology? Ask it here. Discussion of hardware, software, TiVos, multi-region DVDs, Windows, Macs, LINUX, hand-helds, iPods, anything tech related. Better than any helpdesk!
Scripted...how? I mean, in a program, right? Or not? Well, everything is in a program, isn't it?
It's just 7 lines (I, uh, changed all the pointy brackets to regular brackets because I know the pointy ones break things):
[?xml version="1.0"?]
[!DOCTYPE HWExpress PUBLIC "-//HIGHWIRE//DTD HighWire Express Marker DTD v1.1.2HW//EN" "marker.dtd"]
[HWExpress type="issue"]
[site]pharmther[/site]
[volume]45[/volume]
[issue]6[/issue]
[/HWExpress]
And the "site," "volume," and "issue" lines are indented; I just didn't know how to do that here.
The only thing that ever will change is the issue number (and in Janary, the volume number).
So...how would I script that? (I don't actually know what scripting is.)
When I say "script", I mean, someone writes a small program to automate generating the file, so that you don't have to manually edit the file. But if it's just those seven lines, then it's not a big deal.
First of all, the indentation doesn't matter. Second of all, it's just a text file; you can just edit, and save it as a .TXT file. However, there are a bunch of rules you have to follow to make sure the file is syntactically correct.
However, there are a bunch of rules you have to follow to make sure the file is syntactically correct.
Well, I just copied it verbatim from what they sent us. Would what they sent us be syntactically correct?
Second of all, it's just a text file; you can just edit, and save it as a .TXT file.
They want it to be named "foo.xml," though. Which would be...not a .txt file, right?
I hate them so much.
Well, I just copied it verbatim from what they sent us. Would what they sent us be syntactically correct?
Yes.
They want it to be named "foo.xml," though. Which would be...not a .txt file, right?
You can rename the file to be foo.txt, edit it, and then rename it back to foo.xml when you're done. Alternatively, you can just open the file in TextEdit using the "Open" menu item.
Cool. I'ma try that and see if it works for them.
Thank you SO much. My brain hurts.
They want it to be named "foo.xml," though. Which would be...not a .txt file, right?
In this case, you just need to make the file extension .xml -- it's not one of those file formats that needs to be created by a particular program or anything like that.
If that seven-line doohickey is all they need, I'd just change the digit they want changed in a text editor, save as..., and send them the new one each time. It's true that xml is fussy about having all the tags be exactly right, much more so than html is (for example) -- but don't stress about scripting it. I had the same "don't do it manually" thought at first, but I was imagining them wanting the entire journal marked up as xml rather than what you're actually describing.
Your web service is still totally TINOriffic for not giving you actual help on something like this, ftr.
As I understand it, it would just be that file, only you'd change the volume and issue each time. You can change it in a text editor and then rename it. It is, however, stupid to have you do it.
What are they supposed to be doing for you? Putting your articles into html files?
Your web service is still totally TINOriffic for not giving you actual help on something like this, ftr.
This is, very seriously, about 10% of the problems they're giving us. We normally publish articles online (ahead of the print issue) as they are approved by the authors (post-editing, post-typesetting, etc.), and we publish them every week. We haven't been able to publish articles online for 3 weeks because our Web host has FUBARed our account in an epic way.
Our Big!Boss called their Big!Boss, who actually said "Yup, we dropped the ball in a big way, this is all our fault, we'll make it right for you." And *now,* after 3 weeks, they're finally fixing stuff. (I don't know entirely what was FUBARed, since I don't do anything with the ahead-of-print stuff, other than edit it. I do nothing on the technical/upload-y end for the ahead-of-print stuff. I only prepare and upload the "live' issue [meaning, the whole issue is going to press, and all the articles have actual page numbers and such in them].)
What are they supposed to be doing for you? Putting your articles into html files?
What we do is send them the issue as individual pdfs of each article. They send the pdfs to a conversion vendor who converts the pdfs to html files. (Our Web site offers both a pdf option and html option for online viewing of each article, so they do need the pdfs regardless. We aren't just sending them pdfs in order for the pdfs to be converted.)
The new process is, I think, meant to be more automated on their end. Here is their explanation, verbatim:
A HighWire Express "marker" file is a minimal XML file whose presence in a watched HighWire Express FTP directory triggers automated validation and processing of the journal content accompanying that file. The name of the marker file is always go.xml.
Steph, I use to have to deal with that for pubmed, back when I worked for an environmental health publisher. What people said above should work fine. If you're going to spend a lot of time messing around in xml, you might want to look into BBEdit, which is Mac native and something I really miss, being on a PC these days. BBEdit color codes tags and whatnot, so it's easy to see what bit of code is supposed to do what. Notepad's all well and good, but if you leave off a bracket it doesn't give you a color-coded way to see where it all went wrong. (Although Notepad++ for PC works pretty well. It's still not the same. *sniff*)