duanniling0018 2014-05-07 09:20
浏览 29

仅使用PHP的虚拟页面? [关闭]

I am working on a project that I need to let users to create pages on my server. however, I do not want to let users clutter my mysql database by storing the stuff in there so I cannot use mysql database for creating the pages.

I did research this topic and there seem to be a some sort of a plugin for WP that will allow virtual page creation.

is this possible using pure php WITHOUT the use of any database ?

  • 写回答

1条回答 默认 最新

  • dongniaoli1822 2014-05-07 09:35
    关注

    It's possible, but wrong.

    You can use php to write a html file to your web directory, sure. But that solution is in no way cleaner or less cluttered than putting stuff in your database, for a few reasons:

    • It's easier to have structured information in the database

    • It's a good thing conceptually to separate user data from your program

    • It's easier to control access to your database in a safe way, compared to writing user data to the file system

    "I really do not want to use mysql database" is not a good reason to give this up. You might have a good reason, but it's not easy to guess what that is, which makes suggesting alternatives very difficult.

    评论

报告相同问题?

悬赏问题

  • ¥15 微信小程序协议怎么写
  • ¥15 c语言怎么用printf(“\b \b”)与getch()实现黑框里写入与删除?
  • ¥20 怎么用dlib库的算法识别小麦病虫害
  • ¥15 华为ensp模拟器中S5700交换机在配置过程中老是反复重启
  • ¥15 java写代码遇到问题,求帮助
  • ¥15 uniapp uview http 如何实现统一的请求异常信息提示?
  • ¥15 有了解d3和topogram.js库的吗?有偿请教
  • ¥100 任意维数的K均值聚类
  • ¥15 stamps做sbas-insar,时序沉降图怎么画
  • ¥15 买了个传感器,根据商家发的代码和步骤使用但是代码报错了不会改,有没有人可以看看