latex normally generates pdf, you can't put a general html/javascript page in a pdf file. So LaTeX isn't really an issue unless you are not using tex but one of the convertors to html eg tex4ht in which case it would be simple just to add the generated iframe to any html generated from the latex, but that isn't really a latex question.
Here's a possible implementation; the delimiters can be changed.
\documentclass{article}
\usepackage{amsmath,multicol}
\usepackage{xparse}
\ExplSyntaxOn
\NewDocumentCommand{\constraints}{omO{x}}
{
\IfValueTF{#1}{\begin{multicols}{#1}\centering}{\begin{center}}
\egreg_costraints:nn { #2 } { #3 }
\IfValueTF{#1}{\end{multicols}}{\end{center}}
}
\seq_new:N \l__egreg_constraints_seq
\cs_new_protected:Nn \egreg_costraints:nn
{
\seq_set_split:Nnn \l__egreg_constraints_seq { \\ } { #1 }
\seq_map_inline:Nn \l__egreg_constraints_seq
{
\__egreg_constraints_item:nn { ##1 } { #2 }
}
}
\cs_new_protected:Nn \__egreg_constraints_item:nn
{
\tl_if_blank:nF { #1 }
{
$#2\sb{\clist_item:nn { #1 } { 1 }} + #2\sb{\clist_item:nn { #1 } { 2 }}\ge1$ \\
}
}
\ExplSyntaxOff
\begin{document}
\constraints{
1,2 \\ 3,4 \\ 5,6
}
\constraints{
1,2 \\ 3,4 \\ 5,6
}[y]
\constraints[3]{
1,2 \\ 3,4 \\ 5,6 \\
1,2 \\ 3,4 \\ 5,6 \\
1,2 \\ 3,4 \\ 5,6 \\
1,2 \\ 3,4 \\ 5,6 \\
1,2 \\ 3,4 \\ 5,6 \\
1,2 \\ 3,4 \\ 5,6 \\
1,2 \\ 3,4 \\ 5,6 \\
1,2 \\ 3,4 \\ 5,6 \\
1,2 \\ 3,4 \\ 5,6 \\
}
\end{document}
Best Answer
mathURL is pretty cool. It's specifically for mathematics though.