douqin7086 2011-09-19 10:59
浏览 6

在不同的子域周围移动文件

I am currently working on a quite a big project for a client and one of the things that they want is to be able to create new isntances of their software on different sub domains and each using its own database, they want to be able to do this in the most automated way possible. A quick overview of the way a new isntace created is:

  1. A new sub domain is created by one of their administrators by going into thier 123-reg control panel
  2. A new database is created by one of their administrators by going into their 123-reg control panel
  3. They login to an centeral admin panel and fill in a form which then copies over a zip file of the software to the new sub domain and unzips it.
  4. The script then edits the database connection class with the database infromation supplied in the form.
  5. The script then checks the connection and creates the tables
  6. Finally the admin database is updated with the instances new information.

The problem I am having is moving files around different sub domains. For instance the admin panel is at admin.website.com and as an example a new instance might be located at instance.website.com no matter what I try I cannot get a file to move to a different sub domain... Does anyone have a solutions to this? For anyone wondering the directory structure is like so:

  • /public_html/admin/
  • /public_html/instance/
  • /public_html/instance_2/

etc.

  • 写回答

4条回答 默认 最新

  • douying7289 2011-09-19 11:08
    关注

    If you have the appropriate access, could you use the PHP FTP library to move the files over FTP?

    That would mean that it didn't matter if in future instances were on different servers.

    评论

报告相同问题?

悬赏问题

  • ¥60 pb数据库修改或者求完整pb库存系统,需为pb自带数据库
  • ¥15 spss统计中二分类变量和有序变量的相关性分析可以用kendall相关分析吗?
  • ¥15 拟通过pc下指令到安卓系统,如果追求响应速度,尽可能无延迟,是不是用安卓模拟器会优于实体的安卓手机?如果是,可以快多少毫秒?
  • ¥20 神经网络Sequential name=sequential, built=False
  • ¥16 Qphython 用xlrd读取excel报错
  • ¥15 单片机学习顺序问题!!
  • ¥15 ikuai客户端多拨vpn,重启总是有个别重拨不上
  • ¥20 关于#anlogic#sdram#的问题,如何解决?(关键词-performance)
  • ¥15 相敏解调 matlab
  • ¥15 求lingo代码和思路