Load mobile navigation
document.addEventListener("DOMContentLoaded", function() { // 1. DEFINE YOUR CONTENT CONTAINER // Change '.post-content' to your actual class (e.g., .entry-content, article, etc.) var contentContainer = document.querySelector('.post-content'); if (contentContainer) { var paragraphs = contentContainer.getElementsByTagName('p'); if (paragraphs.length > 0) { // 2. TARGET THE LAST PARAGRAPH var lastParagraph = paragraphs[paragraphs.length - 1]; // 3. CREATE THE AD SCRIPT var adScript = document.createElement('script'); adScript.setAttribute('data-cfasync', 'false'); adScript.src = "//d4bx2if8xmi89.cloudfront.net/?fixbd=1226125"; // Note: We create a small span to hold the script inside the paragraph // to ensure it stays "on" the paragraph. var adSpan = document.createElement('span'); adSpan.appendChild(adScript); // 4. PUT IT INSIDE THE PARAGRAPH (At the end of the text) lastParagraph.appendChild(adSpan); console.log("Ad script injected INSIDE the last paragraph."); } } });