gpt-4.1-mini-2025-04-14· OpenAI
WildChat-4.8M (AI2)
generate svg in html
- User
generate svg in html
- Assistant
Certainly! Here's a simple example of an SVG embedded directly within an HTML file:
html<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8" /> <meta name="viewport" content="width=device-width, initial-scale=1" /> <title>SVG Example</title> </head> <body> <h1>Simple SVG Example</h1> <svg width="200" height="200" xmlns="http://www.w3.org/2000/svg" style="border:1px solid #ccc;"> <!-- Draw a red circle --> <circle cx="100" cy="100" r="80" fill="red" /> <!-- Draw a white circle on top --> <circle cx="100" cy="100" r="50" fill="white" /> <!-- Draw a blue rectangle --> <rect x="50" y="150" width="100" height="30" fill="blue" /> <!-- Draw a line --> <line x1="0" y1="0" x2="200" y2="200" stroke="green" stroke-width="2" /> <!-- Text --> <text x="100" y="100" font-family="Arial" font-size="20" fill="black" text-anchor="middle" dy=".3em">SVG</text> </svg> </body> </html>
Other models, same or similar prompt
Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.