zoukankan      html  css  js  c++  java
  • Tsys如何修改静态页面生成格式

          最近好多人对tsys很感兴趣,其实大家不知道的是tsys的asp版本早就已经停止开发了,为了不想让如此优秀的东西被埋没所以我在tsys的asp版 本的基础上使用PHP重新开发了一个功能更强的cms,名字是blackhand,这个版本保留了tsys所有的优点,另外屏蔽了tsys的缺点,还增加 了诸多很棒的功能,大家如果感兴趣可以看一下.
         另外,因为tsys的asp版本就要求站长会编写asp脚本,同样的,为了灵活性所以呢这个PHP版本就要求站长会写PHP脚本,只有如此才能更灵活,才能用它去做别的cms不敢涉及或永远做不到的功能.这才是tsys的真谛!
    PHP版本的tsys浏览页面:http://hi.baidu.com/see7di/blog/item/4daf1955bd555bc8b745ae93.html
    PHP版本的tsys下载地址:http://download.csdn.net/source/3248406
    Tsys如何修改静态页面生成格式


    一般可不用修改。但如果你想把原来2004/0730/****.htm的格式改成20040730/****.htm 的话,请找到Manage/Include目录下的CreateFile_Fun.asp文件。先找到生成文件逻辑存放路径那一 段的

    以下是代码片段:
    tPath = Directory & \"/\" & Year(AddTime) & \"/\" & Create_id(AddTime)&\"/\"&NewsId & Def_FileExtension

    代码。

    将其修改为:

    以下是代码片段:
    tPath = Directory & \"/\" & Year(AddTime) & Create_id(AddTime)&\"/\"&NewsId & Def_FileExtension

    然后再找到生成文件物理存放路径那一段的

    以下是代码片段:
    tPath = Server.MapPath(Directory)
         If Not Fso.FolderExists(tPath) Then
             Fso.CreateFolder(tPath)
             If Def_CreateNewsFiles_ShowFolderError And Err.Number<>0 Then
                 Response.Write \"执行错误:
    \" & tPath & \"路径不存在,请核对。\"
                 Response.End
             End If
         End If
         tPath=tPath & \"/\" & Year(AddTime)
         If Not Fso.FolderExists(tPath) Then
             Fso.CreateFolder(tPath)
             If Def_CreateNewsFiles_ShowFolderError And Err.Number<>0 Then
                 Response.Write \"执行错误:
    \" & tPath & \"路径不存在,请核对。\"
                 Response.End
             End If
         End If
         tPath=tPath & \"/\" & Create_id(AddTime)
         If Not Fso.FolderExists(tPath) Then
             Fso.CreateFolder(tPath)
             If Def_CreateNewsFiles_ShowFolderError And Err.Number<>0 Then
                 Response.Write \"执行错误:
    \" & tPath & \"路径不存在,请核对。\"
                 Response.End
             End If
         End If
    将其修改为:
    以下是代码片段:
    tPath = Server.MapPath(Directory)
         If Not Fso.FolderExists(tPath) Then
             Fso.CreateFolder(tPath)
             If Def_CreateNewsFiles_ShowFolderError And Err.Number<>0 Then
                 Response.Write \"执行错误:
    \" & tPath & \"路径不存在,请核对。\"
                 Response.End
             End If
         End If
         tPath=tPath & \"/\" & Year(AddTime) & Create_id(AddTime)
         If Not Fso.FolderExists(tPath) Then
             Fso.CreateFolder(tPath)
             If Def_CreateNewsFiles_ShowFolderError And Err.Number<>0 Then
                 Response.Write \"执行错误:
    \" & tPath & \"路径不存在,请核对。\"
                 Response.End
             End If
         End If

  • 相关阅读:
    SQL Server事务执行一半出错是否自动回滚整个事务 【转】
    html5 canvas做的俄罗斯方块
    laravel-admin 模型创建、数据迁移、以及关联模型控制器
    laravel-admin 安装
    Composer 安装时要求输入授权用户名密码?
    查找mysql中未提交的事务
    SSH 登录时出现如下错误:No supported key exchange algorithms
    MySQL运行一段时间后自动停止问题的排查
    浅谈PHP中的数组和JS中的数组
    MySQL中使用group_concat()函数数据被截取(有默认长度限制),谨慎!
  • 原文地址:https://www.cnblogs.com/see7di/p/2240003.html
Copyright © 2011-2022 走看看