var filterName = $("#divID").data("option");
$("div.someDiv").on("click",function(){
sendFormGetJSON($(this));
return false;
});
function sendFormGetJSON(e) {
var filterData = e.data("option");
$.ajax({
url: "getJSON.php",
type: "POST",
dataType: "json",
data: {
"filterData":filterData,
},
success: function(data){
setTimeout(function(){
if (data.success == true){
$("#placeReplace").html(data.successMessage);
}else{
alert(data.errorMessage);
}
}, 1000);
},
error: function(){
alert("Произошла ошибка, повторите попытку позже");
}
});
}
Replace `'YOUR_TELEGRAM_BOT_TOKEN'`, `'@yourchannel'`, and `'example.com/rss'` with your own Telegram bot token, Telegram channel ID, and RSS feed URL, respectively.
This bot starts when you send the `/start` command. It then parses the RSS feed and sends a message to the specified Telegram channel if a new article is found. The bot checks for new articles every time the `/start` command is sent.