2 Commits

Author SHA1 Message Date
a4ae21b60f - Update RSS code. 2023-07-19 14:11:06 +02:00
6c119a448f - Update Twiter code. 2022-06-21 11:48:00 +02:00

View File

@@ -1,13 +1,13 @@
<?
// $RCSfile: lmbrowse.php,v $
// $Revision: 1.17 $
// $Name: lmbrowse-1_7_2-1 $
// $Name: lmbrowse-1_7_5-1 $
// $Date: 2016/03/21 16:07:30 $
// $Author: agibert $
/*
* LMBrowse - Langueur Monotone Browser
* Copyright (C) 2012-2020 Arnaud G. GIBERT
* Copyright (C) 2012-2022 Arnaud G. GIBERT
* mailto:arnaud@rx3.net
* http://www.rx3.org/dvp/lmbrowse
*
@@ -41,7 +41,7 @@ $time_start = microtime_float();
include "lmbrowse_config.inc";
$lmb_myname="LMBrowse";
$lmb_tag_tab=explode( " ", "\$Name: lmbrowse-1_7_2-1 $");
$lmb_tag_tab=explode( " ", "\$Name: lmbrowse-1_7_5-1 $");
$lmb_tag_tab=explode( "-", $lmb_tag_tab[1]);
$lmb_myver=strtr( "$lmb_tag_tab[1]-$lmb_tag_tab[2]", "_", ".");
@@ -968,7 +968,7 @@ function lmb_news_tab_get( )
$news_tab[$i]["name"] = "{$play_name}";
$news_tab[$i]["rlink"] = "{$lmb_url_post}?page=play&amp;type={$play_type}&amp;id={$play_id}&amp;priority={$play_priority}";
$news_tab[$i]["alink"] = "http://{$lmb_url_pre}{$news_tab[$i]["rlink"]}";
$news_tab[$i]["rimg"] = lmb_play_path_get( $play_type, $play_id, $play_priority) . "/covers/{$play_id}-cover-1-icon.png";
$news_tab[$i]["rimg"] = "{$lmb_url_post}" . lmb_play_path_get( $play_type, $play_id, $play_priority) . "/covers/{$play_id}-cover-1-icon.png";
$news_tab[$i]["aimg"] = "http://{$lmb_url_pre}{$news_tab[$i]["rimg"]}";
}
else
@@ -1113,6 +1113,7 @@ function lmb_twitter_tab( $skin_path)
ob_start();
echo " <tr class=\"twitter1\">
<td class=\"twitter01\"></td>
<td class=\"twitter0\"></td>
@@ -1121,8 +1122,10 @@ function lmb_twitter_tab( $skin_path)
<tr class=\"twitter1\">
<td class=\"twitter01\">&nbsp;</td>
<td class=\"twitter0\">
<div class=\"button-item\" style=\"display: inline-block; border-radius: 5px;\"><a class=\"twitter-timeline\" href=\"https://twitter.com/langueurmon\" data-widget-id=\"544258336741670912\">Tweets by @langueurmon</a></div>
<script>!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0],p=/^http:/.test(d.location)?'http':'https';if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src=p+\"://platform.twitter.com/widgets.js\";fjs.parentNode.insertBefore(js,fjs);}}(document,\"script\",\"twitter-wjs\");</script>
<a class=\"twitter-timeline\" data-width=\"640\" data-height=\"900\" data-theme=\"dark\" href=\"https://twitter.com/langueurmon?ref_src=twsrc%5Etfw\">Tweets by langueurmon</a>
<script async src=\"https://platform.twitter.com/widgets.js\" charset=\"utf-8\"></script>
</td>
<td class=\"twitter01\">&nbsp;</td>
</tr>
@@ -1134,6 +1137,10 @@ function lmb_twitter_tab( $skin_path)
";
/*
<div class=\"button-item\" style=\"display: inline-block; border-radius: 5px;\"><a class=\"twitter-timeline\" href=\"https://twitter.com/langueurmon\" data-widget-id=\"544258336741670912\">Tweets by @langueurmon</a></div>
<script>!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0],p=/^http:/.test(d.location)?'http':'https';if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src=p+\"://platform.twitter.com/widgets.js\";fjs.parentNode.insertBefore(js,fjs);}}(document,\"script\",\"twitter-wjs\");</script>
echo " <tr class=\"twitter1\">
<td class=\"twitter01\"></td>
<td class=\"twitter1\">AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA</td>
@@ -1406,20 +1413,17 @@ function lmb_rss_page()
header( 'Content-Type: application/rss+xml');
echo "<?xml version=\"1.0\" encoding=\"utf-8\"?>
<rss version=\"2.0\"
xmlns:atom=\"http://www.w3.org/2005/Atom\"
xmlns:dc=\"http://purl.org/dc/elements/1.1/\"
>
<rss version=\"2.0\" xmlns:atom=\"http://www.w3.org/2005/Atom\" xmlns:dc=\"http://purl.org/dc/elements/1.1/\">
<channel>
<title>Langueur Monotone News Page</title>
<link>http://{$lmb_url_pre}/?page=rss</link>
<link>http://{$lmb_url_pre}/</link>
<atom:link href=\"http://{$lmb_url_pre}/?page=rss\" rel=\"self\" type=\"application/rss+xml\" />
<description>Langueur Monotone project news RSS feed</description>
<image>
<url>http://{$lmb_url_pre}/images/lm_logo2-border-220.png</url>
<url>http://{$lmb_url_pre}/skin/images/lm-logo2-border-rss.png</url>
<title>Langueur Monotone News Page</title>
<link>http://{$lmb_url_pre}/?page=rss</link>
<link>http://{$lmb_url_pre}/</link>
</image>
";
@@ -1451,17 +1455,21 @@ xmlns:dc=\"http://purl.org/dc/elements/1.1/\"
if( "{$news_tab[$i]["name"]}" != "")
{
echo " <enclosure url=\"{$news_tab[$i]["aimg"]}\" length=\"".filesize("{$news_tab[$i]["rimg"]}")."\" type=\"picture/png\" />
<link>{$news_tab[$i]["alink"]}</link>
<description>{$news_tab[$i]["alink"]}</description>
";
echo " <enclosure url=\"{$news_tab[$i]["aimg"]}\" length=\"".filesize(".{$news_tab[$i]["rimg"]}")."\" type=\"picture/png\" />
<link>{$news_tab[$i]["alink"]}</link>";
$data = "<table stryle=\"width: 100%;\"><tr><td>{$news_tab[$i]["date"]}: </td><td>{$news_tab[$i]["title"]}</td><td><a href=\"{$news_tab[$i]["alink"]}\">{$news_tab[$i]["name"]}</td><td><a href=\"{$news_tab[$i]["alink"]}\"><img src=\"{$news_tab[$i]["rimg"]}\"/></a></td></tr></table>";
}
else
{
echo " <description>{$news}</description>
";
$data = "<table stryle=\"width: 100%;\"><tr><td>{$news}</td></tr></table>";
}
echo '
<description><![CDATA[<!DOCTYPE html><html><head><meta name="viewport" content="width=device-width, initial-scale=1"><style>table { border-collapse: collapse; width: 100%; border: 0px solid #ddd; color: white; background-color: #333333; font-family: verdana, geneva, lucida, \'lucida grande\', arial, helvetica, sans-serif; font-size: 14px;} th, td { text-align: left; padding: 16px;} a:link { font-weight: bold; color: #6644FF;} a:visited { font-weight: bold; color: #FF00FF;}</style></head><body></br></br></br>';
echo "{$data}";
echo '</br></br></br></body></html>]]></description>
';
echo " </item>
";
}