Comments (3)
The .htaccess is not shipped because we need to set RewriteBase
to the install location, which might not be the web root (so we can't just assume "/").
I think the nested conditionals are confusing PHP because the lack of closures makes the program structure ambiguous. On install the .htaccess is written because it doesn't yet exist, and because the write doesn't fail and trigger an error message, the code flows straight into the else
append statement below. I'll add some closures to sort it out.
Thanks for the report.
from chyrp-lite.
It covers more installation scenarios without user interaction, but clutters the installation code and makes it difficult to ship a hardened and/or cache-optimized .htaccess.
You could leave the RewriteBase
line commented out with instructions in the file and here. For user convenience, there could be a placeholder in the shipped .htaccess (like {{%dir}}
), which gets replaced during the installation, so that the RewriteBase
part looks ~like
Shipped
# Uncomment the next line if chyrp-lite was not installed in the web root
# RewriteBase {{%dir}}
After installing
# Uncomment the next line if chyrp-lite was not installed in the web root
# RewriteBase /path/to/chyrp
Or just skip the commenting and simply replace the placeholder.
from chyrp-lite.
That's a fair point. I don't want to make the user take manual steps, but I can shift the rewrite stuff into an external file with a placeholder and write/append to .htaccess on install. That will allow for the external source to be modified for cache-optimization etc.
I need to give some thought to how this affects the repair function in upgrade.php, and if that even makes sense any more.
from chyrp-lite.
Related Issues (20)
- any user management for chyrp? HOT 1
- ko-fi script shows when opening menu in mobile browser HOT 4
- Posts author HOT 1
- iframe height HOT 2
- Feature Request - Support for icon libraries HOT 8
- Cannot activate account HOT 15
- I cannot see the "likes" column in manage posts HOT 2
- nonstandard spacing around equals sign in chyrplite.net home page HOT 3
- Blog translation HOT 4
- Apache2: Content Encoding Error HOT 1
- Chyrp is Too Wide for my Screen Display HOT 3
- Plugin: Send blog entries to a PubSub nodes HOT 17
- Feature Request: Keep your name/email/website information when commenting instead of always asking HOT 2
- Serving RSS feed as text instead of attachment/download HOT 3
- Site Showing English and French (Only Set for English) HOT 6
- Feature Request: Custom slug for tags HOT 2
- Search multiple keywords results in empty HOT 6
- Feature request: keep the `Category` and `Tags` when switching between tabs when writing a blog HOT 1
- Failed to rename tag which contains Asian characters HOT 6
- Hyperlink issue HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from chyrp-lite.