1. xmlrpc_newedit.py

基于 NewEdit 进行PyBlosxom 的内容维护!

This plugin provides some misc method, and it is a xmlrpc plugin, so you need install xmlrpc.py plugin first. This plugin provides these methods, just like:

  • newedit.editCategory you can edit the existing category, if the category is not existed, it'll create a new one
  • newedit.putFile put file to blog
  • newedit.getFileList get file list which you'v uploaded
  • newedit.getSysFile get system file which you can access
  • newedit.getSysFileList get system file list which you can access
  • newedit.putSysFile put system file which you can access

If you want to use putFile function, you should add parameter as blow:

  • newedit_filepath - the path that files will be saved, it's a relative path according to datadir

getSysFile is used to modify some important files just like links.dat, flavour template files, etc. If you want to use this method, you shoud add parameter in config.py as blow:

  • newedit_filelist - is a filename, the content of it is a list of filename that enable accessed via xmlrpc.
    • so if you invoke the method, it'll check the filename in the list first. If existed, you can get the content of the file, and put the new content back via putSysFile. It should be a relative path according to datadir.

For example:

config.py

py['newedit_filepath'] = 'files'
py['newedit_filelist'] = 'filelist.dat'

the structure of directory:

      files/
      entries/   #datadir
         |
         +------ filelist.dat

If the content of the filelist.dat is :

links.dat

thus you can use getSysFile to get the content of the links.dat, and modify it on the remote, then use putSysFile to save the modification.

download the plugins: Upload new attachment "xmlrpc_newedit.py"