CareersForge Academy

Advertisements
Loading LXP…
"; document.getElementById("b-log").addEventListener("click",function(){ var n=document.getElementById("i-name").value.trim();var e=document.getElementById("i-email").value.trim().toLowerCase(); if(n&&e){ fetch('/cf-courses-api.php?action=get_user&email='+encodeURIComponent(e)) .then(function(r){return r.json();}) .then(function(serverUser){ var enrObj={}; if(serverUser && !serverUser.error && serverUser.enrollments){ Object.keys(serverUser.enrollments).forEach(function(k){ var item=serverUser.enrollments[k]; enrObj[k]={prog:item.progress||0, done:item.completed_lessons||[], cert:item.certificate_id||null, super_passed:(item.status==='Completed'||item.progress>=100), final_score:item.final_score||100}; }); } localStorage.setItem("cf_user",JSON.stringify({name:n,email:e,enr:enrObj})); fetch('/cf-courses-api.php',{method:'POST',headers:{'Content-Type':'application/json'},body:JSON.stringify({action:'enroll',email:e,name:n,courseId:'onboarding'})}); window.location.href="?cf=dashboard"; }).catch(function(){ localStorage.setItem("cf_user",JSON.stringify({name:n,email:e,enr:{}})); window.location.href="?cf=dashboard"; }); }else{alert("Preencha todos os campos.");} }); } else if(view==="logout"){localStorage.removeItem("cf_user");window.location.href="?cf=explore";} else if(view==="explore"){ main.innerHTML=getTpl("explore"); drawGrid("grid-pro","Pro"); } else if(view==="academy"){ main.innerHTML=getTpl("academy"); drawGrid("grid-acad","Deg"); } else if(view==="dashboard"){ if(!usr){window.location.href="?cf=login";return;} main.innerHTML=getTpl("dashboard"); var myIds=Object.keys(usr.enr||{}); if(myIds.length===0){document.getElementById("dash-empty").style.display="block";}else{drawGrid("grid-dash","All");} } else if(view==="verify"){ main.innerHTML=getTpl("verify"); document.getElementById("b-verify").addEventListener("click",function(){ var val=document.getElementById("i-cert-id").value.trim().toUpperCase(); var res=document.getElementById("verify-result"); res.style.display="block"; fetch('/cf-courses-api.php?action=verify_cert&id='+encodeURIComponent(val)) .then(function(r){return r.json();}) .then(function(d){ if(d&&d.cert_id){ res.innerHTML="

✅ Valid Official Credential

Student: "+d.name+"
Course ID: "+d.course_id+"
Issue Date: "+d.issue_date+"

"; }else{ res.innerHTML="

❌ Credential Not Found

Please check the ID and try again.

"; } }).catch(function(){ res.innerHTML="

❌ Credential Not Found

Please check the ID and try again.

"; }); }); } else if(view==="course"&&cId){ var cx=null;DB.forEach(function(x){if(x.id===cId)cx=x;}); if(!cx){window.location.href="?cf=explore";return;} var tC=getTpl("course"); tC=rep(tC,"{{PARTNER}}",cx.partner);tC=rep(tC,"{{TITLE}}",cx.title);tC=rep(tC,"{{HOURS}}",cx.hours);tC=rep(tC,"{{TYPE}}",cx.type==="Deg"?"Degree":"Certificate"); main.innerHTML=tC; var s="";cx.ls.forEach(function(l,i){ var isCp=(i+1)%3===0; s+="
"+(i+1)+". "+l.t+""+(isCp?"🎯 Quiz":"")+"
"; }); document.getElementById("syl-list").innerHTML=s; var act=document.getElementById("course-action"); if(usr&&usr.enr[cx.id]){act.innerHTML="Resume Course ➔";}else{ act.innerHTML=""; document.getElementById("b-enr").addEventListener("click",function(){ if(!usr){window.location.href="?cf=login";return;} usr.enr[cx.id]={prog:0,done:[],cert:null,super_passed:false,final_score:null};localStorage.setItem("cf_user",JSON.stringify(usr)); fetch('/cf-courses-api.php',{method:'POST',headers:{'Content-Type':'application/json'},body:JSON.stringify({action:'enroll',email:usr.email,name:usr.name,courseId:cx.id})}); window.location.href="?cf=player&id="+cx.id; }); } } else if(view==="player"&&cId){ if(!usr||!usr.enr||!usr.enr[cId]){window.location.href="?cf=dashboard";return;} var cp=null;DB.forEach(function(x){if(x.id===cId)cp=x;}); if(!cp||!cp.ls||cp.ls.length===0){window.location.href="?cf=dashboard";return;}var en=usr.enr[cId]; if(!en.done) en.done=[];var isSuperQuiz=(lId==="superquiz"); var aL=null; var curIdx=0;if(!isSuperQuiz){ if(lId){cp.ls.forEach(function(x,i){if(x.id===lId){aL=x;curIdx=i;}});} if(!aL){aL=cp.ls[0];curIdx=0;} }var pct=Math.round((en.done.length/cp.ls.length)*100);en.prog=pct;localStorage.setItem("cf_user",JSON.stringify(usr)); var tP=getTpl("player");tP=rep(tP,"{{TITLE}}",cp.title);tP=rep(tP,"{{PCT}}",pct); main.innerHTML=tP;var maxUnlocked=0; cp.ls.forEach(function(item, idx){ if(en.done.indexOf(item.id)!==-1 && maxUnlocked===idx){ maxUnlocked=idx+1; } });var m=""; cp.ls.forEach(function(l,i){ var d=en.done.indexOf(l.id)!==-1; var isCur=(!isSuperQuiz&&aL.id===l.id); var isLocked=(i>maxUnlocked); var isCp=(i+1)%3===0; var icon=d?"✅":(isLocked?"🔒":(isCp?"🎯":"📖")); var link=isLocked?"javascript:alert('Complete as aulas e o Quiz anterior para desbloquear.')":("?cf=player&id="+cp.id+"&l="+l.id); var cls="cf-lesson-link "+(isCur?"cf-active ":"")+(d?"cf-done ":"")+(isLocked?"cf-locked ":""); m+=""+icon+" "+(i+1)+". "+l.t+""; }); document.getElementById("pl-menu").innerHTML=m;var allDone=(en.done.length===cp.ls.length); var sqBtnEl=document.getElementById("pl-superquiz-btn"); if(allDone&&sqBtnEl){ var sqAct=isSuperQuiz?"cf-active ":""; var sqPassed=en.super_passed?"cf-done ":""; sqBtnEl.innerHTML="🏆 Super Quiz Final"+(en.super_passed?"✅ "+(en.final_score||100)+"%":"")+""; }if((en.super_passed||en.prog===100)&&document.getElementById("pl-cert-box")){ document.getElementById("pl-cert-box").innerHTML="🎓 View Certificate"; }var contentEl=document.getElementById("pl-lesson-content"); var actionEl=document.getElementById("pl-action");if(isSuperQuiz){ if(!allDone){ alert("Conclua todas as aulas para liberar o Super Quiz!"); window.location.href="?cf=player&id="+cp.id; return; } var sqData=cp.sq||{passing_score:80, questions:[]}; var sqLockKey="cflock_"+cp.id+"_sq"; var sqSeconds=getLock(sqLockKey);var sqHead="

🏆 Super Quiz Final: "+cp.title+"

Avaliação final do curso. Nota mínima para certificação: "+sqData.passing_score+"%.

";if(sqSeconds>0){ contentEl.innerHTML=sqHead+"

⏳ Período de Revisão Obrigatório

Você não atingiu a nota mínima. Revise as aulas e tente novamente em:

"; actionEl.innerHTML=""; startTimer("cd-timer",sqSeconds,function(){window.location.reload();}); return; }if(en.super_passed){ contentEl.innerHTML=sqHead+"

🎉 Aprovado com "+(en.final_score||100)+"%!

Seu certificado oficial já está emitido.

🎓 Acessar Certificado
"; actionEl.innerHTML=""; return; }var sqQuestions=(sqData.questions&&sqData.questions.length)?sqData.questions:[ {q:"Qual é o principal foco prático deste curso?", options:["Aplicação no mercado real", "Apenas memorização teórica", "Nenhum"], answer:0} ];contentEl.innerHTML=sqHead+buildQuizHtml(sqQuestions); attachQuizEvents(sqQuestions,function(answers){ var cor=0;sqQuestions.forEach(function(q,qi){if(answers[qi]===q.answer)cor++;}); var score=Math.round((cor/sqQuestions.length)*100); if(score>=sqData.passing_score){ en.super_passed=true;en.final_score=score;localStorage.setItem("cf_user",JSON.stringify(usr)); fetch('/cf-courses-api.php',{method:'POST',headers:{'Content-Type':'application/json'},body:JSON.stringify({action:'update_progress',email:usr.email,courseId:cp.id,progress:100,score:score})}).then(function(){ alert("🎉 Parabéns! Você atingiu "+score+"% e foi aprovado no Super Quiz!"); window.location.href="?cf=cert&id="+cp.id; }); }else{ setLock(sqLockKey); alert("Nota obtida: "+score+"%. Mínima exigida: "+sqData.passing_score+"%.\nVocê poderá tentar novamente em 15 minutos."); window.location.reload(); } }); actionEl.innerHTML=""; return; }var isCp=((curIdx+1)%3===0); var isDone=(en.done.indexOf(aL.id)!==-1); var cpData=aL.cp||{passing_score:70, questions:[]}; var cpLockKey="cflock_"+cp.id+"_"+aL.id; var cpSeconds=getLock(cpLockKey);if(aL.html && aL.html.trim()!==""){ contentEl.innerHTML=aL.html; }else{ contentEl.innerHTML="

"+(curIdx+1)+". "+aL.t+"

Bem-vindo a esta aula prática da CareersForge Academy.

"; }if(isCp&&!isDone&&cpSeconds>0){ actionEl.innerHTML="

⏳ Checkpoint Bloqueado

Você não atingiu a pontuação mínima neste exame. Revise as 3 aulas anteriores e aguarde:

"; startTimer("cp-timer",cpSeconds,function(){window.location.reload();}); return; }if(isCp&&!isDone&&cpData.questions&&cpData.questions.length>0){ actionEl.innerHTML="

🎯 Checkpoint Quiz (Aulas "+(curIdx-1)+" a "+(curIdx+1)+")

Nota mínima de corte: "+cpData.passing_score+"%.

"+buildQuizHtml(cpData.questions); attachQuizEvents(cpData.questions,function(answers){ var cor=0;cpData.questions.forEach(function(q,qi){if(answers[qi]===q.answer)cor++;}); var score=Math.round((cor/cpData.questions.length)*100); if(score>=cpData.passing_score){ en.done.push(aL.id);localStorage.setItem("cf_user",JSON.stringify(usr)); var nprog=Math.round((en.done.length/cp.ls.length)*100); fetch('/cf-courses-api.php',{method:'POST',headers:{'Content-Type':'application/json'},body:JSON.stringify({action:'update_progress',email:usr.email,courseId:cp.id,lesson:aL.id,progress:nprog})}).then(function(){ alert("🎉 Aprovado no Checkpoint com "+score+"%! As próximas aulas foram liberadas."); window.location.reload(); }); }else{ setLock(cpLockKey); alert("Nota: "+score+"%. A nota de corte é "+cpData.passing_score+"%.\nRevise as 3 aulas e tente novamente em 15 minutos."); window.location.reload(); } }); return; }if(isDone){ actionEl.innerHTML="
✅ Lesson Completed
"; }else{ actionEl.innerHTML=""; document.getElementById("b-mdone").addEventListener("click",function(){ en.done.push(aL.id);localStorage.setItem("cf_user",JSON.stringify(usr)); var nxt=cp.ls[curIdx+1]; var nprog=Math.round((en.done.length/cp.ls.length)*100); fetch('/cf-courses-api.php',{method:'POST',headers:{'Content-Type':'application/json'},body:JSON.stringify({action:'update_progress',email:usr.email,courseId:cp.id,lesson:aL.id,progress:nprog})}).then(function(){ if(nxt){window.location.href="?cf=player&id="+cp.id+"&l="+nxt.id;} else{window.location.href="?cf=player&id="+cp.id+"&l=superquiz";} }); }); } } else if(view==="cert"&&cId){ if(!usr||!usr.enr||!usr.enr[cId]){window.location.href="?cf=dashboard";return;} var cc=null;DB.forEach(function(x){if(x.id===cId)cc=x;}); var ec=usr.enr[cId]; if(!ec.cert){ec.cert="CERT-"+Math.random().toString(36).substr(2,8).toUpperCase();localStorage.setItem("cf_user",JSON.stringify(usr));}var certUrl=window.location.origin+"/verify/?id="+ec.cert; var shareMsg="Concluí com êxito a certificação de "+cc.title+" na CareersForge Academy com aproveitamento de "+(ec.final_score||100)+"%! Confira minha credencial oficial:"; var feedUrl="https://www.linkedin.com/sharing/share-offsite/?url="+encodeURIComponent(certUrl); var curYear=new Date().getFullYear(); var curMonth=new Date().getMonth()+1; var licUrl="https://www.linkedin.com/profile/add?startTask=CERTIFICATION_NAME&name="+encodeURIComponent(cc.title)+"&organizationName="+encodeURIComponent("CareersForge")+"&issueYear="+curYear+"&issueMonth="+curMonth+"&certUrl="+encodeURIComponent(certUrl)+"&certId="+encodeURIComponent(ec.cert);var tCe=getTpl("cert"); tCe=rep(tCe,"{{NAME}}",usr.name); tCe=rep(tCe,"{{TITLE}}",cc.title); tCe=rep(tCe,"{{GRADE}}",ec.final_score||100); tCe=rep(tCe,"{{DATE}}",new Date().toLocaleDateString("en-US")); tCe=rep(tCe,"{{CERTID}}",ec.cert); tCe=rep(tCe,"{{LINKEDIN_FEED}}",feedUrl); tCe=rep(tCe,"{{LINKEDIN_LICENSE}}",licUrl); tCe=rep(tCe,"{{SHARE_TEXT_ENCODED}}",encodeURIComponent(shareMsg+" "+certUrl)); main.innerHTML=tCe;var btnC=document.getElementById("btn-copy-cert"); if(btnC){ btnC.onclick=function(){ navigator.clipboard.writeText(certUrl); alert("Link do certificado copiado!"); }; } } }function buildQuizHtml(questions){ var h="
"; questions.forEach(function(q,qi){ h+="
"+(qi+1)+". "+q.q+"
"; q.options.forEach(function(opt,oi){ h+=""; }); h+="
"; }); h+="
"; return h; }function attachQuizEvents(questions,callback){ var ans={}; var btns=document.querySelectorAll(".cf-quiz-opt"); btns.forEach(function(b){ b.addEventListener("click",function(){ var qi=this.getAttribute("data-qi"); var oi=parseInt(this.getAttribute("data-oi"),10); ans[qi]=oi; var sibs=document.querySelectorAll(".cf-quiz-opt[data-qi='"+qi+"']"); sibs.forEach(function(s){s.classList.remove("cf-selected");}); this.classList.add("cf-selected"); }); }); document.getElementById("btn-submit-q").addEventListener("click",function(){ if(Object.keys(ans).length!==questions.length){ alert("Responda todas as perguntas antes de enviar."); return; } callback(ans); }); }function startTimer(elId,sec,onEnd){ if(timerInt) clearInterval(timerInt); var el=document.getElementById(elId); function tick(){ if(!el){clearInterval(timerInt);return;} var m=Math.floor(sec/60);var s=sec%60; el.innerText=(m<10?"0"+m:m)+":"+(s<10?"0"+s:s); if(sec<=0){ clearInterval(timerInt); if(onEnd) onEnd(); } sec--; } tick(); timerInt=setInterval(tick,1000); } });

What brings you to CareersForge today?

Select:

91% of learners achieved a positive career outcome

They reported new job opportunities, enhanced skills, and better performance at work after completing a CareersForge certification.

91%

Why learners choose CareersForge

Sarah W.
"CareersForge's reputation for high-quality content allowed me to dive deep into data analysis while managing my daily life."
Noeris B.
"CareersForge restored my confidence and showed me I could dream bigger. It was about believing in my potential again."
Abdullahi M.
"Now I feel much more prepared to take on leadership roles, and I have already started mentoring some of my colleagues."
Anas A.
"Learning with CareersForge expanded my professional experience by giving me access to cutting-edge research and practical tools."