Library › Coding AI › Marketing and content
Code an email signature with inline styles only
Practice: Setting limits and rules. About 5 minutes.
About this exercise
Write the HTML for Nadia's email signature. Email clients strip style blocks and classes, so every style must be inline; the layout must be one table exactly 420 pixels wide (no divs or flexbox), with Arial 13px everywhere and her name in #1F6F5C. IT blocks images, so no logo or img tags. Use her new phone number as a tel: link. Put each table row on one line: one code block of at most 12 lines, then under 30 words outside the code.
Common mistakes when you ask AI for this
- Not giving the size. The AI picks its own width, so the signature sprawls on wide screens or wraps on phones. Try: Add: "One table, 420 pixels wide, inline styles only."
- Leaving the layout open. The AI uses divs and flexbox, which fall apart in many email clients. Try: Add: "Table layout, Arial 13px, name in #1F6F5C."
- Not saying images are blocked. The AI adds a logo img and a LinkedIn icon that show as broken boxes. Try: Add: "No images. Use the new phone number as a tel: link."
- Getting a menu of options. The AI likes to offer two or three versions of the signature, so you're left to pick and test them yourself. Try: Add: "Give one signature only, in one code block, no alternatives."
- Getting a tutorial. By default the AI explains every part of the code at length, which you then have to scroll past. Try: Add: "After the code, one line under 12 words. Nothing else."
What a strong prompt includes
- Sets the width
- Asks for a table layout
- Rules out images
- Uses the new number
- Caps the code length
Related exercises
- Add a cron line that matches the others in a crontab (Coding AI · Product managers)
- Add dark mode by overriding your existing CSS variables (Coding AI · Software developers)
- Add input checks to your number guessing game (Coding AI · High school students)
- Add input validation to a Java method with exact messages (Coding AI · Software developers)
- Add labels to a signup form without rewriting the page (Coding AI · High school students)