View previous topic :: View next topic |
Author |
Message |
silicondale
Joined: 15 Mar 2007 Posts: 252 Location: Matlock, Derbyshire, UK
|
Posted: Tue Jun 14, 2011 9:49 pm Post subject: Fortran programs for web server |
|
|
I have decades of experience of Fortran programming. I also have plenty of website development experience includig ASP scripting and database access. What I want to do now is make Fortran programs available over the Internet via a web site, with user supply of parameters presumably through a form (using the 'POST' convention?), and output of results back to the user in text and graphical forms. There will also be I/O using files on the web server.
I haven't the slightest idea how to go about this. What I/O streams would I use, and how would these be attached to the necessary ports on the web server?
Will I need to use the Visual Studio .NET version or can I build stand-alone Fortran programs? Is it possible to use Clearwin+ ?
Thanks in advance for any advice. _________________ (Steve Henley) |
|
Back to top |
|
 |
JohnHorspool
Joined: 26 Sep 2005 Posts: 270 Location: Gloucestershire UK
|
Posted: Tue Jun 14, 2011 11:16 pm Post subject: |
|
|
Steve,
Have you looked at the link Dan posted in
"Posting realtime data (graph) on the net" here on 21st May 2011 ? _________________ John Horspool
Roshaz Software Ltd.
Gloucestershire |
|
Back to top |
|
 |
silicondale
Joined: 15 Mar 2007 Posts: 252 Location: Matlock, Derbyshire, UK
|
Posted: Wed Jun 15, 2011 9:11 am Post subject: Fortran on the web |
|
|
Hi John - many thanks. I hadn't found that link on the Silverfrost forum, but I did subsequently find it by googling and it should be quite helpful. Presumably I'll have to upload both the executable and SALFLIB to the web server to try it out.
It also gives advice on exporting graphics. I guess the next question is a trickier one. Part of the application that I want to put on the server uses interactive graphics (for example querying points on a displayed model, or moving vertices in a wireframe). Would a FORTRAN .NET program help with this? _________________ (Steve Henley) |
|
Back to top |
|
 |
JohnHorspool
Joined: 26 Sep 2005 Posts: 270 Location: Gloucestershire UK
|
Posted: Wed Jun 15, 2011 4:48 pm Post subject: |
|
|
Hello Steve,
Sorry I can't help you. Hopefully someone else may do, but I suspect that you may will be the first person to attempt this with ftn95 ! Good Luck ! _________________ John Horspool
Roshaz Software Ltd.
Gloucestershire |
|
Back to top |
|
 |
silicondale
Joined: 15 Mar 2007 Posts: 252 Location: Matlock, Derbyshire, UK
|
Posted: Wed Jun 15, 2011 5:11 pm Post subject: |
|
|
Thanks anyway! I want to get the simple Fortran executable working first, though. Hit a brick wall with:
CGI Error
The specified CGI application misbehaved by not returning a complete set of HTTP headers
It's on a Microsoft Windows server with IIS5 or 6.
I tried changing the .exe extension to .cgi but it didn't help. The Fortran is very simple - see below. Ideas, anyone?
program example0
WRITE(*,*) ' Content-type: text/html'
WRITE(*,*) ' <?xml version="1.0" encoding="utf-8"?>'
WRITE(*,*) ' <!DOCTYPE html PUBLIC>'
WRITE(*,*) ' <html><head></head><body>'
WRITE(*,*) ' <p>HELLO WORLD</p></body></html>'
STOP
END _________________ (Steve Henley) |
|
Back to top |
|
 |
silicondale
Joined: 15 Mar 2007 Posts: 252 Location: Matlock, Derbyshire, UK
|
Posted: Thu Jun 16, 2011 6:08 pm Post subject: |
|
|
I've tried it now on a Win2000 computer with a local web server just to see what the problem is. That also fails, with a CGI Timeout.
I'm wondering if this is because of the opening splash window from the free version - I guess that executing as a CGI script, there isn't anywhere for that to be displayed. Could that be the reason it's not working?
I have an old paid-for version of Salford Fortran which I would like to use, but unfortunately haven't been able to get rid of the splash window by using it. If I uninstall all versions and then reinstall the original one, might that do the trick, I wonder? _________________ (Steve Henley) |
|
Back to top |
|
 |
silicondale
Joined: 15 Mar 2007 Posts: 252 Location: Matlock, Derbyshire, UK
|
Posted: Thu Feb 16, 2012 3:25 pm Post subject: It worked |
|
|
OK, made some progress. reinstalled my old licensed v3.0 version and it works fine locally. I have also got a Windows VPS now, and it also works on this. Important thing is to have no user input (other than from files) and no direct output to screen or printer, only to files.
Output works fine, also to graphics files (JPG, BMP) except that I have hit undocumented limits, max 2048 pixels in the x direction. Have posted separately about this. I need better resolution than this for the graphics: it is mainly vector graphics - map plotting, from applications originally developed for hi-res A0 size plotters. 4096 x 4096 would be just about acceptable. _________________ (Steve Henley) |
|
Back to top |
|
 |
|