Pregunta

¿Cómo incluyo arrastrar y cambiar el tamaño en un solo elemento?

<head>
<style type="text/css">
  #header { width: 200px; height: 100px; background: blue; }
</style>
<script>
  $(document).ready(function() {
    $("#header").draggable().resizable();
  });
</script>
</head>
<body style="font-size:100%;font-weight:bold;font-style:times" >

    <div id="header">

      <label> Header <input type="text" value="headerBox" /> </label>
      <input type="button" value="submit" id="headerSubmit" name="submit" />
      <input type="reset" value="reset"/>

    </div>

    </body>
    </html>
¿Fue útil?

Solución

Tanto el modo de encadenamiento es compatible con la arrastre y el reacondicionamiento para que pueda simplificar su código en una línea

$(document).ready(function() {

    $("#header").draggable().resizable();
 });

Ver demostración aquí .... MANIFESTACIÓN
Consulte este tutorial para obtener más información .....Arrastrable y rechazable

Otros consejos

$(document).ready(function() {

 $("#header").draggable();
$("#header").resizable();

 }); 

ver si funciona

Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top