/phpcms/modules/content/content.php  454行
/**
* 排序
*/
public function listorder() {
  if(isset($_GET['dosubmit'])) {
    $catid = intval($_GET['catid']);
    if(!$catid) showmessage(L('missing_part_parameters'));
    $modelid = $this->categorys[$catid]['modelid'];
    $this->db->set_model($modelid);
    foreach($_POST['listorders'] as $id => $listorder) {
      $this->db->update(array('listorder'=>$listorder),array('id'=>$id));
        //更改推荐排序开始--新添加的
        $r = $this->db->get_one(array('id'=>$id));
        if($r['posids']){
          $this->db_config = pc_base::load_config('database');
          $tablepre = $this->db_config['default']['tablepre'];
          $this->db->table_name = $tablepre."position_data";
          $this->db->update(array('listorder'=>$listorder),array('id'=>$id,modelid=>$modelid));
        }
        //更改推荐排序结束--
    }
    showmessage(L('operation_success'));
  } else {
    showmessage(L('operation_failure'));
  }
}

解决phpcms V9 推荐位无法排序的更多相关文章

  1. 彻底解决phpcms v9升级后,文章发布出现: Mysql 1267错误:MySQL Error : Illegal mix of collations 解决办法

    彻底解决phpcms v9升级后,文章发布出现: MySQL Query : SELECT * FROM `withli_a`.`v9_keyword` WHERE `keyword` = '吼吼' ...

  2. 关于phpcms v9投票模块选项排序listorder设定问题

    关于phpcms v9投票模块选项排序listorder设定问题修改,主要修改了三个文件三处地方. 主要修改三个文件: .phpcms\modules\vote\templates\vote_edit ...

  3. v9 推荐位 排序问题解决办法

    原网站:http://bbs.phpcms.cn/thread-879943-1-1.html 简介: 用phpcms做网站的时候,有些地方要用到推荐位列表,如幻灯片,特别推荐等.有时候因为文章的重要 ...

  4. 解决PhpCms V9后台无法上传图片

    PHPCMS V9 在近期一次更新的版本号(9.4.2)中因为代码推断失误.导致PHPCMS在后台更新文章无法上传图片而导致的bug.在PHPCMS论坛中找到了暂时解决方式,希望PHPCMS官方能尽快 ...

  5. 解决phpcms V9缩略图模糊的方法

    解决V9缩略图模糊/libs/classes/image.class.php注释掉else   imagecopyresized($thumbimg, $srcimg, 0, 0, $psrc_x,  ...

  6. phpcms v9更改后台文章排序的方法

    后台文章排序怎么才可以按自己输入的数字排列?如按4,3,2,1,从大到小排列?实现方法如下: 修改文件: phpcms\modules\content 中的 content.php 代码如下: $da ...

  7. 关于如何解决PHPCMS V9内容搜索显示不全问题解决方案

    站长朋友们都晓得只要是开源的PHP程序都会有漏洞存在.如果想完美的建站就需要自己去研究打补丁了.最近很多站长联系小编咨询用phpcms建站当在首页搜索内容的时候有的居然搜索不到.小编感到很是奇怪于是就 ...

  8. PHPCMS站内搜索功能实现方法汇总,一文解决PHPCMS站内搜索问题

    1,https://blog.csdn.net/hzw19920329/article/details/80110673 点评:phpcms搜索功能实现方法,作者基于PHPCMS做个门户网站实现站内搜 ...

  9. phpcms v9 升级视频云问题推荐位不能添加

    因为使用的是v9的早期版本,后来升级的时候没敢升级数据库,直接使用了老的数据库结构,造成[推荐位]添加不能使用,报告没有thumb列. 查看数据库果然没有,没办法要么添加相关的列,要么禁用上传缩略图. ...

随机推荐

  1. Python读取中文txt文件错误:UnicodeEncodeError: 'gbk' codec can't encode character

    with open(file,'r') as f: line=f.readline() i=1 while line: line=line.decode('utf-8') line=f.readlin ...

  2. 使用GitHub

    1. 进入 1.1 建立账号 打开网站https://github.com/主页上就可以注册.注册之后会有一个简单的帮助文档,在帮组文档上可以下载一个PC客户端(如果是WINDOWS平台,需要.NET ...

  3. 【Networking】gRPC golang 相关资料

    参考资料: Golang gRPC 示例:  http://www.cnblogs.com/YaoDD/p/5504881.html grpc golang学习心得(1)----安装与测试:   ht ...

  4. 【GoLang】GoLang 中 make 与 new的区别

    make.new操作 make用于内建类型(map.slice 和channel)的内存分配.new用于各种类型的内存分配. 内建函数new本质上说跟其它语言中的同名函数功能一样:new(T)分配了零 ...

  5. Git打包文件

    原文: http://gitbook.liuhui998.com/7_5.html 一.打包文件索引 首先, 我们来看一下打包文件索引, 基本上它只是一系列指向打包文件内位置的书签. 打包文件索引有两 ...

  6. [20160704]Addition program that use JOptionPane for input and output

    //Addition program that use JOptionPane for input and output. import javax.swing.JOptionPane; public ...

  7. Delete a node from BST

    Given a root node reference of a BST and a key, delete the node with the given key in the BST. Retur ...

  8. Visual Studio 2013 (vs2013)中“向前定位”,“向后定位”按钮

    Visual Studio 2013 (vs2013)中默认的界面中似乎没有向前向后定位这个非常实用的功能,下面是把它们找出来的方法: 方法1:右键-->工具栏空白处-->最下面,自定义- ...

  9. Node.js 字体格式转换 ttf2eot ttf2woff ttf2svg

    前几天为了查找字体转换工具网上搜索,既然用 Node.js 来做的工具. https://github.com/fontello/ttf2eot https://github.com/fontello ...

  10. UTF8编码转换(C#)

    例如: UTF8---ISO-8859-1 string string = "这是中文";Encoding utf8 = Encoding.UTF8; Encoding ISO = ...