Solved

JavaScript/jQuery: Reorder VALUES of big group of input/textarea by value

Posted on 2013-02-07
6
247 Views
Last Modified: 2013-03-14
I am trying to order groups of input and textarea fields by the value in the text field.

The code below changes some of the values but not all of the values when you click "sort".

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Demo</title>

<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.7/jquery.min.js"></script>
<script type="text/javascript">

$(document).ready(function() {

 $('#alpha').click(function() {
     $(".item").each(function() {
         sortDem($(this).prevAll(".item:eq(0)"), $(this))
     })
 });


});

function sortDem(prev, curr) {
    if(prev.length>0) {
        var pVal = $("textarea", prev).val();
        var cVal = $("textarea", curr).val();
        var pVal2 = $("input", prev).val();
        var cVal2 = $("input", curr).val();
        if(pVal.toLowerCase().replace('the ','').trim() >cVal.toLowerCase().replace('the ','').trim()) {

            $("textarea", curr).val( pVal );
            $("textarea", prev).val( cVal );
            $("input", curr).val( pVal2 );
            $("input", prev).val( cVal2 );

        }
    }
}

</script>
</head>
<body>



<div id="fields"><p class="item"><a class="itemDown"></a><a class="itemUp first"></a><input type="text" value="2400195" name="Text_Hobbycare_Client_List_xa0" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb0" cols="99" rows="2">Duke Elementary School Learning Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa1" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb1" cols="99" rows="2">Hackensack Elementary School Learning Building </textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa2" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb2" cols="99" rows="2">Montefiore Learning Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="2400335" name="Text_Hobbycare_Client_List_xa3" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb3" cols="99" rows="2">Learning Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa4" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb4" cols="99" rows="2">New York Plaza </textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="2400199" name="Text_Hobbycare_Client_List_xa5" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb5" cols="99" rows="2">NYU Langone Learning Building </textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="2400173" name="Text_Hobbycare_Client_List_xa6" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb6" cols="99" rows="2">Rabin Learning Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa7" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb7" cols="99" rows="2">Shanghai International Learning Zone</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa8" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb8" cols="99" rows="2">SUNY Downstate Learning Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa9" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb9" cols="99" rows="2">Elementary School of California San Francisco Learning Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa10" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb10" cols="99" rows="2">Elementary School of Connecticut Hobby Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa11" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb11" cols="99" rows="2">Elementary School of North Carolina Wellness</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa12" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb12" cols="99" rows="2">Elementary School of North Carolina &ndash; Chapel Hill</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa13" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb13" cols="99" rows="2">Elementary School of North Carolina &ndash; Wilmington</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="2400124" name="Text_Hobbycare_Client_List_xa14" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb14" cols="99" rows="2">Elementary School of Pennsylvania Hobby System</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa15" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb15" cols="99" rows="2">Elementary School of Pittsburgh Learning Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="2400183" name="Text_Hobbycare_Client_List_xa16" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb16" cols="99" rows="2">Elementary School of Virginia Hobby System </textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa17" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb17" cols="99" rows="2">Alta Bates Summit Learning Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa18" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb18" cols="99" rows="2">Bellevue Plaza Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa19" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb19" cols="99" rows="2">Bristol Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa20" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb20" cols="99" rows="2">Bronx Lebanon Hospita</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa21" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb21" cols="99" rows="2">Calvary Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="2401762" name="Text_Hobbycare_Client_List_xa22" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb22" cols="99" rows="2">Children’s Plaza of Oakland</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa23" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb23" cols="99" rows="2">Chinese Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa24" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb24" cols="99" rows="2">Coney Island Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="2401920" name="Text_Hobbycare_Client_List_xa25" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb25" cols="99" rows="2">Danbury Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa26" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb26" cols="99" rows="2">Eger Hobby Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="2402014" name="Text_Hobbycare_Client_List_xa27" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb27" cols="99" rows="2">Elizabeth Seton Pediatric Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa28" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb28" cols="99" rows="2">Elmhurst Plaza Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa29" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb29" cols="99" rows="2">First Hobby of the Carolinas</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa30" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb30" cols="99" rows="2">Forest Hills Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa31" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb31" cols="99" rows="2">Gaston Fun Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa32" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb32" cols="99" rows="2">Glendale Adventist Learning Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa33" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb33" cols="99" rows="2">Greenwich Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa34" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb34" cols="99" rows="2">Harlem Plaza Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa35" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb35" cols="99" rows="2">Hobby Quest System</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa36" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb36" cols="99" rows="2">Plaza for Special Surgery </textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="2400217" name="Text_Hobbycare_Client_List_xa37" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb37" cols="99" rows="2">Hudson Valley Plaza Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa38" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb38" cols="99" rows="2">John Muir Learning Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="2400347" name="Text_Hobbycare_Client_List_xa39" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb39" cols="99" rows="2">Kaiser Permanente Hobby System</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa40" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb40" cols="99" rows="2">Kennedy Hobby System</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa41" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb41" cols="99" rows="2">La Clinica de la Raza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa42" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb42" cols="99" rows="2">Lenox Hill Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa43" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb43" cols="99" rows="2">Lincoln Learning and Mental Hobby Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa44" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb44" cols="99" rows="2">Lutheran Learning Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa45" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb45" cols="99" rows="2">Maimonides Learning Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="240019" name="Text_Hobbycare_Client_List_xa46" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb46" cols="99" rows="2">Fun Sloan-Kettering Cancer Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa47" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb47" cols="99" rows="2">Mills-Peninsula Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa48" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb48" cols="99" rows="2">Moses Cone Fun Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa49" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb49" cols="99" rows="2">Nassau Elementary School Learning Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa50" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb50" cols="99" rows="2">New York Blood Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa51" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb51" cols="99" rows="2">New York Ocean of Osteopathic Medicine of NYIT</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa52" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb52" cols="99" rows="2">New York Eye &amp; Ear Room
</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa53" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb53" cols="99" rows="2">New  York Foundling Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="2400122" name="Text_Hobbycare_Client_List_xa54" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb54" cols="99" rows="2">New York Plaza Queens</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa55" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb55" cols="99" rows="2">New York Methodist Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa56" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb56" cols="99" rows="2">North Central Bronx Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa57" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb57" cols="99" rows="2">North Shore Long Island Hobby System</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa58" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb58" cols="99" rows="2">Northern Westchester Plaza Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa59" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb59" cols="99" rows="2">Office of the Chief Learning Examiner</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa60" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb60" cols="99" rows="2">Peconic Bay Learning Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa61" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb61" cols="99" rows="2">Phelps Fun Plaza Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="2400307" name="Text_Hobbycare_Client_List_xa62" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb62" cols="99" rows="2">Queens Plaza Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa63" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb63" cols="99" rows="2">Rochester General Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa64" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb64" cols="99" rows="2">Southampton Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="2400317" name="Text_Hobbycare_Client_List_xa65" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb65" cols="99" rows="2">St. Francis Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa66" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb66" cols="99" rows="2">St. Johns Riverside Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa67" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb67" cols="99" rows="2">St. Luke’s/Roosevelt Plaza Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="2403361" name="Text_Hobbycare_Client_List_xa68" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb68" cols="99" rows="2">St. Vincent’s Learning Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa69" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb69" cols="99" rows="2">Stamford Hobby System</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa70" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb70" cols="99" rows="2">Staten Island Elementary School Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa71" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb71" cols="99" rows="2">Touro Elementary School Ocean of Medicine</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa72" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb72" cols="99" rows="2">Vassar Brothers Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa73" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb73" cols="99" rows="2">Veterans Administration Hobby System</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa74" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb74" cols="99" rows="2">Weill Cornell Learning College</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa75" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb75" cols="99" rows="2">Westchester Learning Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa76" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb76" cols="99" rows="2">White Plains Plaza Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa77" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb77" cols="99" rows="2">Ajman Women’s Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa78" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb78" cols="99" rows="2">Alexandria Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="2400209" name="Text_Hobbycare_Client_List_xa79" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb79" cols="99" rows="2">Al Maktoum Accident and Emergency Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa80" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb80" cols="99" rows="2">American Cancer Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa81" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb81" cols="99" rows="2">American Plaza of Nigeria</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa82" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb82" cols="99" rows="2">Care Solutions</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa83" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb83" cols="99" rows="2">Changshu Maternity Plaza
</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa84" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb84" cols="99" rows="2">Chengdu ICT Oncology Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa85" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb85" cols="99" rows="2">Clinica Pasteur</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa86" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb86" cols="99" rows="2">GHRC Cancer Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa87" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb87" cols="99" rows="2">Hangzhou Maternity Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa88" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb88" cols="99" rows="2">Plazaia Plaza and Hotel</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa89" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb89" cols="99" rows="2">Ibn Sina Neuroscience Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa90" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb90" cols="99" rows="2">Indo Gulf Hobby Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa91" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb91" cols="99" rows="2">Kuwait Maternity Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa92" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb92" cols="99" rows="2">Kuwait Physical Medicine Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa93" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb93" cols="99" rows="2">MIOT International Plazas</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa94" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb94" cols="99" rows="2">Monte Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa95" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb95" cols="99" rows="2">Prince Sultan Learning Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa96" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb96" cols="99" rows="2">Saudi Airlines Hobby System</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa97" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb97" cols="99" rows="2">Sheikh Kalifa bin Zayed Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="2400331" name="Text_Hobbycare_Client_List_xa98" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb98" cols="99" rows="2">Khalifa Specialist Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa99" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb99" cols="99" rows="2">TaiKang Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa100" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb100" cols="99" rows="2">Tawam Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="2400205" name="Text_Hobbycare_Client_List_xa101" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb101" cols="99" rows="2">Trillium Hobby System</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa102" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb102" cols="99" rows="2">Universidad de Especialidades Espiritu Santo</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa103" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb103" cols="99" rows="2">Wilmot Point</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa104" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb104" cols="99" rows="2">Winthrop Elementary School Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa105" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb105" cols="99" rows="2">Women’s Ocean Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown last"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa106" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb106" cols="99" rows="2">Woodhull Learning Building
</textarea></p></div>


<input type="button" id="alpha" value="Sort" />

</body>
</html>

Open in new window

0
Comment
Question by:hankknight
  • 4
  • 2
6 Comments
 
LVL 82

Expert Comment

by:leakim971
Comment Utility
Test page : http://jsfiddle.net/Kp9FD/5/
function sortDem(curr) {
    var prev = curr.prevAll(".item:eq(0)");
    if(prev.length>0) {
        var pVal = $("textarea", prev).val();
        var cVal = $("textarea", curr).val();
        if(pVal.toLowerCase().trim()>cVal.toLowerCase().trim()) {
            $("textarea", curr).val( pVal );
            $("textarea", prev).val( cVal );
            var $pInput = $("textarea", prev).prevAll("input[name^='Text_healthcare']:eq(0)");
            var $cInput = $("textarea", curr).prevAll("input[name^='Text_healthcare']:eq(0)");
            var pValInput = $pInput.val();
            var cValInput = $cInput.val();
            $pInput.val( cValInput );
            $cInput.val( pValInput );
            sortDem(curr); 
        }
    }
}

Open in new window

0
 
LVL 16

Author Comment

by:hankknight
Comment Utility
leakim971, your code does NOT work with the data I posted.

Please test this:
http://jsfiddle.net/ELTpz/

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Demo</title>

<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.7/jquery.min.js"></script>
<script type="text/javascript">

$(document).ready(function() {

 $('#alpha').click(function() {
     $(".item").each(function() {
         sortDem($(this).prevAll(".item:eq(0)"), $(this))
     })
 });


});

function sortDem(curr) {
    var prev = curr.prevAll(".item:eq(0)");
    if(prev.length>0) {
        var pVal = $("textarea", prev).val();
        var cVal = $("textarea", curr).val();
        if(pVal.toLowerCase().trim()>cVal.toLowerCase().trim()) {
            $("textarea", curr).val( pVal );
            $("textarea", prev).val( cVal );
            var $pInput = $("textarea", prev).prevAll("input[name^='Text_healthcare']:eq(0)");
            var $cInput = $("textarea", curr).prevAll("input[name^='Text_healthcare']:eq(0)");
            var pValInput = $pInput.val();
            var cValInput = $cInput.val();
            $pInput.val( cValInput );
            $cInput.val( pValInput );
            sortDem(curr); 
        }
    }
}

</script>
</head>
<body>



<div id="fields"><p class="item"><a class="itemDown"></a><a class="itemUp first"></a><input type="text" value="2400195" name="Text_Hobbycare_Client_List_xa0" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb0" cols="99" rows="2">Duke Elementary School Learning Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa1" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb1" cols="99" rows="2">Hackensack Elementary School Learning Building </textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa2" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb2" cols="99" rows="2">Montefiore Learning Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="2400335" name="Text_Hobbycare_Client_List_xa3" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb3" cols="99" rows="2">Learning Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa4" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb4" cols="99" rows="2">New York Plaza </textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="2400199" name="Text_Hobbycare_Client_List_xa5" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb5" cols="99" rows="2">NYU Langone Learning Building </textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="2400173" name="Text_Hobbycare_Client_List_xa6" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb6" cols="99" rows="2">Rabin Learning Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa7" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb7" cols="99" rows="2">Shanghai International Learning Zone</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa8" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb8" cols="99" rows="2">SUNY Downstate Learning Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa9" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb9" cols="99" rows="2">Elementary School of California San Francisco Learning Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa10" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb10" cols="99" rows="2">Elementary School of Connecticut Hobby Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa11" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb11" cols="99" rows="2">Elementary School of North Carolina Wellness</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa12" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb12" cols="99" rows="2">Elementary School of North Carolina &ndash; Chapel Hill</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa13" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb13" cols="99" rows="2">Elementary School of North Carolina &ndash; Wilmington</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="2400124" name="Text_Hobbycare_Client_List_xa14" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb14" cols="99" rows="2">Elementary School of Pennsylvania Hobby System</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa15" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb15" cols="99" rows="2">Elementary School of Pittsburgh Learning Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="2400183" name="Text_Hobbycare_Client_List_xa16" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb16" cols="99" rows="2">Elementary School of Virginia Hobby System </textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa17" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb17" cols="99" rows="2">Alta Bates Summit Learning Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa18" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb18" cols="99" rows="2">Bellevue Plaza Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa19" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb19" cols="99" rows="2">Bristol Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa20" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb20" cols="99" rows="2">Bronx Lebanon Hospita</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa21" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb21" cols="99" rows="2">Calvary Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="2401762" name="Text_Hobbycare_Client_List_xa22" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb22" cols="99" rows="2">Children’s Plaza of Oakland</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa23" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb23" cols="99" rows="2">Chinese Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa24" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb24" cols="99" rows="2">Coney Island Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="2401920" name="Text_Hobbycare_Client_List_xa25" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb25" cols="99" rows="2">Danbury Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa26" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb26" cols="99" rows="2">Eger Hobby Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="2402014" name="Text_Hobbycare_Client_List_xa27" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb27" cols="99" rows="2">Elizabeth Seton Pediatric Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa28" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb28" cols="99" rows="2">Elmhurst Plaza Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa29" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb29" cols="99" rows="2">First Hobby of the Carolinas</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa30" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb30" cols="99" rows="2">Forest Hills Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa31" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb31" cols="99" rows="2">Gaston Fun Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa32" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb32" cols="99" rows="2">Glendale Adventist Learning Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa33" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb33" cols="99" rows="2">Greenwich Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa34" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb34" cols="99" rows="2">Harlem Plaza Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa35" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb35" cols="99" rows="2">Hobby Quest System</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa36" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb36" cols="99" rows="2">Plaza for Special Surgery </textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="2400217" name="Text_Hobbycare_Client_List_xa37" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb37" cols="99" rows="2">Hudson Valley Plaza Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa38" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb38" cols="99" rows="2">John Muir Learning Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="2400347" name="Text_Hobbycare_Client_List_xa39" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb39" cols="99" rows="2">Kaiser Permanente Hobby System</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa40" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb40" cols="99" rows="2">Kennedy Hobby System</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa41" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb41" cols="99" rows="2">La Clinica de la Raza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa42" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb42" cols="99" rows="2">Lenox Hill Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa43" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb43" cols="99" rows="2">Lincoln Learning and Mental Hobby Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa44" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb44" cols="99" rows="2">Lutheran Learning Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa45" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb45" cols="99" rows="2">Maimonides Learning Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="240019" name="Text_Hobbycare_Client_List_xa46" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb46" cols="99" rows="2">Fun Sloan-Kettering Cancer Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa47" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb47" cols="99" rows="2">Mills-Peninsula Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa48" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb48" cols="99" rows="2">Moses Cone Fun Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa49" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb49" cols="99" rows="2">Nassau Elementary School Learning Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa50" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb50" cols="99" rows="2">New York Blood Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa51" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb51" cols="99" rows="2">New York Ocean of Osteopathic Medicine of NYIT</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa52" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb52" cols="99" rows="2">New York Eye &amp; Ear Room
</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa53" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb53" cols="99" rows="2">New  York Foundling Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="2400122" name="Text_Hobbycare_Client_List_xa54" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb54" cols="99" rows="2">New York Plaza Queens</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa55" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb55" cols="99" rows="2">New York Methodist Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa56" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb56" cols="99" rows="2">North Central Bronx Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa57" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb57" cols="99" rows="2">North Shore Long Island Hobby System</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa58" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb58" cols="99" rows="2">Northern Westchester Plaza Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa59" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb59" cols="99" rows="2">Office of the Chief Learning Examiner</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa60" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb60" cols="99" rows="2">Peconic Bay Learning Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa61" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb61" cols="99" rows="2">Phelps Fun Plaza Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="2400307" name="Text_Hobbycare_Client_List_xa62" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb62" cols="99" rows="2">Queens Plaza Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa63" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb63" cols="99" rows="2">Rochester General Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa64" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb64" cols="99" rows="2">Southampton Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="2400317" name="Text_Hobbycare_Client_List_xa65" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb65" cols="99" rows="2">St. Francis Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa66" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb66" cols="99" rows="2">St. Johns Riverside Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa67" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb67" cols="99" rows="2">St. Luke’s/Roosevelt Plaza Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="2403361" name="Text_Hobbycare_Client_List_xa68" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb68" cols="99" rows="2">St. Vincent’s Learning Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa69" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb69" cols="99" rows="2">Stamford Hobby System</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa70" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb70" cols="99" rows="2">Staten Island Elementary School Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa71" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb71" cols="99" rows="2">Touro Elementary School Ocean of Medicine</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa72" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb72" cols="99" rows="2">Vassar Brothers Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa73" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb73" cols="99" rows="2">Veterans Administration Hobby System</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa74" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb74" cols="99" rows="2">Weill Cornell Learning College</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa75" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb75" cols="99" rows="2">Westchester Learning Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa76" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb76" cols="99" rows="2">White Plains Plaza Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa77" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb77" cols="99" rows="2">Ajman Women’s Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa78" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb78" cols="99" rows="2">Alexandria Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="2400209" name="Text_Hobbycare_Client_List_xa79" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb79" cols="99" rows="2">Al Maktoum Accident and Emergency Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa80" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb80" cols="99" rows="2">American Cancer Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa81" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb81" cols="99" rows="2">American Plaza of Nigeria</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa82" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb82" cols="99" rows="2">Care Solutions</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa83" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb83" cols="99" rows="2">Changshu Maternity Plaza
</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa84" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb84" cols="99" rows="2">Chengdu ICT Oncology Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa85" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb85" cols="99" rows="2">Clinica Pasteur</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa86" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb86" cols="99" rows="2">GHRC Cancer Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa87" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb87" cols="99" rows="2">Hangzhou Maternity Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa88" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb88" cols="99" rows="2">Plazaia Plaza and Hotel</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa89" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb89" cols="99" rows="2">Ibn Sina Neuroscience Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa90" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb90" cols="99" rows="2">Indo Gulf Hobby Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa91" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb91" cols="99" rows="2">Kuwait Maternity Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa92" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb92" cols="99" rows="2">Kuwait Physical Medicine Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa93" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb93" cols="99" rows="2">MIOT International Plazas</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa94" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb94" cols="99" rows="2">Monte Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa95" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb95" cols="99" rows="2">Prince Sultan Learning Building</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa96" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb96" cols="99" rows="2">Saudi Airlines Hobby System</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa97" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb97" cols="99" rows="2">Sheikh Kalifa bin Zayed Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="2400331" name="Text_Hobbycare_Client_List_xa98" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb98" cols="99" rows="2">Khalifa Specialist Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa99" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb99" cols="99" rows="2">TaiKang Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa100" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb100" cols="99" rows="2">Tawam Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="2400205" name="Text_Hobbycare_Client_List_xa101" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb101" cols="99" rows="2">Trillium Hobby System</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa102" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb102" cols="99" rows="2">Universidad de Especialidades Espiritu Santo</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa103" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb103" cols="99" rows="2">Wilmot Point</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa104" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb104" cols="99" rows="2">Winthrop Elementary School Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa105" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb105" cols="99" rows="2">Women’s Ocean Plaza</textarea></p><p class="item"><a class="itemRemove"></a><a class="itemDown last"></a><a class="itemUp"></a><input type="text" value="" name="Text_Hobbycare_Client_List_xa106" autocomplete="off"><br /><textarea name="Text_Hobbycare_Client_List_xb106" cols="99" rows="2">Woodhull Learning Building
</textarea></p></div>


<input type="button" id="alpha" value="Sort" />

</body>
</html>

Open in new window

0
 
LVL 82

Expert Comment

by:leakim971
Comment Utility
Sorry, I did not see the new data.
COuld you confirm it work as required with the old data? Thanks
0
IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

 
LVL 16

Author Comment

by:hankknight
Comment Utility
It does work with the old data but not with the new data.  That is why I posted this as a new question.  Sorry for not making it clearer.  

Please test it with the new data here:
http://jsfiddle.net/ELTpz/

Thanks!
0
 
LVL 82

Expert Comment

by:leakim971
Comment Utility
the first error is : name^='Text_healthcare'
so replace it by : name^='Text_'

there's something else because the order process is broken
let me check again
0
 
LVL 82

Accepted Solution

by:
leakim971 earned 500 total points
Comment Utility
Check this one : http://jsfiddle.net/ELTpz/2/
$(document).ready(function() {

    $('#alpha').click(function() {
         var arr = [];
         $(".item").each(function(i, el) { arr.push( [$("textarea", el).val(), $("input[name^='Text_']", el).val()] ) });
         arr.sort(function(v1, v2) {
             if(v1<v2) return -1;
             return 1;
         })
         $.map(arr, function(arr, i) {
             $(".item:eq(" + i + ") textarea").val( arr[0] );
             $(".item:eq(" + i + ") input[name^='Text_']").val( arr[1] );
         });
     });

});

Open in new window

0

Featured Post

Enabling OSINT in Activity Based Intelligence

Activity based intelligence (ABI) requires access to all available sources of data. Recorded Future allows analysts to observe structured data on the open, deep, and dark web.

Join & Write a Comment

Suggested Solutions

Requirements JQuery 1.6+ HTML CSS Introduction This article was inspired by an EE question (http://www.experts-exchange.com/Programming/Languages/Scripting/JavaScript/Q_28372511.html) on how to make a page show some balloons animate up a page…
Nothing in an HTTP request can be trusted, including HTTP headers and form data.  A form token is a tool that can be used to guard against request forgeries (CSRF).  This article shows an improved approach to form tokens, making it more difficult to…
The viewer will learn how to dynamically set the form action using jQuery.
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)

744 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now