ShayanRl commited on
Commit
2cd773c
·
verified ·
1 Parent(s): c2bedb6

Update index.html

Browse files
Files changed (1) hide show
  1. index.html +6 -2
index.html CHANGED
@@ -172,14 +172,18 @@
172
  resultDiv.innerHTML = '<p>Loading...</p>';
173
 
174
  try {
175
- // Using CORS proxy to bypass CORS restrictions
176
- const proxyUrl = 'https://corsproxy.io/?';
177
  const apiUrl = 'https://api.k12jobspot.com/api/Jobs/Search';
178
 
179
  const response = await fetch(proxyUrl + encodeURIComponent(apiUrl), {
180
  method: 'POST',
181
  headers: {
182
  'Content-Type': 'application/json',
 
 
 
 
183
  },
184
  body: JSON.stringify(requestBody)
185
  });
 
172
  resultDiv.innerHTML = '<p>Loading...</p>';
173
 
174
  try {
175
+ // Using free CORS proxy to bypass CORS restrictions
176
+ const proxyUrl = 'https://api.allorigins.win/raw?url=';
177
  const apiUrl = 'https://api.k12jobspot.com/api/Jobs/Search';
178
 
179
  const response = await fetch(proxyUrl + encodeURIComponent(apiUrl), {
180
  method: 'POST',
181
  headers: {
182
  'Content-Type': 'application/json',
183
+ 'Accept': 'application/json',
184
+ 'User-Agent': 'Mozilla/5.0',
185
+ 'Origin': 'https://k12jobspot.com',
186
+ 'Referer': 'https://k12jobspot.com/'
187
  },
188
  body: JSON.stringify(requestBody)
189
  });