It looks to me like you entered this somewhere in your mediagalary, but that it got parsed. To because that a tag was wrapped around the URL's. Bit weird is the and that it didn't close the a tag, if it were a parser.
So I ask you, did you nativly pasted this into PHP like:
[php]
<?php
//code here
?>
<?php
//code here
?>
[/php] or did you enter this somewhere in a form in the media galary your using. If you didn't enter it in a form it's still theoraticly possible to style it with ob_start() and output buffer functions, seems unlikely though. You might wanna add what gallery your using.
I have included an attachment of the index.php and some of the main files that can contain The New Lines being parsed into tags somewhere.... I have tried messing with it but no luck. Can someone help
In the form you are uploading your script, look at the HTML source. The form will have an "action" attribute. This points to the form handler. This file is the one thats changing the code you're putting in. Post the file contents here or put it in a text editor and search for nl2br.