Прост DHS Bookmark Creator

Идеята на това просто php скриптче, е да направи Bookmark Folder с линкове от file.txt.

<?php
//DHS Bookmark Creator by amri

$links="links.txt";//Fail s linkowe
$bookmark="bookmark_links.html";//Kraen rezultat
$bookmark_title="DHS Bookmark- Links";//Zaglawie na bookmark

$fh = fopen($bookmark, 'w') or die("can't open file");
$head="<!DOCTYPE NETSCAPE-Bookmark-file-1>\n<META HTTP-EQUIV='Content-Type' CONTENT='text/html; charset=UTF-8'>
<TITLE>Bookmarks</TITLE>\n<H1>Bookmarks Menu</H1>\n<DT><H3>$bookmark_title</H3><DL><p>\n";
fwrite($fh, $head);

$mFile = file("$links");
foreach ($mFile as $line_num => $line)
{
$line=trim("$line");
$writeline="<DT><A HREF='$line'>$line</A>\n";
fwrite($fh, $writeline);
}

$foot="</DL><p>";
fwrite($fh, $foot);
?>

VN:F [1.9.22_1171]
Rating: 5.0/5 (1 vote cast)
VN:F [1.9.22_1171]
Rating: 0 (from 0 votes)
Прост DHS Bookmark Creator, 5.0 out of 5 based on 1 rating

Вашият коментар

Вашият email адрес няма да бъде публикуван Задължителните полета са отбелязани с *