Subversion Repositories RepoView

Rev

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

Rev 68 Rev 70
Line 1... Line 1...
1
/* $Id: modern.c 68 2024-08-24 08:19:05Z nishi $ */
1
/* $Id: modern.c 70 2024-08-24 08:48:19Z 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 932... Line 932...
932
	return r;
932
	return r;
933
}
933
}
934
 
934
 
935
void render_stuff(void) {
935
void render_stuff(void) {
936
	char* escaped;
936
	char* escaped;
-
 
937
	char cbuf[2];
-
 
938
	cbuf[1] = 0;
937
	add_data(&buffer, "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01//EN\" \"http://www.w3.org/TR/html4/strict.dtd\">\n");
939
	add_data(&buffer, "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01//EN\" \"http://www.w3.org/TR/html4/strict.dtd\">\n");
938
	add_data(&buffer, "<html>\n");
940
	add_data(&buffer, "<html>\n");
939
	add_data(&buffer, "	<head>\n");
941
	add_data(&buffer, "	<head>\n");
940
	add_data(&buffer, "		<meta http-equiv=\"Content-Type\" content=\"text/html;charset=utf-8\">\n");
942
	add_data(&buffer, "		<meta http-equiv=\"Content-Type\" content=\"text/html;charset=utf-8\">\n");
941
	add_data(&buffer, "		<title>");
943
	add_data(&buffer, "		<title>");
942
	add_data(&buffer, INSTANCE_NAME);
944
	add_data(&buffer, INSTANCE_NAME);
943
	add_data(&buffer, " - ");
945
	add_data(&buffer, " - ");
-
 
946
	int i;
-
 
947
	bool br = false;
-
 
948
	for(i = 0; title[i] != 0; i++){
-
 
949
		if(title[i] == '<'){
-
 
950
			br = true;
-
 
951
		}else if(title[i] == '>'){
-
 
952
			br = false;
-
 
953
		}else if(!br){
-
 
954
			cbuf[0] = title[i];
944
	add_data(&buffer, title);
955
			add_data(&buffer, cbuf);
-
 
956
		}
-
 
957
	}
945
	add_data(&buffer, "</title>\n");
958
	add_data(&buffer, "</title>\n");
946
	add_data(&buffer, "		<style type=\"text/css\">\n");
959
	add_data(&buffer, "		<style type=\"text/css\">\n");
947
	add_data(&buffer, "* {\n");
960
	add_data(&buffer, "* {\n");
948
	add_data(&buffer, "	padding: 0;\n");
961
	add_data(&buffer, "	padding: 0;\n");
949
	add_data(&buffer, "	margin: 0;\n");
962
	add_data(&buffer, "	margin: 0;\n");