不同的更新网站内容的可能方式,以便从一个帐户更新所有用户。

huangapple go评论53阅读模式
英文:

What are the different possible ways of updating content on a website for all users from one account

问题

我将会为未来的一个客户接手一个项目,该项目需要我创建一个系统,让他们能够通过管理员帐户更新网页上的内容,例如欢迎消息或经常更改的信息。我理解其中一种实现方式是从数据库获取信息,然后进行更新等,这个方法将非常有效,但我想知道是否有其他方法可以实现类似的功能,而不使用像WordPress这样的内容管理系统。提前感谢您,如果这个问题不好请谅解,我不经常发帖。

我将尝试我已知的方法,即在数据库中更新消息,除非有更有效的方法。

英文:

I have a project i will be taking on for a client in the future that would require me to make a system where they can update content on the webpage from an admin account, example being like a welcome message or information that would change regularly. I understand one way this could be achieved would be by getting the information from a database and then updating it etc which would work perfectly but i wanted to know if there are other ways to do something like this without using a content management system like WordPress. Thank you in advance and youll have to forgive me if this is a bad question i dont post often.

I will try the approach that i know off which is updating the messages in a database unless there is a more efficient way

答案1

得分: 0

这涉及到项目需求、成本、你的技能,如果你具备编程技能的话。

如果你有足够的时间来开发解决方案,有足够的编程技能来解决技术问题,你的项目需求可能会随时间而变化,你可能需要比现有的CMS系统更多的东西。

作为一种基本的方法,你可以将所有信息放入配置文件中。例如,你可以使用xml文件来存储网页构建信息(如欢迎消息、本地化、标题和说明设置等)。

您可以随时更新这些文件,以满足管理员的要求。这样,你应该跟踪这些文件,避免拥有大量的配置文件,大量的配置文件会导致问题。

另一方面,数据库提供了集中式信息存储。配置本质上也是一种信息。

使用数据库可以获得比配置文件更好的性能,因为你的配置只是有限数量的记录,因此它将帮助你通过将它们缓存在内存中以实现更快的访问,而不是加载文件并知道你应该处理并发问题。

英文:

It's all about the project requirement, costs, your skills, if you have programming skills.

If you have enough time to develop a solution, you have enough programming skills to overcome technical issues, your project requirements may change over time, and you may need something more than available CMS systems.

As a bare-bone approach you can put everything in Configuration files. for example you can use xml files to store your webpage construction info (like welcome message, localization, setting titles and captions and ....).

You can update those files whenever the admin wanted. This way you should keep track of those files. you should prevent of having a large number of config files. huge number of config file throws you in troubles.

databases on the other hand provide centralized information storage. configuration is a piece of information by the way.

Using database you gain better performance vs config files. because of the fact that your configurations are limited number of records so it will help you by caching them in memory for faster access. instead of loading files and knowing that you should take care of concurrency issues.

huangapple
  • 本文由 发表于 2023年4月6日 22:31:54
  • 转载请务必保留本文链接:https://go.coder-hub.com/75950735.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定