Subversion Repositories RepoView

Rev

Rev 55 | Rev 57 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 55 Rev 56
Line 1... Line 1...
1
/* $Id: modern.c 55 2024-08-22 06:03:40Z nishi $ */
1
/* $Id: modern.c 56 2024-08-22 06:04:49Z nishi $ */
2
 
2
 
3
#include "rv_query.h"
3
#include "rv_query.h"
4
 
4
 
5
#include "rv_util.h"
5
#include "rv_util.h"
6
#include "rv_version.h"
6
#include "rv_version.h"
Line 111... Line 111...
111
	}
111
	}
112
	return r;
112
	return r;
113
}
113
}
114
 
114
 
115
int fcounter = 0;
115
int fcounter = 0;
-
 
116
char* instead_username = NULL;
116
void list_repo(const char* name, const char* rev) {
117
void list_repo(const char* name, const char* rev) {
117
	char* showname = html_escape(name);
118
	char* showname = html_escape(name);
118
	char* urluser = url_escape(user);
119
	char* urluser = url_escape(instead_username == NULL ? user : instead_username);
119
	char* urlrepo = url_escape(name);
120
	char* urlrepo = url_escape(name);
120
	add_data(&page, "<tr style=\"background-color: #");
121
	add_data(&page, "<tr style=\"background-color: #");
121
	if((fcounter % 2) == 0) {
122
	if((fcounter % 2) == 0) {
122
		add_data(&page, "D2E1C0");
123
		add_data(&page, "D2E1C0");
123
	} else {
124
	} else {
Line 823... Line 824...
823
 
824
 
824
				add_data(&page, "<h2 id=\"repolist\">Repository List</h2>\n");
825
				add_data(&page, "<h2 id=\"repolist\">Repository List</h2>\n");
825
				add_data(&page, "<table border=\"0\">\n");
826
				add_data(&page, "<table border=\"0\">\n");
826
				add_data(&page, "<tr style=\"background-color: #D2E1F6;\"><th>Repository name</th><th>Revision</th></tr>\n");
827
				add_data(&page, "<tr style=\"background-color: #D2E1F6;\"><th>Repository name</th><th>Revision</th></tr>\n");
827
				fcounter = 0;
828
				fcounter = 0;
-
 
829
				instead_username = rv_get_query("username");
828
				rv_repo_list(rv_get_query("username"), list_repo);
830
				rv_repo_list(rv_get_query("username"), list_repo);
829
				add_data(&page, "</table>\n");
831
				add_data(&page, "</table>\n");
830
			} else {
832
			} else {
831
				add_data(&page, "User does not exist.\n");
833
				add_data(&page, "User does not exist.\n");
832
			}
834
			}