Incrustar la calculadora PetYears

Añade nuestras calculadoras de edad a tu blog de mascotas, sitio de clínica veterinaria o cualquier página. Elige iframe para la configuración más sencilla, o Web Component para una integración más flexible.

Opciones

Personaliza la apariencia mediante parámetros URL (iframe) o atributos (Web Component).

Opción 1: iframe (más sencillo)

Copia el código de abajo y pégalo en el HTML de tu sitio. Funciona en cualquier lugar.

<iframe src="https://petyears.app/en/e/dog/"
        width="100%" height="620" frameborder="0"
        title="PetYears calculator" loading="lazy"
        allow="clipboard-write"></iframe>

Opción 2: Web Component

Incluye nuestro script una vez, luego usa la etiqueta como cualquier elemento HTML. Responsive automático.

<script src="https://petyears.app/embed.js" defer></script>
<petyears-calculator animal="dog" lang="en"></petyears-calculator>

Vista previa

Reference

Animal
iframe:
path segment
Web Comp:
animal
Values:
dog, cat, rabbit, hamster, guinea-pig, horse
Language
iframe:
path segment
Web Comp:
lang
Values:
en, de, fr, it, es, pt, pl
Primary color
iframe:
?primary=2b2d5b
Web Comp:
primary
Values:
hex without #
Background color
iframe:
?bg=e8f5ee
Web Comp:
bg
Values:
hex without #
Accent color
iframe:
?accent=a0d4bc
Web Comp:
accent
Values:
hex without #
Text color
iframe:
?text=1f1d4a
Web Comp:
text
Values:
hex without #
Hide share
iframe:
?hideShare=1
Web Comp:
hide-share
Values:
boolean flag
Height (WC only)
iframe:
iframe height="620"
Web Comp:
height
Values:
pixels (default 620)