本帖最后由 keesky 于 2010-02-10 09:00 编辑
发现你的活动那还有点错位!您可以修改标题的长度或者修改CSS
修改标题长度:找到source/network.php文件
查找代码:- //活动
- include_once(S_ROOT.'./data/data_eventclass.php');
- $cachefile = S_ROOT.'./data/cache_network_event.txt';
- if(check_network_cache('event')) {
- $eventlist = unserialize(sreadfile($cachefile));
- } else {
- $sqlarr = mk_network_sql('event',
- array('eventid', 'uid'),
- array('hot','membernum','follownum'),
- array('dateline'),
- array('dateline','membernum','follownum','hot')
- );
- extract($sqlarr);
- //显示数量
- $shownum = 1;
-
- $eventlist = array();
- $query = $_SGLOBAL['db']->query("SELECT main.*
- FROM ".tname('event')." main
- WHERE ".implode(' AND ', $wherearr)."
- ORDER BY main.{$order} $sc LIMIT 0,$shownum");
- while ($value = $_SGLOBAL['db']->fetch_array($query)) {
- $value['title'] = getstr($value['title'], 45);
- if($value['poster']){
- $value['pic'] = pic_get($value['poster'], $value['thumb'], $value['remote']);
- } else {
- $value['pic'] = $_SGLOBAL['eventclass'][$value['classid']]['poster'];
- }
- $eventlist[] = $value;
- }
- if($_SGLOBAL['network']['event']['cache']) {
- swritefile($cachefile, serialize($eventlist));
- }
- }
- foreach($eventlist as $key => $value) {
- realname_set($value['uid'], $value['username']);
- $eventlist[$key] = $value;
- }
复制代码 修改为- //活动
- include_once(S_ROOT.'./data/data_eventclass.php');
- $cachefile = S_ROOT.'./data/cache_network_event.txt';
- if(check_network_cache('event')) {
- $eventlist = unserialize(sreadfile($cachefile));
- } else {
- $sqlarr = mk_network_sql('event',
- array('eventid', 'uid'),
- array('hot','membernum','follownum'),
- array('dateline'),
- array('dateline','membernum','follownum','hot')
- );
- extract($sqlarr);
- //显示数量
- $shownum = 1;
-
- $eventlist = array();
- $query = $_SGLOBAL['db']->query("SELECT main.*
- FROM ".tname('event')." main
- WHERE ".implode(' AND ', $wherearr)."
- ORDER BY main.{$order} $sc LIMIT 0,$shownum");
- while ($value = $_SGLOBAL['db']->fetch_array($query)) {
- $value['title'] = getstr($value['title'], 20);
- if($value['poster']){
- $value['pic'] = pic_get($value['poster'], $value['thumb'], $value['remote']);
- } else {
- $value['pic'] = $_SGLOBAL['eventclass'][$value['classid']]['poster'];
- }
- $eventlist[] = $value;
- }
- if($_SGLOBAL['network']['event']['cache']) {
- swritefile($cachefile, serialize($eventlist));
- }
- }
- foreach($eventlist as $key => $value) {
- realname_set($value['uid'], $value['username']);
- $eventlist[$key] = $value;
- }
复制代码 $value['title'] = getstr($value['title'], 20);红色字体20为显示标题的长度,20为10个字 |