diff options
Diffstat (limited to 'html.c')
| -rw-r--r-- | html.c | 13 |
1 files changed, 9 insertions, 4 deletions
| @@ -636,13 +636,18 @@ static xs_html *html_base_head(void) | |||
| 636 | xs_html_attr("content", USER_AGENT))); | 636 | xs_html_attr("content", USER_AGENT))); |
| 637 | 637 | ||
| 638 | /* add server CSS and favicon */ | 638 | /* add server CSS and favicon */ |
| 639 | xs *f; | 639 | xs *f = NULL; |
| 640 | f = xs_fmt("%s/favicon.ico", srv_baseurl); | 640 | const char *favicon = xs_dict_get(srv_config, "favicon_url"); |
| 641 | |||
| 642 | if (xs_is_string(favicon)) | ||
| 643 | f = xs_dup(favicon); | ||
| 644 | else | ||
| 645 | f = xs_fmt("%s/favicon.ico", srv_baseurl); | ||
| 646 | |||
| 641 | const xs_list *p = xs_dict_get(srv_config, "cssurls"); | 647 | const xs_list *p = xs_dict_get(srv_config, "cssurls"); |
| 642 | const char *v; | 648 | const char *v; |
| 643 | int c = 0; | ||
| 644 | 649 | ||
| 645 | while (xs_list_next(p, &v, &c)) { | 650 | xs_list_foreach(p, v) { |
| 646 | xs_html_add(head, | 651 | xs_html_add(head, |
| 647 | xs_html_sctag("link", | 652 | xs_html_sctag("link", |
| 648 | xs_html_attr("rel", "stylesheet"), | 653 | xs_html_attr("rel", "stylesheet"), |