{"id":875,"date":"2026-01-25T18:57:10","date_gmt":"2026-01-25T18:57:10","guid":{"rendered":"https:\/\/psf.org.bd\/?page_id=875"},"modified":"2026-01-27T20:29:29","modified_gmt":"2026-01-27T20:29:29","slug":"certificate","status":"publish","type":"page","link":"https:\/\/psf.org.bd\/?page_id=875","title":{"rendered":"CERTIFICATE"},"content":{"rendered":"\t\t<div data-elementor-type=\"wp-page\" data-elementor-id=\"875\" class=\"elementor elementor-875\" data-elementor-post-type=\"page\">\n\t\t\t\t<div class=\"elementor-element elementor-element-57f4dd7 e-con-full e-flex e-con e-parent\" data-id=\"57f4dd7\" data-element_type=\"container\" data-e-type=\"container\">\n\t\t\t\t<div class=\"elementor-element elementor-element-40d0d68 elementor-widget elementor-widget-heading\" data-id=\"40d0d68\" data-element_type=\"widget\" data-e-type=\"widget\" data-widget_type=\"heading.default\">\n\t\t\t\t\t<h6 class=\"elementor-heading-title elementor-size-default\">Mordern Certificate Genarator<\/h6>\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t<div class=\"elementor-element elementor-element-b24a412 e-flex e-con-boxed e-con e-parent\" data-id=\"b24a412\" data-element_type=\"container\" data-e-type=\"container\">\n\t\t\t\t\t<div class=\"e-con-inner\">\n\t\t\t\t<div class=\"elementor-element elementor-element-142e929 elementor-widget elementor-widget-html\" data-id=\"142e929\" data-element_type=\"widget\" data-e-type=\"widget\" data-widget_type=\"html.default\">\n\t\t\t\t\t<!DOCTYPE html>\n<html lang=\"en\">\n<head>\n<meta charset=\"UTF-8\">\n<title>PSF Educational Certificate Generator<\/title>\n<meta name=\"viewport\" content=\"width=device-width, initial-scale=1.0\">\n\n<!-- Fonts -->\n<link href=\"https:\/\/fonts.googleapis.com\/css2?family=Poppins:wght@300;400;600;700&family=Pacifico&family=Great+Vibes&display=swap\" rel=\"stylesheet\">\n\n<!-- jsPDF -->\n<script src=\"https:\/\/cdnjs.cloudflare.com\/ajax\/libs\/jspdf\/2.5.1\/jspdf.umd.min.js\"><\/script>\n\n<!-- QR Code -->\n<script src=\"https:\/\/cdnjs.cloudflare.com\/ajax\/libs\/qrcode-generator\/1.4.4\/qrcode.min.js\"><\/script>\n\n<style>\nbody{font-family:'Poppins',sans-serif;background:#f0f4f8;margin:0;padding:0;}\n\n\/* LOCK OVERLAY *\/\n#lockOverlay{\n    position:fixed;\n    inset:0;\n    background:rgba(0,0,0,0.95);\n    color:#fff;\n    display:flex;\n    justify-content:center;\n    align-items:center;\n    z-index:9999;\n    flex-direction:column;\n}\n#lockOverlay input{\n    padding:10px;\n    font-size:16px;\n    margin-top:10px;\n    width:180px;\n    text-align:center;\n    border:none;\n    border-radius:5px;\n}\n#lockOverlay button{\n    margin-top:10px;\n    padding:10px 20px;\n    font-size:16px;\n    background:#EC008C;\n    border:none;\n    border-radius:5px;\n    color:#fff;\n    font-weight:bold;\n    cursor:pointer;\n}\n#lockOverlay button:hover{opacity:0.9;}\n#errorMsg{margin-top:10px;color:red;font-weight:bold;}\n\n\/* Container & Certificate styling (original code intact) *\/\n.container{max-width:1100px;margin:auto;padding:20px;}\nh1{text-align:center;margin-bottom:20px;color:#111827;}\n.grid{display:grid;grid-template-columns:1fr 1fr;gap:20px;}\n.card{background:#fff;border-radius:12px;padding:20px;box-shadow:0 8px 20px rgba(0,0,0,0.1);}\nlabel{display:block;margin-top:10px;font-size:14px;color:#111827;}\ninput{width:100%;padding:10px;margin-top:6px;border-radius:8px;border:1px solid #cbd5e1;background:#f8fafc;color:#111827;}\nbutton{margin-top:15px;padding:12px 18px;border:none;border-radius:10px;background:#4f46e5;color:#fff;cursor:pointer;font-size:15px;}\nbutton.secondary{background:#16a34a;}\ncanvas{width:100%;border-radius:10px;background:#fff;}\n<\/style>\n<\/head>\n\n<body>\n\n<!-- \ud83d\udd12 PAGE LOCK -->\n<div id=\"lockOverlay\">\n    <h2>Enter Page Access Code<\/h2>\n    <input type=\"password\" id=\"accessCode\" placeholder=\"Enter Code\">\n    <button onclick=\"checkAccess()\">Unlock<\/button>\n    <div id=\"errorMsg\"><\/div>\n<\/div>\n\n<!-- Main Container -->\n<div id=\"pageContent\" style=\"display:none;\">\n<div class=\"container\">\n<h1>\ud83c\udf93 PSF Modern Certificate Generator<\/h1>\n<div class=\"grid\">\n<div class=\"card\">\n<label>Participant Name<\/label>\n<input type=\"text\" id=\"name\">\n<label>Training \/ Program Name<\/label>\n<input type=\"text\" id=\"course\">\n<label>Issue Date<\/label>\n<input type=\"date\" id=\"date\">\n<label>Certificate ID<\/label>\n<input type=\"text\" id=\"cid\" value=\"PSF-2026-001\">\n<label>Organization Logo<\/label>\n<input type=\"file\" id=\"logo\" accept=\"image\/*\">\n<label>Candidate Photo<\/label>\n<input type=\"file\" id=\"photo\" accept=\"image\/*\">\n<label>Watermark Logo<\/label>\n<input type=\"file\" id=\"watermark\" accept=\"image\/*\">\n<button onclick=\"generate()\">Preview Certificate<\/button>\n<button class=\"secondary\" onclick=\"downloadPNG()\">Download PNG<\/button>\n<button class=\"secondary\" onclick=\"downloadPDF()\">Download PDF<\/button>\n<\/div>\n<div class=\"card\">\n<canvas id=\"certificate\" width=\"1000\" height=\"700\"><\/canvas>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n\n<script>\n\/\/ \ud83d\udd11 PAGE ACCESS CODE\nconst PAGE_CODE = \"4313\";\nfunction checkAccess(){\n    const code = document.getElementById(\"accessCode\").value;\n    if(code === PAGE_CODE){\n        document.getElementById(\"lockOverlay\").style.display=\"none\";\n        document.getElementById(\"pageContent\").style.display=\"block\";\n    } else {\n        document.getElementById(\"errorMsg\").innerText=\"\u274c Wrong Code!\";\n    }\n}\ndocument.getElementById(\"accessCode\").addEventListener(\"keypress\", function(e){\n    if(e.key === \"Enter\") checkAccess();\n});\n\n\/\/ ===== Original Certificate Generator JS =====\nconst canvas = document.getElementById('certificate');\nconst ctx = canvas.getContext('2d');\n\n\/\/ Load image as Promise\nfunction loadImage(file){\n  return new Promise((resolve)=>{ if(!file) return resolve(null);\n    const reader = new FileReader();\n    reader.onload = e => {\n      const img = new Image();\n      img.onload = ()=>resolve(img);\n      img.src = e.target.result;\n    };\n    reader.readAsDataURL(file);\n  });\n}\n\n\/\/ Dotted background\nfunction drawDottedBackground(){\n  ctx.fillStyle = '#ffffff';\n  ctx.fillRect(0,0,canvas.width,canvas.height);\n  ctx.fillStyle = '#e0e0e0';\n  const dotSpacing = 15; \/\/ spacing \u0995\u09ae\u09be\u09b2\u09be\u09ae, \u09a1\u099f\u0997\u09c1\u09b2\u09cb \u0998\u09a8 \u09b9\u09ac\u09c7\n  const dotRadius = 1.5; \/\/ \u09a1\u099f radius \u09ac\u09a1\u09bc\u09be\u09b2\u09be\u09ae\n  for(let x=dotSpacing;x<canvas.width;x+=dotSpacing){\n    for(let y=dotSpacing;y<canvas.height;y+=dotSpacing){\n      ctx.beginPath();\n      ctx.arc(x,y,dotRadius,0,Math.PI*2);\n      ctx.fill();\n    }\n  }\n}\n\n\n\/\/ Base design\nasync function baseDesign(){\n  drawDottedBackground();\n  ctx.strokeStyle = '#EC008C';\n  ctx.lineWidth = 12;\n  ctx.beginPath();\n  ctx.moveTo(30,30); ctx.lineTo(970,30);\n  ctx.quadraticCurveTo(980,30,980,40);\n  ctx.lineTo(980,660);\n  ctx.quadraticCurveTo(980,670,970,670);\n  ctx.lineTo(30,670);\n  ctx.quadraticCurveTo(20,670,20,660);\n  ctx.lineTo(20,40);\n  ctx.quadraticCurveTo(20,30,30,30);\n  ctx.stroke();\n  ctx.fillStyle = '#EC008C';\n  ctx.fillRect(30,30,940,120);\n  ctx.fillStyle = '#ffffff';\n  ctx.font = '700 36px Poppins';\n  ctx.textAlign = 'center';\n  ctx.fillText('PROGATI SHEBA FOUNDATION (PSF)',500,90);\n  ctx.font = '700 18px Poppins';\n  ctx.fillText('A Non-Government Organization',500,125);\n  const logoFile = document.getElementById('logo').files[0];\n  const logoImg = await loadImage(logoFile);\n  if(logoImg) ctx.drawImage(logoImg,40,50,100,100);\n}\n\n\/\/ Generate certificate\nasync function generate(){\n  await baseDesign();\n  const name = document.getElementById('name').value || 'Participant Name';\n  const course = document.getElementById('course').value || 'Training Program';\n  const date = document.getElementById('date').value || '';\n  const cid = document.getElementById('cid').value || 'PSF-000';\n  const photoFile = document.getElementById('photo').files[0];\n  const watermarkFile = document.getElementById('watermark').files[0];\n\n  const watermarkImg = await loadImage(watermarkFile);\n  if(watermarkImg){\n    ctx.save();\n    ctx.globalAlpha = 0.1;\n    const w = canvas.width * 0.3;\n    const h = w * (watermarkImg.height \/ watermarkImg.width);\n    ctx.drawImage(watermarkImg,(canvas.width-w)\/2,(canvas.height-h)\/2,w,h);\n    ctx.restore();\n  }\n\n  const photoImg = await loadImage(photoFile);\n  if(photoImg){\n    const radius = 90;\n    const x = canvas.width - 70 - radius*2;\n    const y = 180;\n    ctx.save();\n    ctx.beginPath();\n    ctx.arc(x+radius, y+radius, radius, 0, Math.PI*2,true);\n    ctx.closePath();\n    ctx.clip();\n    ctx.drawImage(photoImg, x, y, radius*2, radius*2);\n    ctx.restore();\n  }\n\n  ctx.textAlign = 'center';\n  ctx.fillStyle = '#111827';\n  ctx.font = '48px Pacifico';\n  ctx.fillText(name,500,280);\n  ctx.font = '400 20px Poppins';\n  ctx.fillText('has successfully completed',500,330);\n  ctx.font = '600 24px Poppins';\n  ctx.fillText(course,500,370);\n\n  const qr = qrcode(0,'M');\n  qr.addData('Certificate ID: '+cid+' | PSF');\n  qr.make();\n  const qrImg = new Image();\n  qrImg.src = qr.createDataURL();\n  await new Promise(res=>qrImg.onload=res);\n  const qrX = 820, qrY = 430;\n  ctx.drawImage(qrImg, qrX, qrY, 120, 120);\n\n  ctx.textAlign='center';\n  ctx.font='400 12px Poppins';\n  ctx.fillStyle='#111827';\n  ctx.fillText('Certificate ID: '+cid, qrX+60, qrY + 140);\n\n  ctx.textAlign='left';\n  ctx.font='400 16px Poppins';\n  ctx.fillText('Date: '+date,80,580);\n  ctx.fillText('Visit: https:\/\/psf.org.bd', 80,605);\n\n  ctx.textAlign='right';\n  ctx.fillStyle = '#111827';\n  ctx.font = '40px Great Vibes';\n  ctx.fillText('Zakir Hossain', 950, 620);\n  ctx.font = '400 16px Poppins';\n  ctx.fillText('Authorized Signatory', 950, 640);\n  ctx.fillText('Progati Sheba Foundation (PSF)', 950, 660);\n}\n\n\/\/ Download functions\nfunction downloadPNG(){\n  const a=document.createElement('a');\n  a.download='PSF-Certificate.png';\n  a.href=canvas.toDataURL('image\/png');\n  a.click();\n}\nfunction downloadPDF(){\n  const { jsPDF } = window.jspdf;\n  const pdf = new jsPDF('l','pt',[canvas.width,canvas.height]);\n  pdf.addImage(canvas.toDataURL('image\/png'),'PNG',0,0,canvas.width,canvas.height);\n  pdf.save('PSF-Certificate.pdf');\n}\n\n\/\/ Initialize blank certificate\nbaseDesign();\n<\/script>\n<\/body>\n<\/html>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t","protected":false},"excerpt":{"rendered":"<p>Mordern Certificate Genarator Certificate Generator | Progati Sheba Foundation PSF Progati Sheba Foundation Digital Certificate Generator Generate Certificate Live Generator Generate Certificate of Progati Sheba Foundation Fill in the participant details and instantly create a professional certificate ready to print or download. Participant Full Name Certificate Title Program \/ Course Name Issue Date Certificate No. [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"class_list":["post-875","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/psf.org.bd\/index.php?rest_route=\/wp\/v2\/pages\/875","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/psf.org.bd\/index.php?rest_route=\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/psf.org.bd\/index.php?rest_route=\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/psf.org.bd\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/psf.org.bd\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=875"}],"version-history":[{"count":76,"href":"https:\/\/psf.org.bd\/index.php?rest_route=\/wp\/v2\/pages\/875\/revisions"}],"predecessor-version":[{"id":1012,"href":"https:\/\/psf.org.bd\/index.php?rest_route=\/wp\/v2\/pages\/875\/revisions\/1012"}],"wp:attachment":[{"href":"https:\/\/psf.org.bd\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=875"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}