Rich S Posted November 27, 2006 Posted November 27, 2006 (If this post isn't in the correct forum, Moderator, then please move it there. Thanks!) First, I want to say I'm totally clueless how to do this so if you can provide a simple or technical answer I'll forward it to the Web developer for his analysis. I have an FM-8.0 runtime solution that I want to export data from it to our company's PC-based web server without having someone redirect or convert the data to another form; the process needs to be fully automated. The Web developer sent me the attached form that he would like to have auto-populated with the exported data. The big question is, since I'm on the sending end of things (sending the exported data from the runtime solution), what file format and/or how do I encode the data so it can be popped into his form's fields automatically? As always, I'm very grateful for your help and thank you in advance. Ciao, Rich test_insert.zip
Genx Posted November 28, 2006 Posted November 28, 2006 Okay, first and formost, you may need fm 8.5 to do it directly -- using the web viewer (or some sort of plugin) Secondly, if you are exporting more than one record at a time, ask your web developer why he can not use xml and process it like a normal person
Fenton Posted November 28, 2006 Posted November 28, 2006 I would agree with Genx, that the easiest format for you would be to Export XML, using an xsl stylesheet to transform the native FileMaker export format to whatever arrangement he likes, removing the FileMaker-specific tags. If he doesn't like that, you could also use xml export, with xsl to produce exactly his html file(s). I say files because each form is its own web page (?, if not there's no problem, just do a form for each thing). So, assuming you have lots of whatever this is, you'd need a page-file for each. Then send them all to him (if this is what he wants). There's a few ways to do that. You can't really do one export of a found set of records and get multiple files. But you can create a found set of 1 (in various ways), then do multiple exports of that. Use a script variable to produce a new name for each export as it goes out. Another method, without xml, is to put the raw html into a template global. Then create a calculation field, using Substitute to populate your data per record. Then you can do a Loop, using Export Field Contents (with naming as above). One glitch with Export Field Contents is that it is UTF-16, which doesn't work so well (at present) with web browsers. Not sure how you get around that on Windows.* On my Mac I use a shell script, in an Perform AppleScript step, to write the file. In other words, I don't use Export Field Contents; I just write the file directly as UTF-8, which web browsers are happy with. *I'm sure there's a way, but I'm experiencing pre-coffee brain slippage -|
Wim Decorte Posted November 29, 2006 Posted November 29, 2006 One glitch with Export Field Contents is that it is UTF-16, which doesn't work so well (at present) with web browsers. Not sure how you get around that on Windows. VBscript has no problem reading the exported file. If this is a hosted form and all you need is the data into the HTML form fields then VBscript can take of that too. Or VBscript can "merge" the FM export file into an HTML page if you use placeholders in the HTML. Many options here as you can see, so there's bound to be one that fits nicely with your skill set and that of your web developer.
Recommended Posts
This topic is 6612 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now