summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Jones <admin@danieljon.es>2020-01-06 20:50:53 +1030
committerDaniel Jones <admin@danieljon.es>2020-01-06 20:50:53 +1030
commit3db6262eecfeebfbe94efd6c8fd8ba0d00874934 (patch)
tree310497a91ad53274cdb35407cad0481ee5da941b
parent9e09cc1469963582a596258824df60889bcd79fa (diff)
downloadwebsitegenerator-3db6262eecfeebfbe94efd6c8fd8ba0d00874934.tar.gz
websitegenerator-3db6262eecfeebfbe94efd6c8fd8ba0d00874934.zip
pagebar generation: don't asdd .html to link
-rw-r--r--pages.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/pages.c b/pages.c
index c2fadd5..47248b1 100644
--- a/pages.c
+++ b/pages.c
@@ -503,7 +503,7 @@ char
int i;
size_t freespace = size;
/* gross hack, sxprintf returns the number of chars written, keep track of our freespace */
- freespace -= snprintf(buff, freespace, "<div class='middle'> <a href='%d.html'>prev</a> ", (currentpage == 1) ? pagecount : currentpage-1);
+ freespace -= snprintf(buff, freespace, "<div class='middle'> <a href='%d'>prev</a> ", (currentpage == 1) ? pagecount : currentpage-1);
if (freespace <= 0) {fprintf(stderr, "out of space in buffer for generatepagebar()\n"); return NULL;}
strncat(bar, buff, freespace);
for (int i = 1; i <= pagecount; i++)
@@ -548,7 +548,7 @@ writeposts(const int *posts, size_t totalposts, const char *outfile, int current
while (stop > (totalposts))
stop--;
- printf("page number is %d, post range is %d-%d, output is: %s\n", currentpage, start, stop, outfilename);
+ printf("page number is %d\n", currentpage);
int post;
/* write posts to a temp file */
char source[512];