Sweetalert: Wie füge ich Javascript-Variablen in die Nachricht ein?

Erstellt am 13. Mai 2016  ·  3Kommentare  ·  Quelle: t4t5/sweetalert

Wie füge ich Javascript-Variablen in die Nachricht ein?

swal({ Titel: „Fehler!“, Text: „Javascript-Variable?“ Typ: „Fehler“, ConfirmButtonText: „Cool“ });

Hilfreichster Kommentar

var myVariable = 'Hello World'; swal({ title: "Error!", text: myVariable, type: "error", confirmButtonText: "Cool" });

Alle 3 Kommentare

var myVariable = 'Hello World'; swal({ title: "Error!", text: myVariable, type: "error", confirmButtonText: "Cool" });

@t4t5 @WeirdestYeti @zenflow wie kann ich die Farbe des Textes bearbeiten, nachdem ich ihm eine Variable zugewiesen habe?

War diese Seite hilfreich?
0 / 5 - 0 Bewertungen

Verwandte Themen

mateuszjarzewski picture mateuszjarzewski  ·  4Kommentare

xgqfrms-GitHub picture xgqfrms-GitHub  ·  4Kommentare

Untit1ed picture Untit1ed  ·  5Kommentare

Lusitaniae picture Lusitaniae  ·  4Kommentare

vmitchell85 picture vmitchell85  ·  6Kommentare