/[MITgcm]/mitgcm.org/devel/buildweb/code-browser/F90Mapper/html_write.c
ViewVC logotype

Annotation of /mitgcm.org/devel/buildweb/code-browser/F90Mapper/html_write.c

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.1.1.1 - (hide annotations) (download) (vendor branch)
Fri Sep 20 19:47:31 2002 UTC (22 years, 9 months ago) by adcroft
Branch: Import, MAIN
CVS Tags: baseline, HEAD
Changes since 1.1: +0 -0 lines
File MIME type: text/plain
Importing web-site building process.

1 adcroft 1.1 /*
2     Generic HTML writing functions
3     */
4     #include <strings.h>
5     #include <stdio.h>
6     #include "DD.h"
7     #include "FD.h"
8     #include "GLOBALS.h"
9    
10     html_ul( FILE *o) { fprintf(o,"<ul>" ); }
11     html_eul(FILE *o) { fprintf(o,"</ul>"); }
12     html_li( FILE *o) { fprintf(o,"<li>" ); }
13     html_eli(FILE *o) { fprintf(o,"</li>"); }
14     html_hn( FILE *o,char *h) { fprintf(o,"<%s>",h ); }
15     html_ehn(FILE *o,char *h) { fprintf(o,"</%s>",h); }
16    
17     html_start(FILE *o){
18     /* Generic header stuff */
19     fprintf(o,"<HTML><HEAD>\n");
20     fprintf(o,"<TITLE> </TITLE>\n");
21     fprintf(o,"</HEAD>\n<BODY text=\"#000000\" bgcolor=\"#FFFFFF\">\n");
22     }
23    
24     html_end(FILE *o){
25     /* Generic footer stuff */
26     fprintf(o,"</BODY></HTML>");
27     }
28    
29     html_entryli(FILE *o,char *string,char *href,char *heading){
30     /*
31     do <li><"heading"><a href="href">"string"</a></"heading"></li>
32     */
33     html_li(o);
34     fprintf(o,"<A href=%s>",href);
35     html_hn(o,heading);
36     fprintf(o,"%s",string);
37     html_ehn(o,heading);
38     fprintf(o,"</A>");
39     html_eli(o);
40     }
41    
42     html_entry(FILE *o,char *string,char *href){
43     /*
44     do <a href="href">"string"</a>
45     */
46     fprintf(o,"<A href=%s>",href);
47     fprintf(o,"%s",string);
48     fprintf(o,"</A>");
49     }
50    
51     int html_FlistTabStart(FILE *curFd)
52     {
53     /* fprintf(curFd,"<TITLE>Source Files</TITLE>"); */
54     /* Begin table */
55     fprintf(curFd,
56     "<TABLE BORDER CELLSPACING=1 BORDERCOLOR=\"#000000\" CELLPADDING=2 >");
57     }
58    
59     int html_FlistColHeader(FILE *curFd)
60     /*
61     File listing table column format
62     */
63     {
64     fprintf(curFd,"<TR>");
65     fprintf(curFd,"<TD VALIGN=\"CENTER\" HEIGHT=40 ALIGN=\"CENTER\">");
66     fprintf(curFd,"<FONT SIZE=5><B><U>Directory </U></B></FONT>");
67     fprintf(curFd,"</TD>");
68     fprintf(curFd,"<TD VALIGN=\"CENTER\" HEIGHT=40 ALIGN=\"CENTER\">");
69     fprintf(curFd,"<FONT SIZE=5><B><U>File Name</U></B></FONT>");
70     fprintf(curFd,"</TD>");
71     fprintf(curFd,"<TD VALIGN=\"CENTER\" HEIGHT=40 ALIGN=\"CENTER\">");
72     fprintf(curFd,"<FONT SIZE=5><B><U>Description</U></B></FONT>");
73     fprintf(curFd,"</TD>");
74     fprintf(curFd,"</TR>");
75     }
76    
77     int html_FlistColRecord(FILE *curFd, char *dirNam, char *fNam, char *hfNam, char *descrip)
78     /*
79     File listing table column format
80     */
81     {
82     fprintf(curFd,"<TR>");
83     fprintf(curFd,"<TD><B><FONT FACE=\"Courier\">");
84     fprintf(curFd,"%s",dirNam);
85     fprintf(curFd,"</FONT></B></TD>");
86     fprintf(curFd,"<TD><B><FONT FACE=\"Courier\">");
87     fprintf(curFd,"<A HREF=%s/%s>",SRCSUF,hfNam);
88     fprintf(curFd,"%s",fNam);
89     fprintf(curFd,"</A>");
90     fprintf(curFd,"</FONT></B></TD>");
91     fprintf(curFd,"<TD><B><FONT FACE=\"Courier\">");
92     fprintf(curFd,"%s",descrip);
93     fprintf(curFd,"</FONT></B></TD>");
94     fprintf(curFd,"</TR>");
95     }
96    
97     int html_FlistTabStop(FILE *curFd)
98     {
99     /* End table */
100     fprintf(curFd,
101     "</TABLE>");
102     }

  ViewVC Help
Powered by ViewVC 1.1.22