65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
|
const struct Submenu *B = (const struct Submenu*)B;
return strcmp(A->zLabel, B->zLabel);
}
/*
** Draw the header.
*/
void style_header(void){
const char *zLogInOut = "Logout";
login_check_credentials();
@ <html>
@ <body bgcolor="white">
@ <hr size="1">
@ <table border="0" cellpadding="0" cellspacing="0" width="100%%">
@ <tr><td valign="top" align="left">
@ <big><big><b>Fossil SCM</b></big></big><br>
if( g.zLogin==0 || g.zLogin[0]==0 ){
@ <small>not logged in</small>
zLogInOut = "Login";
}else{
@ <small>logged in as %h(g.zLogin)</small>
}
@ </td><td valign="top" align="right">
@ <a href="%s(g.zBaseURL)/index">Home</a>
@ | <a href="%s(g.zBaseURL)/timeline">Timeline</a>
@ | <font color="#888888">Search</font>
@ | <font color="#888888">Ticket</font>
@ | <font color="#888888">Reports</font>
if( g.okSetup ){
@ | <a href="%s(g.zBaseURL)/setup">Setup</a>
}
if( !g.noPswd ){
@ | <a href="%s(g.zBaseURL)/login">%s(zLogInOut)</a>
}
if( nSubmenu>0 ){
|
|
|
>
>
>
>
>
|
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
|
const struct Submenu *B = (const struct Submenu*)B;
return strcmp(A->zLabel, B->zLabel);
}
/*
** Draw the header.
*/
void style_header(const char *zTitle){
const char *zLogInOut = "Logout";
login_check_credentials();
@ <html>
@ <body bgcolor="white">
@ <hr size="1">
@ <table border="0" cellpadding="0" cellspacing="0" width="100%%">
@ <tr><td valign="top" align="left">
@ <big><big><b>%s(zTitle)</b></big></big><br>
if( g.zLogin==0 || g.zLogin[0]==0 ){
@ <small>not logged in</small>
zLogInOut = "Login";
}else{
@ <small>logged in as %h(g.zLogin)</small>
}
@ </td><td valign="top" align="right">
@ <a href="%s(g.zBaseURL)/index">Home</a>
@ | <a href="%s(g.zBaseURL)/timeline">Timeline</a>
if( g.okRdWiki ){
@ | <a href="%s(g.zBaseURL)/wiki">Wiki</a>
}
#if 0
@ | <font color="#888888">Search</font>
@ | <font color="#888888">Ticket</font>
@ | <font color="#888888">Reports</font>
#endif
if( g.okSetup ){
@ | <a href="%s(g.zBaseURL)/setup">Setup</a>
}
if( !g.noPswd ){
@ | <a href="%s(g.zBaseURL)/login">%s(zLogInOut)</a>
}
if( nSubmenu>0 ){
|
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
|
/*
** WEBPAGE: index
** WEBPAGE: home
** WEBPAGE: not_found
*/
void page_index(void){
style_header();
@ This will become the title page
style_footer();
}
/*
** WEBPAGE: test_env
*/
void page_test_env(void){
style_header();
cgi_print_all();
style_footer();
}
|
|
|
|
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
|
/*
** WEBPAGE: index
** WEBPAGE: home
** WEBPAGE: not_found
*/
void page_index(void){
style_header("Main Title Page");
@ This will become the title page
style_footer();
}
/*
** WEBPAGE: test_env
*/
void page_test_env(void){
style_header("Environment Test");
cgi_print_all();
style_footer();
}
|