EMI Calculator Embed Code for WordPress

Use the code below to embed the EMI Calculator in your WordPress site. This iframe is optimized for responsive design and will adjust to different screen sizes.

Basic Embed Code

<div style="max-width: 100%; margin: 0 auto;">
  <iframe 
    src="https://emi.ajkerprogram.com/"
    width="100%" 
    height="900px" 
    style="border: none; border-radius: 8px; box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1); max-width: 100%;" 
    title="Loan EMI Calculator" 
    allowfullscreen 
    loading="lazy">
  </iframe>
</div>

Advanced Responsive Embed Code

This code automatically adjusts the iframe height based on screen size and content.

<div style="max-width: 100%; margin: 0 auto;">
  <iframe 
    id="emi-calculator-frame"
    src="https://emi.ajkerprogram.com/"
    width="100%" 
    height="900px"
    style="border: none; border-radius: 8px; box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1); max-width: 100%;" 
    title="Loan EMI Calculator" 
    allowfullscreen 
    loading="lazy">
  </iframe>
</div>

<script>
  // Responsive height adjustment
  function adjustIframeHeight() {
    const iframe = document.getElementById('emi-calculator-frame');
    if (iframe) {
      iframe.style.height = (window.innerWidth < 768) ? '1100px' : '900px';
    }
  }
  
  // Initial adjustment
  window.addEventListener('load', adjustIframeHeight);
  
  // Adjust on resize
  window.addEventListener('resize', adjustIframeHeight);
  
  // Listen for height messages from iframe content
  window.addEventListener('message', function(event) {
    const iframe = document.getElementById('emi-calculator-frame');
    if (iframe && event.data && event.data.type === 'resize') {
      iframe.style.height = (event.data.height + 50) + 'px';
    }
  });
</script>

Instructions

  1. Deploy your EMI Calculator to a hosting service like Vercel.
  2. Replace REPLACE_WITH_YOUR_DEPLOYMENT_URL with your actual deployment URL.
  3. In WordPress, add a "Custom HTML" block and paste the code.
  4. Adjust the height value as needed based on your WordPress theme.