1 / 9

PHP CMS(4) – David

PHP CMS(4) – David. www.dodiphp.cn. PHPCMS教学大纲. 1、产品功能特性简介 2、安装产品并熟悉后台管理操作 3、模板管理与模板技巧 4、标签的使用 5、项目实训之模板嵌套 6、会员整合 7、系统安全与二次开发指导实战 8、实训项目验收与点评. 6-1、 会员整合(1). 1)Ucenter添加新应用 2)Phpcms配置(网站配置->通行证 -> Ucenter Client配置). 6-2、 会员整合(2). 1)Ucenter添加新应用. 6-3、 会员整合(3). 2)Phpcms配置.

phila
Download Presentation

PHP CMS(4) – David

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. PHPCMS(4) – David www.dodiphp.cn

  2. PHPCMS教学大纲 • 1、产品功能特性简介 • 2、安装产品并熟悉后台管理操作 • 3、模板管理与模板技巧 • 4、标签的使用 • 5、项目实训之模板嵌套 • 6、会员整合 • 7、系统安全与二次开发指导实战 • 8、实训项目验收与点评

  3. 6-1、会员整合(1) • 1)Ucenter添加新应用 • 2)Phpcms配置(网站配置->通行证 -> Ucenter Client配置)

  4. 6-2、会员整合(2) • 1)Ucenter添加新应用

  5. 6-3、会员整合(3) • 2)Phpcms配置

  6. 6-4、会员整合(4) • 3)Discuz免激活处理:api/uc.php function synlogin() function synlogin($get, $post) { $uid = $get['uid']; $username = $get['username']; $password=$get['password']; if(!API_SYNLOGIN) { return API_RETURN_FORBIDDEN; } require_once $this->appdir.'./forumdata/cache/cache_settings.php'; require_once $this->appdir.'./uc_client/client.php'; $cookietime = 2592000; $discuz_auth_key = md5($_DCACHE['settings']['authkey'].$_SERVER['HTTP_USER_AGENT']); header('P3P: CP="CURa ADMa DEVa PSAo PSDo OUR BUS UNI PUR INT DEM STA PRE COM NAV OTC NOI DSP COR"'); $uid = intval($uid); $query = $this->db->query("SELECT username, uid, password, secques FROM ".$this->tablepre."members WHERE uid='$uid'"); if($member = $this->db->fetch_array($query)) { _setcookie('sid', '', -86400 * 365); _setcookie('cookietime', $cookietime, 31536000); _setcookie('auth', _authcode("$member[password]\t$member[secques]\t$member[uid]", 'ENCODE', $discuz_auth_key), $cookietime); } else { if($data = uc_get_user($username)) { $this->db->query("INSERT INTO ".$this->tablepre."members(uid,username,password,email) VALUES ($uid,'$username','$password','$data[email]')"); $query = $this->db->query("SELECT username, uid, password, secques FROM ".$this->tablepre."members WHERE uid='$uid'"); if($member = $this->db->fetch_array($query)) { _setcookie('sid', '', -86400 * 365); _setcookie('cookietime', $cookietime, 31536000); _setcookie('auth', _authcode("$member[password]\t$member[secques]\t$member[uid]", 'ENCODE', $discuz_auth_key), $cookietime); }else{ _setcookie('cookietime', $cookietime, 31536000); _setcookie('loginuser', $username, $cookietime); _setcookie('activationauth', _authcode($username, 'ENCODE', $discuz_auth_key), $cookietime); } } } }

  7. 6-5、缓存静态化处理(1) • 1)phpcms的静态化处理机制 为了减轻网站负载,提高搜索引擎的友好度, phpcms大多数内容都需要生成HTML,一般的操作如下: 1、更新主页HTML 2、更新栏目与内容页HTML 3、更新专题(可以同时更新了多个类别页、专题页) 4、发布内容、修改内容(发布、修改时会直接生成HTML)

  8. 6-5、缓存静态化处理(2) • 首页 1)网站配置:开启“生成html” 2)更新首页 • 栏目与内容页 1)管理栏目,开启“栏目生成Html”与“内容页生成Html” 2)内容管理-生成HTML-更新栏目页 3)内容管理-生成HTML-更新内容页

  9. 6-5、缓存静态化处理(3) 2)phpcms的php缓存处理机制 网站配置 - 缓存设置

More Related