Fernando Martinez
Fernando Martinez

Reputation: 197

Textarea isn't allowing white spaces

I'm developing a web app with jquery mobile and Bootstrap,however I have a problem with the textarea, I don't know if it's an incompatibility between those 2 javascript libraries. It's strange but I don't found the error in my html code. It's inside jsp file and here is a piece of code:

</div>
        <ul data-role="listview" data-inset="true" data-theme="a" data-content-theme="a" >
            <li data-role='list-divider'>Middleware</li>

            <div class="inner">
        <a href="" class="btn btn-large" id="TeamLeaderMidd">Team Leader: <% out.println(TeamLeaderMidd); %></a>

        <div hiden id="form-TeamLeaderMidd" class="formularios">
            <fieldset class="ui-grid-a">
                <div class="ui-block-a"><input type="text" id="celTeamLeaderMidd" value = <%out.print("\""+ CelTLMid+ "\"");%> disabled></div>
            </fieldset>
            +
            <textarea cols="40" rows="8" name="textarea" id="mensajeTeamLeaderMidd">sas a</textarea><br>
            <div data-role="fieldcontain">
            <fieldset data-role="controlgroup">

                    <input type="radio" name="radio-choice-1" id="radio-choice-1" value="sms" checked="checked" >
                    <label for="radio-choice-1">SMS</label>


            </fieldset>

      <button class="alert-info" onclick="mensajes(celTeamLeaderMidd.value,mensajeTeamLeaderMidd.value)">Enviar!</button>
      </div>
</div>

I can insert chars, numbers and special chars, however I can insert tab space, newline character or space char.

In the header I've the following:

<script src="./jquery-mobile/jquery-1.5.min.js" type="text/javascript"></script>
<script src="./jquery-mobile/jquery.mobile-1.0a3.min.js" type="text/javascript"></script>
<link href="./jquery-mobile/jquery.mobile-1.0a3.min.css" rel="stylesheet" type="text/css">
<link rel="stylesheet" href="./bootstrap/css/bootstrap.css">
<link rel="stylesheet" href="./bootstrap/css/bootstrap-responsive.css">

I deleted the following lines and now works:

<ul data-role="listview" data-inset="true" data-theme="a" data-content-theme="a" >
<li data-role='list-divider'>Middleware</li>

Any one does know why?

Upvotes: 1

Views: 2341

Answers (1)

Fabr&#237;cio Matt&#233;
Fabr&#237;cio Matt&#233;

Reputation: 70169

You have invalid HTML. You didn't close the </ul> in your markup sample.

Put the list back in with </ul> after it.

Upvotes: 1

Related Questions