Releases: zhonglike/MyBlog
MyBlog-V1.7-9beta
V1.7-9beta -- MyBlog's First Version: and Changelog of Previous Versions
==================================================
MyBlog V1.7-9beta Summary Report
Update Date: 2026-06-27
==================================================
I. Project Overview
MyBlog Personal Blog System
Version: V1.7-9beta
Technology Stack: Node.js + Express 5 + SQLite + Cloudflare Tunnel
Port: 3000
Startup Method:
-
Intranet: blogserver.bat (node server.js)
-
External Network: blogI.bat (node (start-tunnel.js + cloudflared)
II. Version V1.7 Major Updates
- Large File Upload Fixes
-
Added multer error handling middleware; upload errors return JSON instead of HTML.
-
Extended server timeout from the default 2 minutes to 10 minutes.
-
Added try-catch and JSON parsing fault tolerance for front-end uploads.
-
Issue: 113MB video upload failed (Timeout / No response)
-
Affected files: src/routes/media.js, server.js, public/js/app.js
- Version Identification
-
Added version number to the footer.
-
Affected file: public/index.html
- Secondary Password Pinning (V1.7-5 beta)
-
Fixed the issue of the secondary password popup being obscured by other popups.
-
Reason: All popups had a z-index of 200; sec-password-modal was positioned earlier in the DOM and was covered by the later-defined popup.
-
Fix:
sec-password-modalindependent z-index: 300, ensuring it's always on top -
Related file: public/css/main.css
- Deep Fix for Large File Uploads (V1.7-7beta)
-
Express 5's
express.json/urlencodedmight interfere with multer's multipart parsing -
Fix: Global body parser skips multipart requests, directly handing them over to multer
-
Added: Diagnostic logs for upload requests (Content-Type / Content-Length)
-
Related files: server.js, src/routes/media.js
- Media Association Fix (V1.7-8beta)
-
Uploaded videos/files were stored with
post_id = NULL, and were not associated after creating a new post -
Added: PUT /api/media/link endpoint, batch updating media's
post_id -
Frontend:
savePostautomatically callsbatchLinkMediato associate uploaded files after creating a new post -
Related files: src/routes/media.js, public/js/app.js
- Video Recognition and Download Functionality (V1.7-9beta)
-
Some browsers misinterpreted filetype as 'file' when uploading videos because the MIME type was not video/*.
-
Fixed: Added getFiletypeByExt() for secondary checking based on file extension (mp4/webm/mov, etc.)
-
Frontend: isVideo/isImage functions now check filetype, MIME type, and file extension simultaneously.
-
Download: Download buttons are now displayed for all attachments at the bottom of post details.
-
Files involved: src/routes/media.js, public/js/app.js
III. Function List
-
User: Login / Register / Primary Password / Secondary Password
-
Posts: Create / Edit / Delete / Markdown Edit / Category / Tag / Pin
-
Media: Image / Video / File Upload/Download / Drag and Drop Upload
-
Display: Dark / Light Cyberpunk - Three Themes
-
Video Pool: Bilibili / YouTube External Link Embedding / Daily Recommendations / Delta Zone
-
Settings: Blog Title / Layout Sorting / Profile / Backup & Export
-
Statistics: Data Dashboard / Browsing History / Personal Homepage
IV. Project Structure
server.js - Main Entry Point (Express 5)
config.js - Global Configuration
start-tunnel.js - Cloudflare Tunnel Startup
cloudflared.exe - Cloudflare Tunnel Client
db/ - SQLite Database
public/ - Front-end Static Files
index.html - Main Page (Footer Version Number)
css/ - Style Files (main.css / theme-*.css)
js/ - JavaScript (app.js / auth.js / theme.js)
src/
routes/ - Backend Routing (auth / posts / media / categories, etc.)
middleware/ - Middleware (auth authentication)
db.js - Database Initialization
uploads/ - Uploaded file storage (images / videos / files)
V. Areas for Optimization
-
Upload progress bar display
-
Large file chunked upload
-
Image compression/thumbnail
-
HTTPS support
-
Mobile adaptation optimization
================================================
== V1.8-1beta Update (2026-06-27) ==
【New】Plyr Video Player
-
Integrated plyr.io CDN (3.7.8), replacing the native
-
Automatically initialize videos in the details page
-
Automatically destroy plyr instances to release resources when closingDetail
【New】Image Lightbox
-
Full-screen viewing of post details images after clicking
-
Support for switching between forward and backward (mouse click/left and right arrow keys)
-
ESC to close
-
My Homepage → Images in the Gallery also use lightboxes
【Modified】Added Plyr cleanup logic to closeDetail
【Modified】Added lightbox overlay and Plyr CSS/JS CDN reference to index.html
【Modified】Added lightbox style to main.css
== V1.8-2beta Update (2026-06-27) ==
【Fixed】The issue of closeDetail not closing in posts containing uploaded files
-
Reason: Plyr destroy or video cleanup may throw an exception blocking display=none
-
Fix: All cleanup operations are now wrapped in try-catch
【Refactoring】Self-displaying search area
-
The search box has been moved from the navigation bar and placed above the main text as an independent search area
-
Search button + Full-text search button side by side
【Added】Title Search (Basic Search)
- The homepage search box only searches post titles, no longer searching the main text/tags
【Added】Full-text Search (Advanced Search)
-
Click "Full-text Search" Expand the input box to search for title + body + tags
-
Added a
fulltextparameter to the backend, corresponding to SQL:title/content/tags LIKE
【New】More Posts Button
-
Added a "More Posts →" button to the bottom of the "Latest" section, paginated (20 posts/page)
-
Added a "More Videos →" button to the bottom of the "Videos" section, paginated
-
Initialize page number to 1, reset when a new search/filter is performed
【Modified】Removed the search box from the navigation bar in index.html, added a search area and a "More" button
【Modified】Added styles to the search area and "More" button in main.css
【Modified】Changed listPosts: search in posts.js to search only for title, added a fulltext parameter to search for title/content/tags
== V1.8-3beta Update (2026-06-27) ==
【New】Separate Search Results Page
-
Hides the main content area after searching, displaying a dedicated search results page
-
Displays search keywords and total matches
-
Supports pagination (More Results →)
-
Click "Close" to restore the main content area
-
Click category filter to automatically close the search results page
== V1.9-1beta Update (2026-06-27) ==
【Major New Feature】AI Smart Assistant
-
Floating 🤖 button in the lower right corner of the page; click to open the AI chat panel
-
One-click switching between four modes:
· 💬 Free Questions — General AI Q&A
· 📰 News Summary — News and Information Compilation
· 🎮 Game Guides — Game Tips and Strategies
· 🔑 Delta Passwords — Delta Operations Strategy/Password Lookup
-
Supports conversation history and loading status indicators
-
Error messages are displayed directly in the panel
【New Feature】AI Configuration Page (Settings → 🤖 AI)
-
Configurable API Address (default https://api.openai.com/v1)
-
API Key Input
-
Model Name (default gpt-3.5-turbo)
-
Supports all OpenAI compatible interfaces
【New】Backend /api/ai/chat interfaces
-
Calls OpenAI compatible APIs and returns AI responses
-
Four system-level role presets for prompt
-
Supports passing dialogue history (last 10 messages)
-
Configuration saved in the settings table
【Modified】Added default AI configuration to config.js
【Modified】Registered AI routes in server.js
== V1.9-2beta Update (2026-06-27) ==
【New】Native support for Google Gemini
-
Settings → 🤖 AI provider switchable: OpenAI compatible / Google Gemini
-
Automatically uses native API format in Gemini mode (no need to fill in API address)
-
Automatically hides API address and model fields after selecting Gemini
-
Recommended models: gemini-2.0-flash / gemini-2.5-flash
Full Changelog: https://github.com/zhonglike/MyBlog/commits/V1