بيان عاجل من قناة الشمس عن “ريهام سعيد” .. ما القصة؟


هو ايه حكايه دير سانت كاترين .. الرئيس السيسي يخرج ليتحدث من جديد عنه بأقوى التصريحات ويك عن مكانتهkers


30 مايو, 2025 09:09 م

characteristic replaceOembeds() {
var allEmbeds = document.getElementsByTagName(“OEMBED”);

whereas (allEmbeds.length != 0) {
replaceOembedWithHtml(allEmbeds(0), extractLinkFromOembed(allEmbeds(0)));
allEmbeds = document.getElementsByTagName(“OEMBED”);
}

runYoutubeLazyLoad();

}

characteristic replaceOembedWithHtml(part, sourceData) {
if (sourceData.source.toLowerCase() === “youtube”) {
var html=”

” +
‘ +
‘ +
‘ +
‘ +

‘ +

‘;

replaceElementWithHtml(part, html);
} else if (sourceData.source.toLowerCase() === “instagram”) {
var html=”

‘;

replaceElementWithHtml(part, html);
} else if (sourceData.source.toLowerCase() === “twitter”) {
var html=”

‘;
replaceElementWithHtml(part, html);
} else if (sourceData.source.toLowerCase() === “fb”) {

loadfbApi();

var html=”


replaceElementWithHtml(part, html);
} else {
replaceElementWithHtml(part, “”);
}

}

characteristic extractLinkFromOembed(part) {
return getUrlSource(part.getAttribute(“url”));
}

characteristic getUrlSource(url) {
var ytRegex = /http(?:s?)://(?:www.)?youtu(?:be.com/take a look at?v=|.be/)((w-_)*)(&(amp;)?‌​(w?‌​=)*)?/;
var instaRegex = /(https?://www.)?instagram.com(/p/(w+)/?)/;
var twitterRegex = /twitter.com/.*/disclose(?:es)?/((^/?)+)/;
var fbRegex = /^https?://www.fb.com.*/(video(s)?|take a look at|yarn|posts)(.php?|/).+$/;

if (ytRegex.take a look at(url)) {
return {
source: “Youtube”,
url: url,
identification: ytRegex.exec(url)(1)
};
}

if (instaRegex.take a look at(url)) {
return {
source: “Instagram”,
url: url,
identification: instaRegex.exec(url)(3)
};
}

if (twitterRegex.take a look at(url)) {
return {
source: “Twitter”,
url: url,
identification: twitterRegex.exec(url)(1)
};
}

if (fbRegex.take a look at(url)) {
return {
source: “Facebook”,
url: url,
identification: fbRegex.exec(url)(1)
};

}

return {
source: “Unknown”,
url: url,
identification: “”
};
}

characteristic replaceElementWithHtml(part, html) {
var str = html;
var Obj = part; //any part to be completely changed
if (Obj.outerHTML) { //if outerHTML is supported
Obj.outerHTML = str; ///or not it’s straightforward replacement of complete part with contents of str var
} else { //if outerHTML isn’t supported, there could be a uncommon but crossbrowsered trick
var tmpObj = document.createElement(“div”);
tmpObj.innerHTML = ‘‘;
ObjParent = Obj.parentNode; //Okey, part needs to be parented
ObjParent.replaceChild(tmpObj, Obj); //right here we placing our momentary information as a replacement of our aim, so we can obtain it then and exchange it into whatever we need to exchange to
ObjParent.innerHTML = ObjParent.innerHTML.exchange(‘

‘, str);
}
}
characteristic loadfbApi() {
var js = document.createElement(‘script’);
js.src=”
document.body.appendChild(js);
}
characteristic runYoutubeLazyLoad() {
/// youtube lazyload
var youtube = document.querySelectorAll(“.youtube”);

for (var i = 0; i < youtube.length; i++) { var source = "https://img.youtube.com/vi/" + youtube(i).dataset.embed + "http://192.168.2.55/0.jpg"; var image = new Characterize(); image.src = "https://www.christian-dogma.com/themes/ch/sources/photographs/no.jpg"; image.classList.add('lazyload'); image.setAttribute("information-src", source); image.setAttribute("alt", "youtube"); image.addEventListener("load", characteristic () { youtube(i).appendChild(image); }(i)); youtube(i).addEventListener("click on", characteristic () { var iframe = document.createElement("iframe"); iframe.setAttribute("frameborder", "0"); iframe.setAttribute("allowfullscreen", ""); iframe.setAttribute("src", "https://www.youtube.com/embed/" + this.dataset .embed + "?rel=0&showinfo=0&autoplay=1"); this.innerHTML = ""; this.appendChild(iframe); }); }; }

Source link

Exit mobile version