Posts

ios - How to get rid of multiple sets of parentheses in an array -

i'm using restkit object mapping json , i'm mapping array. json i'm mapping looks this: "parameters":[{"parameter_value":["smith"]}, {"parameter_value":[66211]}] the array i'm getting looks this: parameter value: ( ( smith ), ( 66211 ) ) when try convert array string via code: nsstring *nameidvalue = [[parametervaluearray valueforkey:@"description"] componentsjoinedbystring:@""]; string nameidvalue turns this: ( smith )( 66211 ) how rid of parentheses i'm left smith, 66211 you asked eliminating "sets of parentheses", given underlying structure series of nested collections (dictionaries , arrays), can achieve desired effect collapsing level or 2 structure. can kvc collection operator , @unionofarrays , used in conjunction valueforkeypath . if want string manipulation, can that, seems more logical write code renders simple arra...

grails - Grials clean command prevent deleting resources -

Image
how prevent grails clean command, not delete newly added folder in web-app folder. i use lots of custom folders in webapp, grails-clean doesn't delete of mine. plz rename folder other , check again.

html - How to make responsive table -

i have table represent data in html page. i'm trying make table responsive. how can ? here demo . basically a responsive table 100% width table. you can set table css: .table { width: 100%; } demo here you can use media queries show/hide/manipulate columns according screens dimensions adding class (or targeting using nth-child , etc): @media screen , (max-width: 320px) { .hide { display: none; } } html <td class="hide">not important</td> more advanced solutions if have table lot of data , make readable on small screen devices there many other solutions: css-tricks.com offers this article handling large data tables. zurb ran issue , solved it using javascript. footables great jquery plugin helps out issue. as posted elvin arzumanoğlu great list of examples .

linux kernel - Difference between ZRAM and ZSWAP -

does know difference between feature zram , zswap in linux kernel? seems similar-- store compressed pages in ram. zram module of linux kernel, called "compcache". zram increases performance avoiding paging on disk , instead uses compressed block device in ram in paging takes place until necessary use swap space on hard disk drive. since using ram faster using disks, zram allows linux make more use of ram when swapping/paging required, on older computers less ram installed. zswap lightweight compressed cache swap pages. takes pages in process of being swapped out , attempts compress them dynamically allocated ram-based memory pool. zswap trades cpu cycles potentially reduced swap i/o. trade-off can result in significant performance improvement if reads compressed cache faster reads swap device.

html - Basic javascript isn't working - display block -

if user selects "house" want new select option box pop up. nothing happening. function showfamilies(){ if(pt.selectedindex == 1) document.getelementbyid('families').style.display = 'block'; if(pt.selectedindex != 1) document.getelementbyid('families').style.display = 'none'; } <select id="pt" value="pt" name="pt" onchange="showfamilies()"> <option value="" name="">select</option> <option value="1" name="1">house</option> <option value="2" name="2">commercial</option> </select> <div id="families" style="display:none">families: <select name="amin_families"> <option value="1" name="condo">1</option> <option value="2" name="co-op">2</option></select> </div> redefined...

Soundcloud SDK for Android -

may know, possible use soundcloud sdk android sdk ? if is, know how use soundcloud sdk android project ? sample projects or guideline links helpful. as there soundcloud java library available, seems practical use soundcloud android. it contains example code.

Php to json does not pass all arrays (or json does not display all received values) -

Image
as see first , third row fields filled, second row fields left blank. filled values with $.post("__php_file.php", { 'number_of_input_row': number_of_input_row, 'date_day': date_day, 'date_month': date_month, 'date_year': date_year, 'currency': currency }, function(data, success) { $('#currency_load1').html(data[0].finalcurrencyrate); $('#currency_load2').html(data[1].finalcurrencyrate); $('#currency_load3').html(data[2].finalcurrencyrate); }, "json"); send php file, process , such php array array ( [0] => array ( [currencyabbreviation] => aud [dateofcurrencyrate] => 2013-07-11 [numberofinputrow] => 1 [finalcurrencyrate] => 0.506 ) [2] => array ( [currencyabbreviation] => cad [dateofcurrencyrate] => 2013-07-25 [numberofinputrow] => 3 [...