muhammadsalmanalfaridzi commited on
Commit
e8f939d
·
verified ·
1 Parent(s): 46fc669

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -1
app.py CHANGED
@@ -122,7 +122,10 @@ def export_resume(new_resume):
122
 
123
  # Convert HTML to PDF and save
124
  output_pdf_file = "resumes/optimized_resume.pdf"
125
- HTML(string=html_content).write_pdf(output_pdf_file)
 
 
 
126
 
127
  return output_pdf_file # Return the file path for download
128
  except Exception as e:
 
122
 
123
  # Convert HTML to PDF and save
124
  output_pdf_file = "resumes/optimized_resume.pdf"
125
+ stylesheets = ['resumes/style.css'] # Ensure this path is correct and accessible
126
+
127
+ # Write HTML to PDF with optional styling
128
+ HTML(string=html_content).write_pdf(output_pdf_file, stylesheets=['resumes/style.css'])
129
 
130
  return output_pdf_file # Return the file path for download
131
  except Exception as e: