title: building a string
body: <p>I have this code:</p>
  
  <pre><code>#!/bin/bash
  
  input="./user.cvs"
  
  while IFS=';' read -r f1 f2 f3 f4 f5 f6 f7 f8 f9 f10 f11 f12 f13
  do
  
    path="./QRcodes/$f2$f3.png"
  
    vcard="BEGIN:VCARD%0AN;CHARSET=utf-8:$f3;$f2;;$f1;%0AADR;CHARSET=utf-8;INTL;PARCEL;WORK:;;$f10;$f11;;$f12;$f13%0AEMAIL;INTERNET:$f6%0AORG:$f4%0ATEL;WORK:$f8%0ATEL;FAX;WORK:$f9%0ATITLE:$f5%0AURL;WORK:$f7%0AEND:VCARD"
  
    latex=""
  
    encodedVCard=$(echo "$vcard" | sed -e 's/\+/\%2B/g')
  
    url="http://api.qrserver.com/v1/create-qr-code/?size=300x300&amp;data=$encodedVCard"
  
    wget -O "$path" "$url"
  
    latex+="\n \\begin{tabular}{ C C } \\includegraphics[height=30mm]{graphic.png} &amp; Name \\\\ \\end{tabular}"
  
    echo $latex
  
  done &lt; "$input"
  </code></pre>
  
  <p>Everything works except the 'echo $latex' always prints the same line instead of multiple times. What am I missing?</p>