9/14 What is purpose of selectable


I went through the lesson (9/14) and it worked, but I wonder what the selectable do ?, just to highlight it?.

	<title>Select Ye Favorite</title>
    <link rel='stylesheet' type='text/css' href='stylesheet.css'/>
    <script type='text/javascript' src='script.js'></script>
    <script src="//ajax.googleapis.com/ajax/libs/jqueryui/1.9.1/jquery-ui.min.js"></script>
        <li>Super Mario Bros.</li>
        <li>Legend of Zelda: Link's Awakening</li>
        <li>Kirby's Dream World</li>
        <li>Burger Time</li>
        <li>Pokémon Red</li>
        <li>Pokémon Blue</li>
<div id="appendHere">

I changed script.js like this

$('ol').selectable( {appendTo: "#appendHere"});

Nothing happend after select a element, so how can I do it?


Errr... The issue should be here?

You should only do this:

$(document).ready(function() {

selectable is an event
Hope this helps!:smiles


I want the selected element append to element has id #appendHere, it is why I added > $('ol').selectable( {appendTo: "#appendHere"}); line, but nothing happen.



$( ".selector" ).selectable({
  appendTo: "#someElem"
}); //this will initialize the selectable event

//to get and set the appendTo

// Getter
var appendTo = $( ".selector" ).selectable( "option", "appendTo" );
// Setter
$( ".selector" ).selectable( "option", "appendTo", "#someElem" );


Yeah, I followed this as about code but I don't work.

$( ".selector" ).selectable({
appendTo: "#someElem"
}); //this will initialize the selectable event