title: Codeigniter $this->lang->line(errors) without paragraph tags for tank auth error messages
body: <p>I'm wondering if someone can help me with this. I am currently trying to integrate tank auth into my codeigniter site. I am slowly getting there but have run into a minor stumbling block in that when I have moved the error messages from being displayed as part of an html view to a javascript alert they are still printing out the paragraph tags around the error message.</p>
  
  <p>The error messages which are passed to my login form as an array/ or multidimensional array I think are produced in the controller by the following lines of code:</p>
  
  <pre><code>$data['errors'] = array();
  foreach ($errors as $k =&gt; $v)   $data['errors'][$k] = $this-&gt;lang-&gt;line($v);
  </code></pre>
  
  <p>Here is my code for displaying the error messages:</p>
  
  <pre><code>if ((isset($errors[$login['name']]))||(isset($errors[$password['name']]))||(form_error($login['name']))||(form_error($password['name']))){
          echo'&lt;script type="text/javascript"&gt;alert("';
  }
  echo form_error($login['name']);
  echo isset($errors[$login['name']])?$errors[$login['name']]:'';
  echo form_error($password['name']); 
  echo isset($errors[$password['name']])?$errors[$password['name']]:'';
  if ((isset($errors[$login['name']]))||(isset($errors[$password['name']]))||(form_error($login['name']))||(form_error($password['name']))){
          echo'")&lt;/script&gt;';
  }
  </code></pre>
  
  <p>Now my primary question here is how to remove the paragreaph tags ande I have found a clue here in the codeigniter documentation:
  <a href="http://codeigniter.com/user_guide/libraries/file_uploading.html" rel="nofollow">http://codeigniter.com/user_guide/libraries/file_uploading.html</a>
  They key part here is that It says you can set the delimeters for the errors on the upload script by doing this:</p>
  
  <pre><code>$this-&gt;upload-&gt;display_errors('&lt;p&gt;', '&lt;/p&gt;');
  </code></pre>
  
  <p>But I have no idea how and where to apply this to tank auth.</p>
  
  <p>I also have a second question which I would be grateful to anyone who can answer, I am slightly confused by the code for displaying the error messages. For example:</p>
  
  <pre><code>echo form_error($password['name'])
  </code></pre>
  
  <p>can someone explain this to me, it has no $ at the beginning so is not a variable so whats it all about, and the thing I am really trying to get to is how to simplify my logic in checking for the error messages, since it is incredibly long winded at the moment and there are a lot of error messages to handle.</p>
  
  <p>I appreciate there is a lot to deal with here but any help/explainations will be gratefully recieved.</p>