loading...
Share Code Tạo Sitemap Cho Xtgem
- Chuyên mục: Wapmaster
- Lượt xem: 27
- Tình trạng: Hoàn thành
Code này hỗ trợ full các tools post hiện nay như viptruyen, toisv, ttblog, v.v
đầu tiên vào host của bạn tạo file sitemap.txt nhớ là đặt tools ở đâu thì tạo ở đó
rồi vào file post bài của wap bạn tìm đoạn code như này
hoặc
và thay bằng
chú ý thay lại cho đúng cấu trúc link nhé
vậy là pot bài nào thì nó sẽ tự update vào file sitemap wap bạn
đầu tiên vào host của bạn tạo file sitemap.txt nhớ là đặt tools ở đâu thì tạo ở đó
rồi vào file post bài của wap bạn tìm đoạn code như này
curl_exec($ch); } echo 'Thành công'; } }
curl_exec($ch); } echo 'ok'; } }
và thay bằng
curl_exec($ch); } $f = fopen('sitemap.txt',a); fwrite($f,"<url><loc>http://roly.yn.lt/$thumuc/$cmc/$file</loc><changefreq>daily</changefreq></url>"); fclose($f); $sitemap = file_get_contents('./sitemap.txt', true); curl_setopt($ch, CURLOPT_URL, 'http://xtgem.com/filebrowser/file_save?__token='.$token.'&act=edit_file&file=/sitemap.xml'); curl_setopt($ch, CURLOPT_POSTFIELDS, array('value' => cvnokia('<?xml version="1.0" encoding="UTF-8"?> <urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.sitemaps.org/schemas/sitemap/0.9 http://www.sitemaps.org/schemas/sitemap/0.9/sitemap.xsd">'.$sitemap.'</urlset>'), 'submit' => 'Save')); curl_exec($ch); header('Location: http://Tên wap bạn/index?save=ok');}}
chú ý thay lại cho đúng cấu trúc link nhé
vậy là pot bài nào thì nó sẽ tự update vào file sitemap wap bạn
Nguồn: pupy
Search video