正則問題希望朋友幫忙解決

 $a =  "[ms]
        index.title = 魔獸我愛悠閒
        index.keywords = 網頁遊戲,網頁遊戲大全,,新手卡,英雄卡,聯合運營
        index.description = 歡迎加入閒人。
       
        [sgb]
        index.title = 三國幫閒人開始
        index.keywords = 休閒競技
        index.description = 閒人網遊戲";
         $b = '新聞';
         echo  preg_replace("//[ms/]index/.title.*/", "[ms]index.title =".$b,$a);
我想把上面‘[ms]index.title’的數據換成'新聞',可是替換不了

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章