var minisrv_service_file = true; var files = session_data.listScrapbook(); var dir = session_data.scrapbookDir() var pageNum = parseInt(request_headers.query.pageNum || 1); var start = (pageNum - 1) * 6; headers = `200 OK Connection: Keep-Alive Content-Type: text/html wtv-expire-all: wtv-author:/scrapbook` data = ` Scrapbook
 
 
 
Index
 
Capture
 
Clean up
 
Help
 
 
Your scrapbook ` if (files.length > 6) { data += `
`; if (pageNum > 1) { data += `
` } else { data += `
` } data += `
${pageNum} of ${Math.ceil(files.length / 6)} `; if (files.length > start + 6) { data += `
` } else { data += `
` } data += `
` } data += `
`; if (files.length === 0) { data += ` Your scrapbook is currently empty.

Storing pictures in your scrapbook makes it easy to add them to your Web pages.

You can add pictures to your scrapbook from TV, a VCR, a video camera, an e-mail message, or another Web page.

Choose Help for instructions. `; } else { if (request_headers.query.addMediaURL) { data += "Choose an image to add to your web page."; } else { data += `You are currently using ${session_data.getScrapbookUsagePercent()}% of your scrapbook storage space. Choose one of your saved images to view it full size.`; } } data += `

` if (files.length > 0) { data += `
` for (let i = start; i < Math.min(files.length, start + 6); i++) { url = "wtv-tricks:/view-scrapbook-image?id=" + files[i]; if (request_headers.query.addMediaURL) { url = decodeURIComponent(request_headers.query.addMediaURL) + "&scrapbookID=" + files[i]; } data += ` ${(i - start + 1) % 3 === 0 ? '' : ''}` } data += `
` } data += `
`;