diff --git a/src/templates.js b/src/templates.js
index c874e0a..a85f1d3 100644
--- a/src/templates.js
+++ b/src/templates.js
@@ -142,7 +142,17 @@ const CSS = `
}
`;
-function layout(title, body, user = null, extraHead = '') {
+const BASE_URL = 'https://careers.bored.investments';
+const DEFAULT_IMAGE = 'https://careersgateway.com.au/wp-content/uploads/2025/06/pexels-photo-1236421-1236421-scaled.jpg';
+const SITE_NAME = 'Careers Gateway Australia';
+
+function layout(title, body, user = null, extraHead = '', meta = {}) {
+ const fullTitle = `${title} — ${SITE_NAME}`;
+ const description = meta.description || 'Your trusted partner for education, migration, recruitment, and career services in Australia. Search CRICOS courses, get expert visa advice, and more.';
+ const image = meta.image || DEFAULT_IMAGE;
+ const url = meta.url ? `${BASE_URL}${meta.url}` : BASE_URL;
+ const type = meta.type || 'website';
+
const navUser = user
? `
`
: ``;
@@ -150,7 +160,28 @@ function layout(title, body, user = null, extraHead = '') {
-${esc(title)} — Careers Gateway Australia
+${esc(fullTitle)}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -420,7 +451,7 @@ function homePage(user) {
- `, user);
+ `, user, '', { url: '/', description: 'Careers Gateway Australia — your trusted partner for education, migration, recruitment, RPL, and visa services. Search 26,000+ CRICOS courses and book a free consultation.', image: 'https://careersgateway.com.au/wp-content/uploads/2025/06/pexels-photo-1236421-1236421-scaled.jpg' });
}
function coursesPage(user, results, params, fromCache, error) {
@@ -428,6 +459,7 @@ function coursesPage(user, results, params, fromCache, error) {
const stateOptions = ['NSW','VIC','QLD','WA','SA','TAS','ACT','NT'];
const levelOptions = [['1','Bachelor Degree'],['2','Master Degree'],['3','Doctoral Degree'],['4','Diploma'],['5','Certificate'],['6','Advanced Diploma'],['7','Graduate Certificate'],['8','Graduate Diploma']];
+ const courseMeta = { url: '/courses', description: 'Search 26,000+ CRICOS-registered courses from Australian universities and colleges. Filter by state, level, and field of study. Free account required to view results.', image: 'https://careersgateway.com.au/wp-content/uploads/2025/06/pexels-photo-1236421-1236421-scaled.jpg' };
return layout('CRICOS Course Search', `
@@ -553,7 +585,7 @@ function coursesPage(user, results, params, fromCache, error) {
- `, user);
+ `, user, '', courseMeta);
}
function registerPage(error, values = {}) {
@@ -591,7 +623,7 @@ function registerPage(error, values = {}) {
- `);
+ `, null, '', { url: '/register', description: 'Create a free Careers Gateway account to access CRICOS course search, save favourites, and book consultations with our expert advisors.' });
}
function loginPage(error, redirect = '') {
@@ -616,13 +648,13 @@ function loginPage(error, redirect = '') {
- `);
+ `, null, '', { url: '/login', description: 'Login to your Careers Gateway account to access CRICOS course search, saved courses, and your consultation history.' });
}
function dashboardPage(user, inquiries) {
const initials = user.full_name.split(' ').map(w => w[0]).join('').toUpperCase().slice(0,2);
return layout('Dashboard', `
-
+
- `, user);
+ `, user, '', { url: '/dashboard', description: 'Your Careers Gateway dashboard — manage course inquiries, saved courses, and your profile.' });
}
function contactPage(user, params = {}, success = false, error = '') {
@@ -761,7 +793,7 @@ function contactPage(user, params = {}, success = false, error = '') {
- `, user);
+ `, user, '', { url: '/contact', description: 'Book a free consultation with Careers Gateway. Our certified experts can help with education, visa, migration, RPL, and skills assessment in Australia.', image: 'https://careersgateway.com.au/wp-content/uploads/elementor/thumbs/career-bijendra-sir-r7juads0rjdgs6e5oqchau1e6jow26qbi4k3ky7bwy.jpg' });
}
function healthInsurancePage(user, konpareKey) {
@@ -808,7 +840,7 @@ function healthInsurancePage(user, konpareKey) {
- `, user);
+ `, user, '', { url: '/health-insurance', description: 'Compare and buy OSHC and OVHC health insurance for international students and visitors in Australia. Powered by Konpare — instant online purchase.', image: 'https://careersgateway.com.au/wp-content/uploads/elementor/thumbs/pexels-photo-7163956-7163956-scaled-r7fvhsbi458lc1m0wz89g7f03sdjg52qxlmabibvpc.jpg' });
}
function servicesPage(user, service) {
@@ -851,7 +883,7 @@ function servicesPage(user, service) {
- `, user);
+ `, user, '', { url: `/services/${service}`, description: page.desc, image: DEFAULT_IMAGE });
}
export { layout, esc, homePage, coursesPage, registerPage, loginPage, dashboardPage, contactPage, healthInsurancePage, servicesPage };