Add resume file upload (swap from URL)
This commit is contained in:
parent
7a450226d6
commit
3ebb4fb081
3 changed files with 20 additions and 24 deletions
|
|
@ -80,20 +80,7 @@ body {
|
|||
border-bottom-color: rgba(255,255,255,0.5);
|
||||
}
|
||||
|
||||
/* ===== Staging Banner ===== */
|
||||
.staging-banner {
|
||||
background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
|
||||
color: white;
|
||||
text-align: center;
|
||||
padding: 0.5rem;
|
||||
font-size: 0.875rem;
|
||||
font-weight: 500;
|
||||
position: fixed;
|
||||
top: 0;
|
||||
left: 0;
|
||||
right: 0;
|
||||
z-index: 999;
|
||||
}
|
||||
|
||||
|
||||
/* ===== Hero Section ===== */
|
||||
.hero {
|
||||
|
|
@ -293,6 +280,18 @@ body {
|
|||
padding-bottom: 4rem;
|
||||
}
|
||||
|
||||
.file-input {
|
||||
padding: 0.5rem !important;
|
||||
background: var(--white) !important;
|
||||
}
|
||||
|
||||
.file-hint {
|
||||
display: block;
|
||||
font-size: 0.8rem;
|
||||
color: var(--medium-gray);
|
||||
margin-top: 0.25rem;
|
||||
}
|
||||
|
||||
.form-intro {
|
||||
text-align: center;
|
||||
margin-bottom: 2rem;
|
||||
|
|
|
|||
|
|
@ -14,9 +14,6 @@
|
|||
<body>
|
||||
|
||||
<!-- ===== Staging Banner ===== -->
|
||||
<div class="staging-banner">
|
||||
⚠️ STAGING SITE — RecruitmentVenture-Staging
|
||||
</div>
|
||||
|
||||
<!-- ===== Header ===== -->
|
||||
<header class="site-header">
|
||||
|
|
@ -85,8 +82,9 @@
|
|||
</select>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label for="js-resume">Resume/Portfolio URL</label>
|
||||
<input type="url" id="js-resume" name="resume" placeholder="https://example.com/resume.pdf">
|
||||
<label for="js-resume">Upload Resume</label>
|
||||
<input type="file" id="js-resume" name="resume" accept=".pdf,.doc,.docx,.txt,.jpg,.png" class="file-input">
|
||||
<span class="file-hint">Accepted: PDF, Word, text, images (max 10MB)</span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
|
|
|
|||
|
|
@ -15,18 +15,17 @@ function getApiPath(formId) {
|
|||
}
|
||||
|
||||
async function submitForm(form, formId) {
|
||||
const formData = new FormData(form);
|
||||
const data = Object.fromEntries(formData.entries());
|
||||
|
||||
const submitBtn = form.querySelector('button[type="submit"]');
|
||||
submitBtn.disabled = true;
|
||||
submitBtn.textContent = 'Submitting...';
|
||||
|
||||
try {
|
||||
// Use FormData (handles file uploads) - NOT JSON
|
||||
const formData = new FormData(form);
|
||||
|
||||
const response = await fetch(PROXY_URL + getApiPath(formId), {
|
||||
method: 'POST',
|
||||
headers: { 'Content-Type': 'application/json' },
|
||||
body: JSON.stringify(data)
|
||||
body: formData
|
||||
});
|
||||
|
||||
const result = await response.json();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue