GoSOLAR Course Schedule Auto Search Method

This method can automatically fill the search form in GoSOLAR course schedule page.

Prepare Bookmarks

Add the three bookmarks below to your browser (e.g., Chrome, Firefox).

  1. Copy the following code. Add a bookmark with Name "GoSOLAR Course Schedule" and paste the code to the URL field.
https://registration.gosolar.gsu.edu/StudentRegistrationSsb/ssb/term/termSelection?mode=search
  1. Copy the following code. Add a bookmark with Name "MathStatUndergrad" and paste the code to the URL field.
javascript:(async()=>{const $=window.jQuery,wait=t=>new Promise(r=>setTimeout(r,t)),norm=s=>String(s||"").replace(/\s+/g," ").trim().toUpperCase(),vis=e=>!!(e&&e.getClientRects().length),subjects=["MATHEMATICS","MATHEMATICS EDUCATION","STATISTICS"];if(!$||!$.fn.select2)return alert("GoSOLAR Select2 is not ready.");async function choose(name,target){if(name==="campus"){let s=[...document.querySelectorAll("select")].find(e=>[...e.options].some(o=>norm(o.textContent)===norm(target)));if(s){s.value=[...s.options].find(o=>norm(o.textContent)===norm(target)).value;s.dispatchEvent(new Event("change",{bubbles:true}));await wait(700);return}}let e=document.getElementById("txt_"+name)||document.querySelector('[name="txt_'+name+'"]');if(!e)throw Error("Cannot find "+name);$(e).select2("open");await wait(300);let input=[...document.querySelectorAll("#s2id_txt_"+name+" .select2-input,.select2-container-active .select2-input,.select2-drop-active .select2-input,.select2-search-field .select2-input")].find(vis);if(!input)throw Error("Cannot find "+name+" search input");$(input).focus().val(target).trigger("input").trigger($.Event("keyup",{which:65,keyCode:65}));for(let i=0;i<50;i++){await wait(200);let o=[...document.querySelectorAll(".select2-drop-active .select2-result-selectable,.select2-container--open .select2-results__option")].find(x=>vis(x)&&norm(x.textContent)===norm(target));if(o){$(o).trigger("mouseup");o.click();await wait(700);return}}throw Error("Cannot select "+target)}try{let d=document.getElementById("txt_level");if(!d)throw Error("Degree field not found");d.value="US";d.dispatchEvent(new Event("change",{bubbles:true}));await wait(1000);let sub=$("#txt_subject");if(!sub.length)throw Error("Subject field not found");sub.select2("val",[]);sub.trigger("change");await wait(500);for(let t of subjects)await choose("subject",t);let selected=$("#txt_subject").select2("data");if(Array.isArray(selected)&&!subjects.every(t=>selected.some(x=>norm(x.text)===t)))throw Error("Not all three subjects were retained");await choose("campus","Atlanta");let b=[...document.querySelectorAll("button,input[type=button],input[type=submit]")].find(x=>vis(x)&&norm(x.textContent||x.value)==="SEARCH");if(!b)throw Error("Search button not found");let start=Date.now(),changes=0;let timer=setInterval(()=>{let s=[...document.querySelectorAll("select.page-size-select")].find(vis);if(Date.now()-start>1500&&s&&s.value!=="50"&&changes<5){s.value="50";s.dispatchEvent(new Event("change",{bubbles:true}));changes++}if(Date.now()-start>20000)clearInterval(timer)},300);b.click()}catch(e){alert("GoSOLAR: "+e.message)}})();
  1. Copy the following code. Add a bookmark with Name "MathStatGrad" and paste the code to the URL field.
javascript:(async()=>{const $=window.jQuery,wait=t=>new Promise(r=>setTimeout(r,t)),norm=s=>String(s||"").replace(/\s+/g," ").trim().toUpperCase(),vis=e=>!!(e&&e.getClientRects().length),subjects=["MATHEMATICS","MATHEMATICS EDUCATION","STATISTICS"];if(!$||!$.fn.select2)return alert("GoSOLAR Select2 is not ready.");async function choose(name,target){if(name==="campus"){let s=[...document.querySelectorAll("select")].find(e=>[...e.options].some(o=>norm(o.textContent)===norm(target)));if(s){s.value=[...s.options].find(o=>norm(o.textContent)===norm(target)).value;s.dispatchEvent(new Event("change",{bubbles:true}));await wait(700);return}}let e=document.getElementById("txt_"+name)||document.querySelector('[name="txt_'+name+'"]');if(!e)throw Error("Cannot find "+name);$(e).select2("open");await wait(300);let input=[...document.querySelectorAll("#s2id_txt_"+name+" .select2-input,.select2-container-active .select2-input,.select2-drop-active .select2-input,.select2-search-field .select2-input")].find(vis);if(!input)throw Error("Cannot find "+name+" search input");$(input).focus().val(target).trigger("input").trigger($.Event("keyup",{which:65,keyCode:65}));for(let i=0;i<50;i++){await wait(200);let o=[...document.querySelectorAll(".select2-drop-active .select2-result-selectable,.select2-container--open .select2-results__option")].find(x=>vis(x)&&norm(x.textContent)===norm(target));if(o){$(o).trigger("mouseup");o.click();await wait(700);return}}throw Error("Cannot select "+target)}try{let d=document.getElementById("txt_level");if(!d)throw Error("Degree field not found");d.value="GS";d.dispatchEvent(new Event("change",{bubbles:true}));await wait(1000);let sub=$("#txt_subject");if(!sub.length)throw Error("Subject field not found");sub.select2("val",[]);sub.trigger("change");await wait(500);for(let t of subjects)await choose("subject",t);let selected=$("#txt_subject").select2("data");if(Array.isArray(selected)&&!subjects.every(t=>selected.some(x=>norm(x.text)===t)))throw Error("Not all three subjects were retained");await choose("campus","Atlanta");let b=[...document.querySelectorAll("button,input[type=button],input[type=submit]")].find(x=>vis(x)&&norm(x.textContent||x.value)==="SEARCH");if(!b)throw Error("Search button not found");let start=Date.now(),changes=0;let timer=setInterval(()=>{let s=[...document.querySelectorAll("select.page-size-select")].find(vis);if(Date.now()-start>1500&&s&&s.value!=="50"&&changes<5){s.value="50";s.dispatchEvent(new Event("change",{bubbles:true}));changes++}if(Date.now()-start>20000)clearInterval(timer)},300);b.click()}catch(e){alert("GoSOLAR: "+e.message)}})();

How to Use

  1. Click the "GoSOLAR Course Schedule" bookmark to open the GoSolar search page. Select the term and click "Continue" to go to the search form.
  2. On the search form page, click either the "MathStatUndergrad" or "MathStatGrad" bookmark depending on whether you are searching for undergraduate or graduate courses. Wait a few seconds for the search results to show.