How to self-update PHP+MySQL CMS?

后端 未结 6 693
独厮守ぢ
独厮守ぢ 2021-01-31 04:53

I\'m writing a CMS on PHP+MySQL. I want it to be self-updatable (throw one click in admin panel). What are the best practices?
How to compare current version of cms and a ve

6条回答
  •  慢半拍i
    慢半拍i (楼主)
    2021-01-31 05:30

    A slightly more experimental solution could be to use something like the phpsvnclient library.

    With features:

    • List all files in a given SVN repository directory
    • Retrieve a given revision of a file
    • Retrieve the log of changes made in a repository or in a given file between two revisions
    • Get the repository latest revision

    This way you can see if there are new files, removed files or updated files and only change those in your local application.

    I recon this will be a little harder to implement, but the benefit would probably be that it is easier and quicker to add updates to your CMS.

提交回复
热议问题