POST TIME:2017-11-12 23:37
@SetSysEnv($this->Fields['typeid'],$this->Fields['typename'],$this->Fields['id'],$this->Fields['title'],'archives'); |
//替換圖片Alt為文檔標題 $this->Fields['body'] = str_ireplace(array('alt=""','alt=\&;\&;'),'',$this->Fields['body']); $this->Fields['body'] = preg_replace("@ [\s]{0,}alt[\s]{0,}=[\&;'\s]{0,}[\s\S]{0,}[\&;'\s] @isU"," ",$this->Fields['body']); $this->Fields['body'] = str_ireplace("<img " ,"<img alt='".$this->Fields['title']."' ",$this->Fields['body']); |