好!欢迎访问迷津渡口 现在时间是: 天气 °C ~ °C

迷津渡口

越感到迷惑 越接近真理

修改emlog后台登录路径-含恢复导航方法(亲测)

网络是一个复杂的世界,每个站长还是要学会保护自己。

emlog的默认后台路径是admin目录,非常赤裸的暴露了重要的信息。

修改默认后台路径拢共分三步:

第一步、把文件夹admin改成你想要的的名字,例如cantseeme之类的。

第二步、打开admin/globals.php这个文件,现在可能是cantseeme/globals.php了^_^

修改第9行代码:

define('TEMPLATE_PATH', EMLOG_ROOT.'/admin/views/');

把其中的admin改成你新改的名称cantseeme:

define('TEMPLATE_PATH', EMLOG_ROOT.'/cantseeme/views/');

第三步、刷新后台登录后在导航设置里将 “登录” 隐藏,否则点击会出现404错误多烦人啊~


解决一些后遗症:

1. 改变后台路径后,微语的表情图片无法显示,解决方法:

打开 include/lib/function.base.php , 找到

$t = str_replace($data,'<img title="'.$data.'" src="'.BLOG_URL.'admin/editor/plugins/emoticons/images/'.$emos[$data].'"/>',$t);

替换 admin 为 cantseeme:

$t = str_replace($data,'<img title="'.$data.'" src="'.BLOG_URL.'cantseeme/editor/plugins/emoticons/images/'.$emos[$data].'"/>',$t);


2. 若后台的个人设置里没有上传新头像,则微语头像也无法在前台显示,解决办法:

打开 t/index.php ,找到

$avatar = empty($user_cache[UID]['avatar']) ? '../admin/views/images/avatar.jpg' : '../' . $user_cache[UID]['avatar'];

替换 admin 为 cantseeme:

$avatar = empty($user_cache[UID]['avatar']) ? '../cantseeme/views/images/avatar.jpg' : '../' . $user_cache[UID]['avatar'];

再打开模板里面的 t.php ,即 content/templates/模板名/t.php ,找到

BLOG_URL . 'admin/views/images/avatar.jpg' :

替换 admin 为 cantseeme:

BLOG_URL . 'cantseeme/views/images/avatar.jpg' :


3. 解决模板损坏时“点击返回”按钮的链接问题,默认admin,点击后出错 :

打开 include/lib/view.php ,找到

emMsg('当前使用的模板已被删除或损坏,请登录后台更换其他模板。', BLOG_URL . 'admin/template.php');

替换 admin 为 cantseeme :

emMsg('当前使用的模板已被删除或损坏,请登录后台更换其他模板。', BLOG_URL . 'cantseeme/template.php');


4. 解决文章列表页编辑按钮链接问题,

打开模板的  module.php文件,找到

$editflg = ROLE == ROLE_ADMIN || $author == UID ? '<a href="'.BLOG_URL.'admin/write_log.php?action=edit&gid='.$logid.'" target="_blank">编辑</a>' : '';

替换 admin 为 cantseeme:

$editflg = ROLE == ROLE_ADMIN || $author == UID ? '<a href="'.BLOG_URL.'cantseeme/write_log.php?action=edit&gid='.$logid.'" target="_blank">编辑</a>' : '';


还有一些熊孩子问了,我就想改名字,导航上能保留登录不出错误吗?

小指只想告诉你,人生如此艰难,你还如此任性,不好,不过我喜欢^_^

首先按照本站的这篇文章获取修改默认导航的权限:emlog如何修改默认的导航 | 迷津渡口

然后到后台->导航设置->编辑登录,将路径从 admin 改为新的 cantseeme。

刷新缓存,首页导航 登录 可以使用了!

下一步,修改 管理站点退出 的链接,打开模板的 module.php,找到下面的代码

<li class="item common"><a href="<?php echo BLOG_URL; ?>admin/">管理站点</a></li>
<li class="item common"><a href="<?php echo BLOG_URL; ?>admin/?action=logout">退出</a></li>

你已经知道要做什么了,把admin改为新的路径cantseeme

<li class="item common"><a href="<?php echo BLOG_URL; ?>cantseeme/">管理站点</a></li>
<li class="item common"><a href="<?php echo BLOG_URL; ?>cantseeme/?action=logout">退出</a></li>

刷新缓存,完全正常使用 登录 管理站点退出 三个链接。


好了教程结束,该干啥干啥去吧~

点赞10
   支持一下
挤眼 亲亲 咆哮 开心 想想 可怜 糗大了 委屈 哈哈 小声点 右哼哼 左哼哼 疑问 坏笑 赚钱啦 悲伤 耍酷 勾引 厉害 握手 耶 嘻嘻 害羞 鼓掌 馋嘴 抓狂 抱抱 围观 威武 给力
 点赞
 签到
 表情
 图片
 代码
提交评论

清空信息
关闭评论
kendalfewster
 kendalfewster 约 1 小时前回复
#232
<a href="http://www.cnovas.com/femminile-nike-flynit-air-max-viola-bianca-scarpei">femminile nike flynit air max viola bianca</a> <a href="http://www.omnicitycorp.com/dam%C3%A4nner-nike-flyknit-racer-orangen-gr%C3%BCn-schuhej">dam盲nner nike flyknit racer orangen gr眉n</a> <a href="http://www.cmcheechalk.com/utah-jazz-new-era-nba-2-tone-shone-9twenty-cap-hath">utah jazz new era nba 2 tone shone 9twenty cap</a> <a href="http://www.armandopaz.com/femmes-nike-zoom-pegasus-33-gris-noir-chaussuresh">femmes nike zoom pegasus 33 gris noir</a> <a href="http://www.alrightdesign.com/nike-air-huarache-femminile-bianca-nero-scarpel">nike air huarache femminile bianca nero</a> <a href="http://www.parksindust.com/nike-kobe-7-gold-blue-shoesj">nike kobe 7 gold blue</a>
kendalfewster http://www.kendalfewster.com/
sousoushop
 sousoushop 约 5 小时前回复
#231
<a href="http://www.egyptmaritime.com/adidas-neo-lazy-verde-gituttio-scarpel">adidas neo lazy verde gituttio</a> <a href="http://www.erstube.com/asics-onitsuka-tiger-mexico-66-silver-green-shoesj">asics onitsuka tiger mexico 66 silver green</a> <a href="http://www.thecardplayer.com/air-jordan-retro-2-bl%C3%A5-lyser%C3%B8d-skoi">air jordan retro 2 bl氓 lyser酶d</a> <a href="http://www.theweedaddict.com/femminile-nike-air-max-90-grigio-rosa-scarpeq">femminile nike air max 90 grigio rosa</a> <a href="http://www.thecampingman.com/mens-nike-flyknit-lunar-3-black-red-shoesj">mens nike flyknit lunar 3 black red</a> <a href="http://www.otuzbircek.com/michael-kors-red-leather-handbag-mkh">michael kors red leather handbag</a>
sousoushop http://www.sousoushop.com/
mandydugan
 mandydugan 约 20 小时前回复
#230
<a href="http://www.theskifanatic.com/air-jordan-retro-6-pink-gold-shoesh">air jordan retro 6 pink gold</a> <a href="http://www.bestoftumblr.com/nike-roshe-run-high-rosado-plata-zapatosp">nike roshe run high rosado plata</a> <a href="http://www.thehogrider.com/nike-zoom-pegasus-33-mujeres-amarillo-plata-zapatosk">nike zoom pegasus 33 mujeres amarillo plata</a> <a href="http://www.artpreneure.com/north-face-spring-jacket-mens-northfaceh">north face spring jacket mens</a> <a href="http://www.thefarmergirl.com/herren-asics-gel-kinsei-5-schwarz-orangen-schuhej">herren asics gel kinsei 5 schwarz orangen</a> <a href="http://www.shetablink.com/nike-air-huarache-kvinders-s%C3%B8lv-gr%C3%A5-skoh">nike air huarache kvinders s酶lv gr氓</a>
mandydugan http://www.mandydugan.com/
sevenguard
 sevenguard 约 22 小时前回复
#229
<a href="http://www.sousoushop.com/dam%C3%A4nner-nike-kd-8-gold-gr%C3%BCn-schuhej">dam盲nner nike kd 8 gold gr眉n</a> <a href="http://www.rcfitcamp.com/nike-air-yeezy-2-sort-himmelbl%C3%A5-skoh">nike air yeezy 2 sort himmelbl氓</a> <a href="http://www.milajerdchat.com/nike-air-max-90-em-oranger-noir-chaussuresh">nike air max 90 em oranger noir</a> <a href="http://www.girisweb.com/seattle-seahawks-on-field-hat-hatl">seattle seahawks on field hat</a> <a href="http://www.abcmovieplot.com/nike-lebron-ambassador-9-bleu-ciel-blanc-chaussuresh">nike lebron ambassador 9 bleu ciel blanc</a> <a href="http://www.oldhalliwell.com/air-jordan-retro-14-rosado-gamma-azul-zapatosp">air jordan retro 14 rosado gamma azul</a>
sevenguard http://www.sevenguard.com/
asoseinhalb
 asoseinhalb 2019-05-18 08:58回复
#228
<a href="http://www.forttr.com/nike-dunk-high-pro-sb-sko-svart-svart-r%C3%B8d-10-obuvi">nike dunk high pro sb sko svart svart r酶d 10</a> <a href="http://www.chopkinslaw.com/adidas-ace-16-purecontrol-svart-gullen-obuvk">adidas ace 16 purecontrol svart gullen</a> <a href="http://www.plusbolivia.com/all-r%C3%B8d-nike-air-max-obuvi">all r酶d nike air max</a> <a href="http://www.ahlivv.com/adidas-stan-smith-plata-negro-zapatosl">adidas stan smith plata negro</a> <a href="http://www.bybrettbarner.com/nike-huarache-tutti-rosso-femminile-scarpeh">nike huarache tutti rosso femminile</a> <a href="http://www.timowallets.com/adidas-predator-instinct-black-shoesk">adidas predator instinct black</a>
asoseinhalb http://www.asoseinhalb.com/
tuurulz
 tuurulz 2019-05-18 08:12回复
#227
<a href="http://www.avantajreyonu.com/nike-air-max-90-premium-wei%C3%9F-dam%C3%A4nner-schuhek">nike air max 90 premium wei脽 dam盲nner</a> <a href="http://www.oranjeskishop.com/air-jordan-1-dark-bl%C3%A5-skoi">air jordan 1 dark bl氓</a> <a href="http://www.johannafrost.com/hommes-nike-lunarepic-low-flyknit-gris-noir-blanc-chaussuresh">hommes nike lunarepic low flyknit gris noir blanc</a> <a href="http://www.rolandviet.com/boston-celtics-new-era-nba-city-flag-9fifty-snapback-cap-hatl">boston celtics new era nba city flag 9fifty snapback cap</a> <a href="http://www.classmedya.com/bleu-air-jordan-5-chaussuresh">bleu air jordan 5</a> <a href="http://www.anteageserums.com/nike-air-max-blanco-and-armada-zapatosk">nike air max blanco and armada</a>
tuurulz http://www.tuurulz.com/
playglenlakes
 playglenlakes 2019-05-18 07:06回复
#226
<a href="http://www.bluesophy.com/dam%C3%A4nner-nike-free-run-4.0-wei%C3%9F-schwarz-foota">dam盲nner nike free run 4.0 wei脽 schwarz</a> <a href="http://www.stylehousestl.com/nike-free-5.0-gr%C3%A5-volt-runninga">nike free 5.0 gr氓 volt</a> <a href="http://www.byvergara.com/blanco-negro-oro-jordan-9-scarpef">blanco negro oro jordan 9</a> <a href="http://www.ruthlesscrew.com/nike-air-presto-dark-grigio-lights-runningf">nike air presto dark grigio lights</a> <a href="http://www.fullserviceap.com/nike-free-run-5.0-dam%C3%A4nner-rosa-schuhei">nike free run 5.0 dam盲nner rosa</a> <a href="http://www.idealkizlar.com/south-carolina-gamecocks-new-era-ncaa-black-white-fashion-9fifty-snapback-cap-hath">south carolina gamecocks new era ncaa black white fashion 9fifty snapback cap</a>
playglenlakes http://www.playglenlakes.com/
xlectures
 xlectures 2019-05-18 04:30回复
#225
<a href="http://www.showboxi.com/adidas-prossoator-instinct-astro-turf-scarpeh">adidas prossoator instinct astro turf</a> <a href="http://www.erzincanet.com/adidas-ultra-boost-all-black-uncaged-shoesk">adidas ultra boost all black uncaged</a> <a href="http://www.hoyerequip.com/ray-ban-wayfarer-black-on-black-sunglassesh">ray ban wayfarer black on black</a> <a href="http://www.oreandacasino.com/nike-air-max-2014-hommes-noir-blanc-chaussuresl">nike air max 2014 hommes noir blanc</a> <a href="http://www.floraroja.com/gris-blanc-hommes-adidas-springblade-drive-chaussures-chaussuresl">gris blanc hommes adidas springblade drive chaussures</a> <a href="http://www.dazedkayla.com/nike-air-max-1-wei%C3%9F-schuhej">nike air max 1 wei脽</a>
xlectures http://www.xlectures.com/
prepperdays
 prepperdays 2019-05-17 17:08回复
#224
<a href="http://www.rexpousa.com/nike-internationalist-cool-grau-schuheh">nike internationalist cool grau</a> <a href="http://www.dalvadesign.com/nike-magista-obra-blue-grey-shoesk">nike magista obra blue grey</a> <a href="http://www.velvetwifi.com/nike-huarache-ultra-bl%C3%A5-skol">nike huarache ultra bl氓</a> <a href="http://www.sophiarugby.com/nike-free-5.0-kvinner-rosa-hvit-obuvk">nike free 5.0 kvinner rosa hvit</a> <a href="http://www.thumbglovepro.com/asics-gel-lyte-iii-bianca-grigio-teal-scarpei">asics gel lyte iii bianca grigio teal</a> <a href="http://www.ceracustica.com/air-jordan-2-rojo-and-negro-zapatosh">air jordan 2 rojo and negro</a>
prepperdays http://www.prepperdays.com/
escawinebar
 escawinebar 2019-05-17 17:06回复
#223
<a href="http://www.kanseisc.com/converse-alle-star-lo-sort-skoj">converse alle star lo sort</a> <a href="http://www.pragaoviedo.com/adidas-zx-flux-core-schwarz-gold-schuheh">adidas zx flux core schwarz gold</a> <a href="http://www.turamodenovia.com/nike-air-max-90-women-wholesale-white-grey-shoesk">nike air max 90 women wholesale white grey</a> <a href="http://www.redfiveonline.com/michael-kors-mini-studded-backpack-mkh">michael kors mini studded backpack</a> <a href="http://www.hoangkang.com/nike-free-run-5.0-menn-svart-gr%C3%A5-r%C3%B8d-obuvi">nike free run 5.0 menn svart gr氓 r酶d</a> <a href="http://www.valaseif.com/adidas-tubular-radial-off-bianca-scarpek">adidas tubular radial off bianca</a>
escawinebar http://www.escawinebar.com/
顶部留言底部
 00:00/00:00
我想和你虚度时光 - 花房姑娘(9)
  1. 我想和你虚度时光
  2. 花房姑娘
  3. 恋恋风尘
  4. 我喜爱一切不彻底的事物
  5. 我的心里是满的
  6. Long Way
  7. 给少年的歌
  8. 晴日共剪窗
  9. 天上的月你的脸