Fossil SCM

Add hyperlinks to the "user:" and "tags:" marks in timelines.

drh 2011-01-28 14:09 trunk
Commit 13165785e1deb2de3b1fb9014f5c7c7b290f0f4e
+1 -1
--- src/branch.c
+++ src/branch.c
@@ -357,11 +357,11 @@
357357
"%s AND blob.rid IN (SELECT rid FROM tagxref"
358358
" WHERE tagtype>0 AND tagid=%d AND srcid!=0)"
359359
" ORDER BY event.mtime DESC",
360360
timeline_query_for_www(), TAG_BRANCH
361361
);
362
- www_print_timeline(&q, 0, brtimeline_extra);
362
+ www_print_timeline(&q, 0, 0, 0, brtimeline_extra);
363363
db_finalize(&q);
364364
@ <script type="text/JavaScript">
365365
@ function xin(id){
366366
@ }
367367
@ function xout(id){
368368
--- src/branch.c
+++ src/branch.c
@@ -357,11 +357,11 @@
357 "%s AND blob.rid IN (SELECT rid FROM tagxref"
358 " WHERE tagtype>0 AND tagid=%d AND srcid!=0)"
359 " ORDER BY event.mtime DESC",
360 timeline_query_for_www(), TAG_BRANCH
361 );
362 www_print_timeline(&q, 0, brtimeline_extra);
363 db_finalize(&q);
364 @ <script type="text/JavaScript">
365 @ function xin(id){
366 @ }
367 @ function xout(id){
368
--- src/branch.c
+++ src/branch.c
@@ -357,11 +357,11 @@
357 "%s AND blob.rid IN (SELECT rid FROM tagxref"
358 " WHERE tagtype>0 AND tagid=%d AND srcid!=0)"
359 " ORDER BY event.mtime DESC",
360 timeline_query_for_www(), TAG_BRANCH
361 );
362 www_print_timeline(&q, 0, 0, 0, brtimeline_extra);
363 db_finalize(&q);
364 @ <script type="text/JavaScript">
365 @ function xin(id){
366 @ }
367 @ function xout(id){
368
--- src/descendants.c
+++ src/descendants.c
@@ -342,11 +342,11 @@
342342
"%s"
343343
" AND blob.rid IN leaves"
344344
" ORDER BY event.mtime DESC",
345345
timeline_query_for_www()
346346
);
347
- www_print_timeline(&q, TIMELINE_LEAFONLY, leaves_extra);
347
+ www_print_timeline(&q, TIMELINE_LEAFONLY, 0, 0, leaves_extra);
348348
db_finalize(&q);
349349
@ <br />
350350
@ <script type="text/JavaScript">
351351
@ function xin(id){
352352
@ }
353353
--- src/descendants.c
+++ src/descendants.c
@@ -342,11 +342,11 @@
342 "%s"
343 " AND blob.rid IN leaves"
344 " ORDER BY event.mtime DESC",
345 timeline_query_for_www()
346 );
347 www_print_timeline(&q, TIMELINE_LEAFONLY, leaves_extra);
348 db_finalize(&q);
349 @ <br />
350 @ <script type="text/JavaScript">
351 @ function xin(id){
352 @ }
353
--- src/descendants.c
+++ src/descendants.c
@@ -342,11 +342,11 @@
342 "%s"
343 " AND blob.rid IN leaves"
344 " ORDER BY event.mtime DESC",
345 timeline_query_for_www()
346 );
347 www_print_timeline(&q, TIMELINE_LEAFONLY, 0, 0, leaves_extra);
348 db_finalize(&q);
349 @ <br />
350 @ <script type="text/JavaScript">
351 @ function xin(id){
352 @ }
353
+1 -1
--- src/tag.c
+++ src/tag.c
@@ -583,11 +583,11 @@
583583
" AND tagid IN (SELECT tagid FROM tag "
584584
" WHERE tagname GLOB 'sym-*'))"
585585
" ORDER BY event.mtime DESC",
586586
timeline_query_for_www()
587587
);
588
- www_print_timeline(&q, 0, tagtimeline_extra);
588
+ www_print_timeline(&q, 0, 0, 0, tagtimeline_extra);
589589
db_finalize(&q);
590590
@ <br />
591591
@ <script type="text/JavaScript">
592592
@ function xin(id){
593593
@ }
594594
--- src/tag.c
+++ src/tag.c
@@ -583,11 +583,11 @@
583 " AND tagid IN (SELECT tagid FROM tag "
584 " WHERE tagname GLOB 'sym-*'))"
585 " ORDER BY event.mtime DESC",
586 timeline_query_for_www()
587 );
588 www_print_timeline(&q, 0, tagtimeline_extra);
589 db_finalize(&q);
590 @ <br />
591 @ <script type="text/JavaScript">
592 @ function xin(id){
593 @ }
594
--- src/tag.c
+++ src/tag.c
@@ -583,11 +583,11 @@
583 " AND tagid IN (SELECT tagid FROM tag "
584 " WHERE tagname GLOB 'sym-*'))"
585 " ORDER BY event.mtime DESC",
586 timeline_query_for_www()
587 );
588 www_print_timeline(&q, 0, 0, 0, tagtimeline_extra);
589 db_finalize(&q);
590 @ <br />
591 @ <script type="text/JavaScript">
592 @ function xin(id){
593 @ }
594
+53 -6
--- src/timeline.c
+++ src/timeline.c
@@ -149,10 +149,12 @@
149149
** 10. Short comment to user for repeated tickets and wiki
150150
*/
151151
void www_print_timeline(
152152
Stmt *pQuery, /* Query to implement the timeline */
153153
int tmFlags, /* Flags controlling display behavior */
154
+ const char *zThisUser, /* Suppress links to this user */
155
+ const char *zThisTag, /* Suppress links to this tag */
154156
void (*xExtra)(int) /* Routine to call on each line of display */
155157
){
156158
int wikiFlags;
157159
int mxWikiLen;
158160
Blob comment;
@@ -290,15 +292,54 @@
290292
blob_reset(&truncated);
291293
}else{
292294
wiki_convert(&comment, 0, wikiFlags);
293295
}
294296
blob_reset(&comment);
295
- if( zTagList && zTagList[0] ){
296
- @ (user: %h(zUser), tags: %h(zTagList))
297
+
298
+ /* Generate the "user: USERNAME" at the end of the comment, together
299
+ ** with a hyperlink to another timeline for that user.
300
+ */
301
+ if( zTagList && zTagList[0]==0 ) zTagList = 0;
302
+ if( g.okHistory && fossil_strcmp(zUser, zThisUser)!=0 ){
303
+ char *zLink = mprintf("%s/timeline?u=%h&c=%t&nd",
304
+ g.zTop, zUser, zDate);
305
+ @ (user: <a href="%s(zLink)">%h(zUser)</a>%s(zTagList?",":"\051")
306
+ fossil_free(zLink);
297307
}else{
298
- @ (user: %h(zUser))
308
+ @ (user: %h(zUser)%s(zTagList?",":"\051")
309
+ }
310
+
311
+ /* Generate the "tags: TAGLIST" at the end of the comment, together
312
+ ** with hyperlinks to the tag list.
313
+ */
314
+ if( zTagList ){
315
+ if( g.okHistory ){
316
+ int i;
317
+ const char *z = zTagList;
318
+ Blob links;
319
+ blob_zero(&links);
320
+ while( z && z[0] ){
321
+ for(i=0; z[i] && (z[i]!=',' || z[i+1]!=' '); i++){}
322
+ if( zThisTag==0 || memcmp(z, zThisTag, i)!=0 || zThisTag[i]!=0 ){
323
+ blob_appendf(&links,
324
+ "<a href=\"%s/timeline?r=%.*t&nd&c=%s\">%.*h</a>%.2s",
325
+ g.zTop, i, z, zDate, i, z, &z[i]
326
+ );
327
+ }else{
328
+ blob_appendf(&links, "%.*h", i+2, z);
329
+ }
330
+ if( z[i]==0 ) break;
331
+ z += i+2;
332
+ }
333
+ @ tags: %s(blob_str(&links)))
334
+ blob_reset(&links);
335
+ }else{
336
+ @ tags: %h(zTagList))
337
+ }
299338
}
339
+
340
+ /* Generate extra hyperlinks at the end of the comment */
300341
if( xExtra ){
301342
xExtra(rid);
302343
}
303344
@ </td></tr>
304345
}
@@ -708,22 +749,26 @@
708749
const char *zCirca = P("c"); /* Events near this time */
709750
const char *zTagName = P("t"); /* Show events with this tag */
710751
const char *zBrName = P("r"); /* Show events related to this tag */
711752
const char *zSearch = P("s"); /* Search string */
712753
int useDividers = P("nd")==0; /* Show dividers if "nd" is missing */
713
- HQuery url; /* URL for various branch links */
714754
int tagid; /* Tag ID */
715755
int tmFlags; /* Timeline flags */
756
+ const char *zThisTag = 0; /* Suppress links to this tag */
757
+ const char *zThisUser = 0; /* Suppress links to this user */
758
+ HQuery url; /* URL for various branch links */
716759
717760
/* To view the timeline, must have permission to read project data.
718761
*/
719762
login_check_credentials();
720763
if( !g.okRead && !g.okRdTkt && !g.okRdWiki ){ login_needed(); return; }
721764
if( zTagName && g.okRead ){
722765
tagid = db_int(0, "SELECT tagid FROM tag WHERE tagname='sym-%q'", zTagName);
766
+ zThisTag = zTagName;
723767
}else if( zBrName && g.okRead ){
724768
tagid = db_int(0, "SELECT tagid FROM tag WHERE tagname='sym-%q'",zBrName);
769
+ zThisTag = zBrName;
725770
}else{
726771
tagid = 0;
727772
}
728773
if( zType[0]=='a' ){
729774
tmFlags = TIMELINE_BRIEF | TIMELINE_GRAPH;
@@ -739,10 +784,12 @@
739784
timeline_temp_table();
740785
blob_zero(&sql);
741786
blob_zero(&desc);
742787
blob_append(&sql, "INSERT OR IGNORE INTO timeline ", -1);
743788
blob_append(&sql, timeline_query_for_www(), -1);
789
+ url_initialize(&url, "timeline");
790
+ if( !useDividers ) url_add_parameter(&url, "nd", 0);
744791
if( (p_rid || d_rid) && g.okRead ){
745792
/* If p= or d= is present, ignore all other parameters other than n= */
746793
char *zUuid;
747794
int np, nd;
748795
@@ -807,11 +854,10 @@
807854
}else{
808855
int n;
809856
const char *zEType = "timeline item";
810857
char *zDate;
811858
char *zNEntry = mprintf("%d", nEntry);
812
- url_initialize(&url, "timeline");
813859
url_add_parameter(&url, "n", zNEntry);
814860
if( tagid>0 ){
815861
blob_appendf(&sql,
816862
"AND (EXISTS(SELECT 1 FROM tagxref"
817863
" WHERE tagid=%d AND tagtype>0 AND rid=blob.rid)", tagid);
@@ -874,10 +920,11 @@
874920
}
875921
}
876922
if( zUser ){
877923
blob_appendf(&sql, " AND event.user=%Q", zUser);
878924
url_add_parameter(&url, "u", zUser);
925
+ zThisUser = zUser;
879926
}
880927
if ( zSearch ){
881928
blob_appendf(&sql,
882929
" AND (event.comment LIKE '%%%q%%' OR event.brief LIKE '%%%q%%')",
883930
zSearch, zSearch);
@@ -1002,11 +1049,11 @@
10021049
}
10031050
blob_zero(&sql);
10041051
db_prepare(&q, "SELECT * FROM timeline ORDER BY sortby DESC /*scan*/");
10051052
@ <h2>%b(&desc)</h2>
10061053
blob_reset(&desc);
1007
- www_print_timeline(&q, tmFlags, 0);
1054
+ www_print_timeline(&q, tmFlags, zThisUser, zThisTag, 0);
10081055
db_finalize(&q);
10091056
style_footer();
10101057
}
10111058
10121059
/*
10131060
--- src/timeline.c
+++ src/timeline.c
@@ -149,10 +149,12 @@
149 ** 10. Short comment to user for repeated tickets and wiki
150 */
151 void www_print_timeline(
152 Stmt *pQuery, /* Query to implement the timeline */
153 int tmFlags, /* Flags controlling display behavior */
 
 
154 void (*xExtra)(int) /* Routine to call on each line of display */
155 ){
156 int wikiFlags;
157 int mxWikiLen;
158 Blob comment;
@@ -290,15 +292,54 @@
290 blob_reset(&truncated);
291 }else{
292 wiki_convert(&comment, 0, wikiFlags);
293 }
294 blob_reset(&comment);
295 if( zTagList && zTagList[0] ){
296 @ (user: %h(zUser), tags: %h(zTagList))
 
 
 
 
 
 
 
 
297 }else{
298 @ (user: %h(zUser))
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
299 }
 
 
300 if( xExtra ){
301 xExtra(rid);
302 }
303 @ </td></tr>
304 }
@@ -708,22 +749,26 @@
708 const char *zCirca = P("c"); /* Events near this time */
709 const char *zTagName = P("t"); /* Show events with this tag */
710 const char *zBrName = P("r"); /* Show events related to this tag */
711 const char *zSearch = P("s"); /* Search string */
712 int useDividers = P("nd")==0; /* Show dividers if "nd" is missing */
713 HQuery url; /* URL for various branch links */
714 int tagid; /* Tag ID */
715 int tmFlags; /* Timeline flags */
 
 
 
716
717 /* To view the timeline, must have permission to read project data.
718 */
719 login_check_credentials();
720 if( !g.okRead && !g.okRdTkt && !g.okRdWiki ){ login_needed(); return; }
721 if( zTagName && g.okRead ){
722 tagid = db_int(0, "SELECT tagid FROM tag WHERE tagname='sym-%q'", zTagName);
 
723 }else if( zBrName && g.okRead ){
724 tagid = db_int(0, "SELECT tagid FROM tag WHERE tagname='sym-%q'",zBrName);
 
725 }else{
726 tagid = 0;
727 }
728 if( zType[0]=='a' ){
729 tmFlags = TIMELINE_BRIEF | TIMELINE_GRAPH;
@@ -739,10 +784,12 @@
739 timeline_temp_table();
740 blob_zero(&sql);
741 blob_zero(&desc);
742 blob_append(&sql, "INSERT OR IGNORE INTO timeline ", -1);
743 blob_append(&sql, timeline_query_for_www(), -1);
 
 
744 if( (p_rid || d_rid) && g.okRead ){
745 /* If p= or d= is present, ignore all other parameters other than n= */
746 char *zUuid;
747 int np, nd;
748
@@ -807,11 +854,10 @@
807 }else{
808 int n;
809 const char *zEType = "timeline item";
810 char *zDate;
811 char *zNEntry = mprintf("%d", nEntry);
812 url_initialize(&url, "timeline");
813 url_add_parameter(&url, "n", zNEntry);
814 if( tagid>0 ){
815 blob_appendf(&sql,
816 "AND (EXISTS(SELECT 1 FROM tagxref"
817 " WHERE tagid=%d AND tagtype>0 AND rid=blob.rid)", tagid);
@@ -874,10 +920,11 @@
874 }
875 }
876 if( zUser ){
877 blob_appendf(&sql, " AND event.user=%Q", zUser);
878 url_add_parameter(&url, "u", zUser);
 
879 }
880 if ( zSearch ){
881 blob_appendf(&sql,
882 " AND (event.comment LIKE '%%%q%%' OR event.brief LIKE '%%%q%%')",
883 zSearch, zSearch);
@@ -1002,11 +1049,11 @@
1002 }
1003 blob_zero(&sql);
1004 db_prepare(&q, "SELECT * FROM timeline ORDER BY sortby DESC /*scan*/");
1005 @ <h2>%b(&desc)</h2>
1006 blob_reset(&desc);
1007 www_print_timeline(&q, tmFlags, 0);
1008 db_finalize(&q);
1009 style_footer();
1010 }
1011
1012 /*
1013
--- src/timeline.c
+++ src/timeline.c
@@ -149,10 +149,12 @@
149 ** 10. Short comment to user for repeated tickets and wiki
150 */
151 void www_print_timeline(
152 Stmt *pQuery, /* Query to implement the timeline */
153 int tmFlags, /* Flags controlling display behavior */
154 const char *zThisUser, /* Suppress links to this user */
155 const char *zThisTag, /* Suppress links to this tag */
156 void (*xExtra)(int) /* Routine to call on each line of display */
157 ){
158 int wikiFlags;
159 int mxWikiLen;
160 Blob comment;
@@ -290,15 +292,54 @@
292 blob_reset(&truncated);
293 }else{
294 wiki_convert(&comment, 0, wikiFlags);
295 }
296 blob_reset(&comment);
297
298 /* Generate the "user: USERNAME" at the end of the comment, together
299 ** with a hyperlink to another timeline for that user.
300 */
301 if( zTagList && zTagList[0]==0 ) zTagList = 0;
302 if( g.okHistory && fossil_strcmp(zUser, zThisUser)!=0 ){
303 char *zLink = mprintf("%s/timeline?u=%h&c=%t&nd",
304 g.zTop, zUser, zDate);
305 @ (user: <a href="%s(zLink)">%h(zUser)</a>%s(zTagList?",":"\051")
306 fossil_free(zLink);
307 }else{
308 @ (user: %h(zUser)%s(zTagList?",":"\051")
309 }
310
311 /* Generate the "tags: TAGLIST" at the end of the comment, together
312 ** with hyperlinks to the tag list.
313 */
314 if( zTagList ){
315 if( g.okHistory ){
316 int i;
317 const char *z = zTagList;
318 Blob links;
319 blob_zero(&links);
320 while( z && z[0] ){
321 for(i=0; z[i] && (z[i]!=',' || z[i+1]!=' '); i++){}
322 if( zThisTag==0 || memcmp(z, zThisTag, i)!=0 || zThisTag[i]!=0 ){
323 blob_appendf(&links,
324 "<a href=\"%s/timeline?r=%.*t&nd&c=%s\">%.*h</a>%.2s",
325 g.zTop, i, z, zDate, i, z, &z[i]
326 );
327 }else{
328 blob_appendf(&links, "%.*h", i+2, z);
329 }
330 if( z[i]==0 ) break;
331 z += i+2;
332 }
333 @ tags: %s(blob_str(&links)))
334 blob_reset(&links);
335 }else{
336 @ tags: %h(zTagList))
337 }
338 }
339
340 /* Generate extra hyperlinks at the end of the comment */
341 if( xExtra ){
342 xExtra(rid);
343 }
344 @ </td></tr>
345 }
@@ -708,22 +749,26 @@
749 const char *zCirca = P("c"); /* Events near this time */
750 const char *zTagName = P("t"); /* Show events with this tag */
751 const char *zBrName = P("r"); /* Show events related to this tag */
752 const char *zSearch = P("s"); /* Search string */
753 int useDividers = P("nd")==0; /* Show dividers if "nd" is missing */
 
754 int tagid; /* Tag ID */
755 int tmFlags; /* Timeline flags */
756 const char *zThisTag = 0; /* Suppress links to this tag */
757 const char *zThisUser = 0; /* Suppress links to this user */
758 HQuery url; /* URL for various branch links */
759
760 /* To view the timeline, must have permission to read project data.
761 */
762 login_check_credentials();
763 if( !g.okRead && !g.okRdTkt && !g.okRdWiki ){ login_needed(); return; }
764 if( zTagName && g.okRead ){
765 tagid = db_int(0, "SELECT tagid FROM tag WHERE tagname='sym-%q'", zTagName);
766 zThisTag = zTagName;
767 }else if( zBrName && g.okRead ){
768 tagid = db_int(0, "SELECT tagid FROM tag WHERE tagname='sym-%q'",zBrName);
769 zThisTag = zBrName;
770 }else{
771 tagid = 0;
772 }
773 if( zType[0]=='a' ){
774 tmFlags = TIMELINE_BRIEF | TIMELINE_GRAPH;
@@ -739,10 +784,12 @@
784 timeline_temp_table();
785 blob_zero(&sql);
786 blob_zero(&desc);
787 blob_append(&sql, "INSERT OR IGNORE INTO timeline ", -1);
788 blob_append(&sql, timeline_query_for_www(), -1);
789 url_initialize(&url, "timeline");
790 if( !useDividers ) url_add_parameter(&url, "nd", 0);
791 if( (p_rid || d_rid) && g.okRead ){
792 /* If p= or d= is present, ignore all other parameters other than n= */
793 char *zUuid;
794 int np, nd;
795
@@ -807,11 +854,10 @@
854 }else{
855 int n;
856 const char *zEType = "timeline item";
857 char *zDate;
858 char *zNEntry = mprintf("%d", nEntry);
 
859 url_add_parameter(&url, "n", zNEntry);
860 if( tagid>0 ){
861 blob_appendf(&sql,
862 "AND (EXISTS(SELECT 1 FROM tagxref"
863 " WHERE tagid=%d AND tagtype>0 AND rid=blob.rid)", tagid);
@@ -874,10 +920,11 @@
920 }
921 }
922 if( zUser ){
923 blob_appendf(&sql, " AND event.user=%Q", zUser);
924 url_add_parameter(&url, "u", zUser);
925 zThisUser = zUser;
926 }
927 if ( zSearch ){
928 blob_appendf(&sql,
929 " AND (event.comment LIKE '%%%q%%' OR event.brief LIKE '%%%q%%')",
930 zSearch, zSearch);
@@ -1002,11 +1049,11 @@
1049 }
1050 blob_zero(&sql);
1051 db_prepare(&q, "SELECT * FROM timeline ORDER BY sortby DESC /*scan*/");
1052 @ <h2>%b(&desc)</h2>
1053 blob_reset(&desc);
1054 www_print_timeline(&q, tmFlags, zThisUser, zThisTag, 0);
1055 db_finalize(&q);
1056 style_footer();
1057 }
1058
1059 /*
1060
+2 -1
--- src/tkt.c
+++ src/tkt.c
@@ -704,11 +704,12 @@
704704
timeline_query_for_www(), tagid, zFullUuid, zFullUuid, zFullUuid
705705
);
706706
}
707707
db_prepare(&q, zSQL);
708708
free(zSQL);
709
- www_print_timeline(&q, TIMELINE_ARTID|TIMELINE_DISJOINT|TIMELINE_GRAPH, 0);
709
+ www_print_timeline(&q, TIMELINE_ARTID|TIMELINE_DISJOINT|TIMELINE_GRAPH,
710
+ 0, 0, 0);
710711
db_finalize(&q);
711712
style_footer();
712713
}
713714
714715
/*
715716
--- src/tkt.c
+++ src/tkt.c
@@ -704,11 +704,12 @@
704 timeline_query_for_www(), tagid, zFullUuid, zFullUuid, zFullUuid
705 );
706 }
707 db_prepare(&q, zSQL);
708 free(zSQL);
709 www_print_timeline(&q, TIMELINE_ARTID|TIMELINE_DISJOINT|TIMELINE_GRAPH, 0);
 
710 db_finalize(&q);
711 style_footer();
712 }
713
714 /*
715
--- src/tkt.c
+++ src/tkt.c
@@ -704,11 +704,12 @@
704 timeline_query_for_www(), tagid, zFullUuid, zFullUuid, zFullUuid
705 );
706 }
707 db_prepare(&q, zSQL);
708 free(zSQL);
709 www_print_timeline(&q, TIMELINE_ARTID|TIMELINE_DISJOINT|TIMELINE_GRAPH,
710 0, 0, 0);
711 db_finalize(&q);
712 style_footer();
713 }
714
715 /*
716
+4 -3
--- src/url.c
+++ src/url.c
@@ -298,12 +298,12 @@
298298
*/
299299
struct HQuery {
300300
Blob url; /* The URL */
301301
const char *zBase; /* The base URL */
302302
int nParam; /* Number of parameters. Max 10 */
303
- const char *azName[10]; /* Parameter names */
304
- const char *azValue[10]; /* Parameter values */
303
+ const char *azName[15]; /* Parameter names */
304
+ const char *azValue[15]; /* Parameter values */
305305
};
306306
#endif
307307
308308
/*
309309
** Initialize the URL object.
@@ -350,11 +350,12 @@
350350
if( zName2 && strcmp(zName2,p->azName[i])==0 ){
351351
zName2 = 0;
352352
z = zValue2;
353353
if( z==0 ) continue;
354354
}
355
- blob_appendf(&p->url, "%s%s=%T", zSep, p->azName[i], z);
355
+ blob_appendf(&p->url, "%s%s", zSep, p->azName[i]);
356
+ if( z && z[0] ) blob_appendf(&p->url, "=%T", z);
356357
zSep = "&amp;";
357358
}
358359
if( zName1 && zValue1 ){
359360
blob_appendf(&p->url, "%s%s=%T", zSep, zName1, zValue1);
360361
}
361362
--- src/url.c
+++ src/url.c
@@ -298,12 +298,12 @@
298 */
299 struct HQuery {
300 Blob url; /* The URL */
301 const char *zBase; /* The base URL */
302 int nParam; /* Number of parameters. Max 10 */
303 const char *azName[10]; /* Parameter names */
304 const char *azValue[10]; /* Parameter values */
305 };
306 #endif
307
308 /*
309 ** Initialize the URL object.
@@ -350,11 +350,12 @@
350 if( zName2 && strcmp(zName2,p->azName[i])==0 ){
351 zName2 = 0;
352 z = zValue2;
353 if( z==0 ) continue;
354 }
355 blob_appendf(&p->url, "%s%s=%T", zSep, p->azName[i], z);
 
356 zSep = "&amp;";
357 }
358 if( zName1 && zValue1 ){
359 blob_appendf(&p->url, "%s%s=%T", zSep, zName1, zValue1);
360 }
361
--- src/url.c
+++ src/url.c
@@ -298,12 +298,12 @@
298 */
299 struct HQuery {
300 Blob url; /* The URL */
301 const char *zBase; /* The base URL */
302 int nParam; /* Number of parameters. Max 10 */
303 const char *azName[15]; /* Parameter names */
304 const char *azValue[15]; /* Parameter values */
305 };
306 #endif
307
308 /*
309 ** Initialize the URL object.
@@ -350,11 +350,12 @@
350 if( zName2 && strcmp(zName2,p->azName[i])==0 ){
351 zName2 = 0;
352 z = zValue2;
353 if( z==0 ) continue;
354 }
355 blob_appendf(&p->url, "%s%s", zSep, p->azName[i]);
356 if( z && z[0] ) blob_appendf(&p->url, "=%T", z);
357 zSep = "&amp;";
358 }
359 if( zName1 && zValue1 ){
360 blob_appendf(&p->url, "%s%s=%T", zSep, zName1, zValue1);
361 }
362
+1 -1
--- src/wiki.c
+++ src/wiki.c
@@ -577,11 +577,11 @@
577577
"ORDER BY mtime DESC",
578578
timeline_query_for_www(), zPageName, zPageName);
579579
db_prepare(&q, zSQL);
580580
free(zSQL);
581581
zWikiPageName = zPageName;
582
- www_print_timeline(&q, TIMELINE_ARTID, wiki_history_extra);
582
+ www_print_timeline(&q, TIMELINE_ARTID, 0, 0, wiki_history_extra);
583583
db_finalize(&q);
584584
style_footer();
585585
}
586586
587587
/*
588588
--- src/wiki.c
+++ src/wiki.c
@@ -577,11 +577,11 @@
577 "ORDER BY mtime DESC",
578 timeline_query_for_www(), zPageName, zPageName);
579 db_prepare(&q, zSQL);
580 free(zSQL);
581 zWikiPageName = zPageName;
582 www_print_timeline(&q, TIMELINE_ARTID, wiki_history_extra);
583 db_finalize(&q);
584 style_footer();
585 }
586
587 /*
588
--- src/wiki.c
+++ src/wiki.c
@@ -577,11 +577,11 @@
577 "ORDER BY mtime DESC",
578 timeline_query_for_www(), zPageName, zPageName);
579 db_prepare(&q, zSQL);
580 free(zSQL);
581 zWikiPageName = zPageName;
582 www_print_timeline(&q, TIMELINE_ARTID, 0, 0, wiki_history_extra);
583 db_finalize(&q);
584 style_footer();
585 }
586
587 /*
588

Keyboard Shortcuts

Open search /
Next entry (timeline) j
Previous entry (timeline) k
Open focused entry Enter
Show this help ?
Toggle theme Top nav button