samrtronik Posted July 6, 2009 Share Posted July 6, 2009 This is my first post, though I have been coming here for a while now.... I'm really hoping someone might be able to help out.. I am almost certain this isn't going to be possible, but here is what I am trying to do: I have a php page which creates XML. If a parameter is passed to the php page (csv=1) then the page includes this: if ($useCSV == 1) { $xml .= "<?xml-stylesheet type=\"text/xsl\" href=\"makecsv.xsl\"?>\n"; } This formats the page as though the data were a CSV file, and they want to create a cron script which gets the data, parses it using simple tools like GREP and automatically updates a page on their Wiki. We are trying to use WGET to pick up the CSV but as XSL is browser based WGET just returns the XML. In a browser of course, the page looks like a nicely formatted CSV. My next stop is just to create another page which just returns CSV data, but it would be nice to use something like this if possible. Is there such a thing as server side CSS?! Any ideas? Quote Link to comment Share on other sites More sharing options...
rhodesa Posted July 6, 2009 Share Posted July 6, 2009 No, I don't think that is possible. But, can they modify their scripts to just parse the XML? Quote Link to comment Share on other sites More sharing options...
samrtronik Posted July 6, 2009 Author Share Posted July 6, 2009 Thanks for the speedy reply. I think they have already started to edit their scripts so this is now hopefully not an issue. I would be surprised if this hasn't come up for someone before. It would make scripting easier, although I presume most systems now expect XML. Maybe if there was a parameter to wget (a bit like the -f) to allow csv parsing.... Quote Link to comment Share on other sites More sharing options...
samrtronik Posted July 6, 2009 Author Share Posted July 6, 2009 I just found this on the wget forums: 5.2. Can Wget download links found in CSS? Thanks to code supplied by Ted Mielczarek, Wget can now parse embedded CSS stylesheet data and text/css files to find additional links for recursion. This feature is not yet in any official release, it's in the development sources only. The support for this feature will be available in Wget release version 1.12. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.