‘jQuery’ Category Archives

24
May

Diltiazem HCI 60mg Pills $141.00

by Lynn Demarest in ASP.NET, jQuery, Miscellaneous, Technical, Web

Comments Off Comments

Non prescription viagra canada The jQueryUI sortable widget works like magic. Non prescription viagra canada Apply it to an HTML DIV that contains other DIVs and you can magically drag and drop the inner DIVs to reorder them on the client. Non prescription viagra canada Say, non prescription viagra canada for example, non prescription viagra canada you have an image gallery and want to allow the site administrator to reorder the images. Non prescription viagra canada Drop the images into the inner DIVs, non prescription viagra canada attach the widget to the outer DIV and you’re done.

Non prescription viagra canada Here’s how:

Non prescription viagra canada 1. Non prescription viagra canada Add jQuery files

Non prescription viagra canada <script type=”text/javascript” src=”//code.jquery.com/jquery-2.1.1.min.js” ></script>

Non prescription viagra canada <script type=”text/javascript” src=”//code.jquery.com/ui/1.10.4/jquery-ui.min.js” ></script>

Non prescription viagra canada <link rel=”stylesheet” href=”//code.jquery.com/ui/1.10.4/themes/smoothness/jquery-ui.css” />

Non prescription viagra canada 2. Non prescription viagra canada Insert startup scripts to make the outer DIV with the ID “sortable” sortable

Non prescription viagra canada <script>

Non prescription viagra canada $(function () {

$(“#sortable”).sortable();

}

Non prescription viagra canada </script>

Non prescription viagra canada 3. Non prescription viagra canada Create the div with the sortable ID. Non prescription viagra canada Put the inner divs inside it.

Non prescription viagra canada <div id=”sortable” >

Non prescription viagra canada <div style=”height:200px;”>
<img id=”ctl00_ContentPlaceHolder1_RIL1_Repeater1_ctl00_Image1″ ImageID=”50″ src=”http://www.mysite.com/donuts.jpg” style=”height:200px;border-width:0px;” />
<input type=”hidden” name=”ids” id=”ids” value=’50′ />
</div>

Non prescription viagra canada <div style=”height:200px;”>
<img id=”ctl00_ContentPlaceHolder1_RIL1_Repeater1_ctl01_Image1″ ImageID=”48″ src=”http://www.mysite.com/BMproduce.jpg” style=”height:200px;border-width:0px;” />
<input type=”hidden” name=”ids” id=”ids” value=’48′ />
</div>
… and so on

Non prescription viagra canada </div> <!– end id=sortable –>

Non prescription viagra canada The thing to notice here is that, non prescription viagra canada instead of trying to use the widget’s fancy UPDATE event to trigger a javascript routine charged with reporting the new image order back to the server, non prescription viagra canada perhaps via AJAX, non prescription viagra canada we instead include in each list element a hidden input field containing the id of the element to be reordered. Non prescription viagra canada When a list item gets dragged to a new position, non prescription viagra canada this hidden field gets dragged along with it.

Non prescription viagra canada Finally, non prescription viagra canada we give all of these hidden fields the same name: ids. Non prescription viagra canada When the form is posted back, non prescription viagra canada the form field named ids contains the keys in order, non prescription viagra canada like this:

Non prescription viagra canada ids=23, non prescription viagra canada43, non prescription viagra canada54, non prescription viagra canada67, non prescription viagra canada65, non prescription viagra canada87, non prescription viagra canada67

Non prescription viagra canada Given these record keys, non prescription viagra canada of course, non prescription viagra canada you can just create SQL statements to update each record’s “SEQ” value. Non prescription viagra canada In other words, non prescription viagra canada set the SEQ of record 23 to 1, non prescription viagra canada set the SEQ of record 43 to 2 and so on.

Non prescription viagra canada Simple!

Non prescription viagra canada  

Average Rating: 4.7 out of 5 based on 157 user reviews.