Is there a way to include a complete stylesheet within the email using PHPs mail()
function to ensure the proper display of styles? I have a large stylesheet, specifically for CKEditor, that I need to include to ensure the correct styling in the email.
EDIT
I know that I could just copy the styles into an inline <style>
tag. However, the CKEditor Style Sheet alone has over 10k lines, so I wouldn't think copying and pasting 10k lines is a good solution. So maybe there is another clever way to do this.
Edit 2: Solution
Using file_get_contents('xyz.css')
is the solution I was looking for. It loads the content of the .css
-file and I can simply wrap it with <style>
and it works.