Code Monkey home page Code Monkey logo

Comments (4)

e2jk avatar e2jk commented on August 24, 2024

We could add e.g. the letter "s" in front (just picking that one up as it's the first letter of Shaarli). That addresses the - issue for the future, all newly created permalinks will start with an s.

Regarding already existing permalinks, I completely agree should still continue to work. The following should work: keep the old permalink in the database, but display it with an s in front starting today (i.e. if the first character of the permalink is not an "s", add "s" to the HTML code).
People that have the old permalink saved can still access it the old way (maybe not valid, but still working)
People that see the permalink for the first time will see it with an s in front. When a permalink is accessed that couldn't be found in the database, strip the s in front and check if that permalink exists. If so, display the content.

Or this could be implemented the other way around, but would involve updating the database of all old permalinks to add an "s" in front, which may be more complex to address (how/when do you trigger that conversion, as it shouldn't be a process that is done by the user manually)

from shaarli.

nodiscc avatar nodiscc commented on August 24, 2024

@e2jk thanks for your input. Your solution looks good, however I'm not sure at all about how permalink storage is handled in Shaarli.

The developer documentation is basically non-existent (what we have + comments in code) and we've been hacking at the code with an axe so far. The docs were requested at sebsauvage#17

This kind of bug reaally needs @sebsauvage's input.

from shaarli.

nodiscc avatar nodiscc commented on August 24, 2024

I suggest we close this as wontfix.

@Alkarex @BoboTiG @e2jk @Sbgodin @sebsauvage @timovn what do you think?

from shaarli.

e2jk avatar e2jk commented on August 24, 2024

I'm OK with closing.

from shaarli.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.