unified_texts
stringlengths
32
30.1k
OpenStatus_id
int64
0
4
input_ids
list
token_type_ids
list
attention_mask
list
# splitting the string dynamically in sql server 2008 === I have a string like this ","","","41","20120627063343-0210600-41" I wrote QUERY LIKE this to split the above string declare @s varchar(max) set @s = '","","","41","20120627063343-0210600-41"' select right(replace(@s,',',''),26) as output AND I AM GETTING THE OUTPUT LIKE THIS output ------- 20120627063343-0210600-41" I want the output like this for the above string YEAR TIME NO ID ---- ----- ---- ---- 2012-06-27 06:33:43 0210600 41 HELP ME THANKS AND REGARDS ANAND
0
[ 2, 6926, 17282, 14, 3724, 7782, 1326, 19, 4444, 255, 8128, 570, 800, 3726, 3726, 31, 57, 21, 3724, 101, 48, 13, 7, 15, 7, 7, 15, 7, 7, 15, 7, 4499, 7, 15, 7, 3212, 3370, 13710, 3891, 24142, 8, 3564, 1036, 7664, 8, 4499, 7, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Premature end of file. exception trying to parse xml from Zipinputstream === I am trying to extract an xml file & other contents from a ZipInputStream and create my objects from xml parsing the zipinputstream. However I am getting Premature end of file exception - for the following code or Stream Closed - when I dont have the while loop reading the inputStream. From what I understand, ZipInputStream.getNextEntry gets the next entries inputstream. Also - when I run it by creating an actual temp file & pass the inputstream (as in the commented code) - it processes fine - but in my case, I wont be able to write to the disk - so all this has to happen in-memory. Can someone tell me where mycode is wrong and what can I do to fix it? ZipEntry entry; Map<String, byte[]> otherElements = new HashMap<String, byte[]>(); entry =((ZipInputStream)inputStream).getNextEntry(); while (entry != null) { logger.debug("entry: " + entry.getName() + ", " + entry.getSize()); System.out.println(entry.getName() + " - " + entry.getSize()); if (entry.getName().equalsIgnoreCase("Document.xml")) { /*File file = new File("C:\\tmp.xml"); FileOutputStream fos = new FileOutputStream(); int read = 0; byte[] bytes = new byte[1024]; while ((read = inputStream.read(bytes)) != -1) { fos.write(bytes, 0, read); } InputStream fis = new FileInputStream();*/ while(inputStream.available()>0){ inputStream.read(); } myOutput = buildMyOutput((ZipInputStream)inputStream); //fos.close(); //fis.close(); --------------------------------------------------------------------- // method that takes the input and creates the java object private MyObject buildMyOutput(InputStream xmlStream) throws Exception { // build my objects XStream xstream = ConvertUtil.getXStream(); xstream.processAnnotations(MyObject.class); MyObject myOutput = (MyObject) xstream.fromXML(xmlStream); return myOutput; } -----------------------------------------------------------------------
0
[ 2, 17769, 241, 16, 3893, 9, 5391, 749, 20, 2017, 870, 23504, 37, 12133, 108, 4881, 11260, 800, 3726, 3726, 31, 589, 749, 20, 10962, 40, 23504, 3893, 279, 89, 8478, 37, 21, 12133, 108, 4881, 11260, 17, 1600, 51, 3916, 37, 23504, 20...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
jQuery selector td with specific text === I have a jquery selector which looks like this: $("#MasterListDVWP tr td:contains('" + currentSchool + "')").siblings("td:contains('Yes')").siblings("td:contains('CD'),td:contains('Other1')").each(function() { // do something }); Could someone help me to convert the selector so that it returns the object that matches the exact text rather than just contains? I know this isn't valid but something like this..siblings("td:equals('CD')")... Your help will be greatly appreciated.
0
[ 2, 487, 8190, 93, 23946, 15596, 29, 1903, 1854, 800, 3726, 3726, 31, 57, 21, 487, 8190, 93, 23946, 56, 1879, 101, 48, 45, 5579, 5, 7, 5910, 4594, 5739, 17905, 13790, 9235, 15596, 45, 1126, 5851, 18, 5, 22, 7, 2754, 866, 7535, 27...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Sort Magento related products by ASC sort order with NULLs last (or excluded) === My Magento 1.6.2.0 installation currently sorts related products in ascending order by sort order (thanks to this [Q/A][1]). The answer detailed there works beautifully, however I prefer my products with a sort order value of NULL be listed last or completely excluded. I've played with addAttributeToSelect() but I have so far been unsuccessful. Any guidance would be great. Thank you! [1]: http://stackoverflow.com/questions/8008076/magento-1-6-sort-order-of-related-products-not-working
0
[ 2, 2058, 4723, 17050, 1597, 1985, 34, 28, 150, 2058, 389, 29, 16203, 18, 236, 13, 5, 248, 13599, 6, 800, 3726, 3726, 51, 4723, 17050, 137, 9, 379, 9, 135, 9, 387, 7758, 871, 14357, 1597, 1985, 19, 24859, 389, 34, 2058, 389, 13, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Build list using only list comprehensions, no function === Given userplays = { "Alice" : { "AC/DC" : 2, "The Raconteurs" : 3, "Mogwai" : 1 }, "Bob" : { "The XX" : 4, "Lady Gaga" : 3, "Mogwai" : 1, "The Raconteurs" : 1 }, "Charlie" : { "AC/DC" : 7, "Lady Gaga" : 7 } } get a list of all bands: ['Lady Gaga', 'Mogwai', 'AC/DC', 'The Raconteurs', 'The XX'] I can do list(set(flatten([ [ band for band in playcounts.keys() ] for playcounts in userplays.values() ] ) ) ) where `flatten` is from http://stackoverflow.com/questions/2158395/flatten-an-irregular-list-of-lists-in-python, but is it possible without `flatten`, using only list/dict comprehensions?
0
[ 2, 1895, 968, 568, 104, 968, 27300, 18, 15, 90, 1990, 800, 3726, 3726, 504, 4155, 5438, 18, 800, 13, 1, 13, 7, 58, 11909, 7, 13, 45, 13, 1, 13, 7, 1738, 118, 7201, 7, 13, 45, 172, 15, 13, 7, 124, 13, 525, 1126, 20130, 18, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How to get a variable's byte count? === In PHP, read binary data from MySQL, how to get binary data's length? For example: $sql = "SELECT * FROM test WHERE id = 2"; $result = mysql_query($sql, $connection); if(!$result) { echo "Execute query failed!"; exit; } $row = mysql_fetch_assoc($result)); // $row["col_varbinary"] is binary data, how to get this data's length?
0
[ 2, 184, 20, 164, 21, 7612, 22, 18, 34, 591, 2468, 60, 800, 3726, 3726, 19, 13, 26120, 15, 1302, 14171, 1054, 37, 51, 18, 22402, 15, 184, 20, 164, 14171, 1054, 22, 18, 1476, 60, 26, 823, 45, 5579, 18, 22402, 800, 13, 7, 18, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
design pattern to handle base/super classes with optional subclasses === I may not have my terms right here, so please edit for clarity. Let's say I have code for running a online shop that has a number of different classes/objects associated with it (Order, Customer, Product etc) Then, I have particular stores, like a Shoe Store and a Pencil Shop, and each implements different aspects of the Base Store. In an MVC pattern, how do I design an app so that I don't have write a subclass for each object for each type of store? (This would quickly get unwieldy if I had many stores). For instance, given these modes: models/baseOrders.file models/baseCustomers.file models/baseProducts.file models/shoeStoreOrders.file (extends baseOrders) models/pencilShopCustomers.file (extends baseCustomers) Then I'd like to be able to instantiate an orders model, using shoeStoreModel.file when it's the shoe store and baseOrders when it's the pencil store... Hopefully this is a clear question, but maybe I'm thinking about this incorrectly altogether... Guidance please!!! Thanks in advance...
0
[ 2, 704, 3732, 20, 3053, 1000, 118, 8542, 2684, 29, 12832, 972, 1898, 160, 800, 3726, 3726, 31, 123, 52, 57, 51, 1663, 193, 235, 15, 86, 2247, 9392, 26, 18314, 9, 408, 22, 18, 395, 31, 57, 1797, 26, 946, 21, 2087, 2546, 30, 63,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
end user modifications of website === I am making a website as a school project, but it will have real end uses and a has a client, I have made a 'admin' area in this website, and would like to let the client edit certain things, this would save to the server and then any other person viewing the site would see it. Ive been reading around on this for days now and have seen several methods, firstly was ckeditor, which i consider a possibility however i have been bafled with how it saves the data, as it constantly provides me with a posteddata.php which simply re-opens it self continuously, if anyone could explain how to get ckeditor to save and/or open/overwrite and existing webpage. the second option was i looked into databases and found taffyDB which i very much liked the look of until i realised that any dynamic changes made on one page would not resave the javascript to include these for another, let alone when accesed from another computer. this remains my back up, as i think taffy would be the simplest method to explain how to achieve with raw data, if there is another simple db method which can save itself on the server i would much appreciate being informed of it :) and finally i looked into mysql, however i am unsure yet as if i would have access to put mysql databases on the final webserver, and this seems very heavy duty and difficult to learn for just a school project :/ i saw drupal as well, however also saw it used mysql and was scared off :P basically I am asking for your opinion on the best way to progress, i understand if this is not the most orthodox method of posting however I value the community at stackoverflow to be the best at advice, and would much appreciate your opinion, thank you Thomas
4
[ 2, 241, 4155, 13922, 16, 2271, 800, 3726, 3726, 31, 589, 544, 21, 2271, 28, 21, 116, 669, 15, 47, 32, 129, 57, 683, 241, 2027, 17, 21, 63, 21, 6819, 15, 31, 57, 117, 21, 13, 22, 1283, 2160, 22, 217, 19, 48, 2271, 15, 17, 8...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Replace paragraph text within a div based on class === I'm trying to use jQuery to change paragraph text based upon the class of the div in which it resides. I want each of the class names in the array to replace the p text within their respective divs. Right now I just get the last div's class name for the p text. <div class="ph player">PHILIPPINES<p class="topic">Test topic</p></div> <div class="sl player">SOLOMON ISLANDS<p class="topic">Test topic</p></div> <div class="fi player">FIJI<p class="topic">Test topic</p></div> <div class="sm player">SAMOA<p class="topic">Test topic</p></div> <script> var divArr = ["ph", "sl", "fi", "sm"]; $.each(divArr, function(index, value) { $(".topic").text(this); }); </script> Thanks for looking. Total beginner here.
0
[ 2, 3934, 20599, 1854, 363, 21, 13, 12916, 432, 27, 718, 800, 3726, 3726, 31, 22, 79, 749, 20, 275, 487, 8190, 93, 20, 753, 20599, 1854, 432, 685, 14, 718, 16, 14, 13, 12916, 19, 56, 32, 12631, 9, 31, 259, 206, 16, 14, 718, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
jquery hide/show causing mouseleave event === I inserted a hover effect into my site, basically "click this link >" will transform to "click this link >" with a different color. Because i use cufon, i'm doing this with two seperate divs, i first show the new one and then hide the old one and run the animation. This works great, when the mouse enters from the top, left and right, but when the mouse enters from the bottom there's a flicker and the mouseleave event is triggered. My guess is that the hide is done before the show and that the container div becomes empty for a short period of time. Any ideas how to prevent the mouseleave? my php function for such links is this: function link_arrowed($label,$font_size,$margin_to_arrow,$extended_margin,$inactive_color,$active_color){ $html = " <div class='arrowed_link' style='min-height:".$font_size.";'> <input value='".$extended_margin."' class='extended_margin' type='text' style='display:none' hidden> <div class='inactive_text' style='float:left;'> <div style='float:left;margin-right:".$margin_to_arrow.";font-size:".$font_size.";color:".$inactive_color.";'>".$label."</div> <div class='arrow_right' style='float:left;font-size:".$font_size.";color:".$inactive_color.";'>></div> </div> <div class='active_text' style='float:left;display:none;'> <div style='float:left;margin-right:".$margin_to_arrow.";font-size:".$font_size.";color:".$active_color.";'>".$label."</div> <div class='arrow_right' style='float:left;font-size:".$font_size.";color:".$active_color.";'>></div> </div> </div> "; return $html; } my js: $(document).on('mouseenter','.arrowed_link', function(){ var extended_margin = $(this).children('.extended_margin').val(); $(this).children('.active_text').show(); $(this).children('.inactive_text').hide(); $(this).children('.active_text').children('.arrow_right').animate( {'margin-left': extended_margin}, 200, function(){ }); }); $(document).on('mouseleave','.arrowed_link', function(){ $(this).children('.active_text').children('.arrow_right').animate( {'margin-left': '0px'}, 200, function(){ $(this).parent().siblings('.inactive_text').show(); $(this).parent().hide(); }); });
0
[ 2, 487, 8190, 93, 3077, 118, 9303, 3242, 7567, 14416, 807, 800, 3726, 3726, 31, 14215, 21, 21350, 1590, 77, 51, 689, 15, 11374, 13, 7, 150, 10129, 48, 3508, 13, 1, 7, 129, 8007, 20, 13, 7, 150, 10129, 48, 3508, 13, 1, 7, 29, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Creating JS objects in PHP with commas in between === I'm trying to create an array of JS objects from a PHP array, but I'm struggling to find a way to insert commas in between each object. Here's what I'm trying to output: var things = [ { a: "foo", b: "bar" }, // Comma on this line { a: "moo", b: "car" } // No comma on this line ]; And here is what I have so far: var things = [ <?php foreach ($things as $thing): ?> { a: "<?php echo $thing->getA(); ?>", b: "<?php echo $thing->getB(); ?>" } <?php endforeach; ?> ]; I suppose I could resort to something ugly, like an `if` statement that only runs once: <?php $i = 1; if ($i == 1) { echo '{'; $i++; } else { echo ',{'; } ?> Is there not a cleaner/better way to do this?
0
[ 2, 2936, 487, 18, 3916, 19, 13, 26120, 29, 11951, 472, 19, 128, 800, 3726, 3726, 31, 22, 79, 749, 20, 1600, 40, 7718, 16, 487, 18, 3916, 37, 21, 13, 26120, 7718, 15, 47, 31, 22, 79, 7587, 20, 477, 21, 161, 20, 14692, 11951, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Android : Apply style to List and set a selected item shown in AlertDialog === I am showing a List in AlertDialog. I want to customize the list with some style (maybe custom). Also want an item to be selected in the list of Alert dialog. I have used very simple code : new AlertDialog.Builder(TrainsListActivity.this).setTitle(curTrainRoute.getName() + " to " + stationNames[which]) .setItems(timeList, new DialogInterface.OnClickListener() { @Override public void onClick(DialogInterface dialog, int which) { dialog.dismiss(); } }) .show(); I tried searching for the same, but couldn't find any resource for the same. Can you please help me out. Any help is highly appreciated. Thanks
0
[ 2, 13005, 13, 45, 5645, 1034, 20, 968, 17, 309, 21, 1704, 9101, 1721, 19, 7863, 4286, 5567, 800, 3726, 3726, 31, 589, 3187, 21, 968, 19, 7863, 4286, 5567, 9, 31, 259, 20, 5816, 2952, 14, 968, 29, 109, 1034, 13, 5, 5138, 5816, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Cluster manager for Linux/Java processes, log gathering === I have some Java servers (though Java in fact doesn't matter here, it can be any executable) which I want to run on multiple machines. Is there some cluster management software, which would allow me to say, for example "start 3 instances of service A, and 5 instaces of service B". In case one node dies, start the services on another server. It would also be nice to have some kind of an admin console, where I could see which servers work, which services work were etc. (Of course with a nice dashboard with lots of green ;) ). Or at least a REST interface to get that info easily. Going a step further, such a cluster manager could take care of gathering logs from the services, and alerting an adinistrators if there are errors in any of them. Or maybe that's a separate service? Does such a thing exist? (preferrably in an open-source version of course)
0
[ 2, 7460, 1382, 26, 13024, 118, 1004, 1385, 5102, 15, 6738, 5822, 800, 3726, 3726, 31, 57, 109, 8247, 17595, 13, 5, 9371, 8247, 19, 837, 1437, 22, 38, 1161, 235, 15, 32, 92, 44, 186, 1396, 17194, 5924, 6, 56, 31, 259, 20, 485, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Google maps in china "Are they actually blocked"? === Hi guys im working on a site which has a majority of chinese users. The problem is that it has been reported that google maps is not working for our users in china, because it is blocked. I have trawled the net looking for a definitive answer but cant seem to find one, does any one know for sure weather it is blocked or not. When I use a Chinese proxy I cannot reproduce the issue, and I am also not using https for my calls.
2
[ 2, 8144, 6867, 19, 998, 13, 7, 1509, 59, 1121, 8388, 7, 60, 800, 3726, 3726, 4148, 2776, 797, 638, 27, 21, 689, 56, 63, 21, 1698, 16, 1116, 3878, 9, 14, 1448, 25, 30, 32, 63, 74, 1117, 30, 8144, 6867, 25, 52, 638, 26, 318, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How to load data from a variable into a select menu? === I am getting my data from a web service using ajax call. i am saving it in a variable, the problem i am facing is that i need to display this data that i am getting into a select menu.. i am not able to crack it up. my html code. <div data-role="page" id="requestPage"> <div data-role="fieldcontain"> <select id="select-choice-3" name="pid you need"> <option value="select-value" selected="selected">-- Select PID --</option> // here i want my data to be </select> </div> </div> JS code function content_Load(){ var soapMessage='<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"><soap:Body><GetProjectByPeopleId xmlns="http://there.org/"><tmsUserId>' + TmsUserId +'</tmsUserId></GetProjectByPeopleId></soap:Body></soap:Envelope>' $.ajax({ url: "http://22.232.32.14/therewebservice/thereeatmswebservice.asmx?op=GetProjectByPeopleId", type: "POST", dataType: "xml", SOAPAction: "http://there.org/GetProjectByPeopleId", data: soapMessage, complete: endSaveProduct, contentType: "text/xml; charset=\"utf-8\"" }); return false; } function endSaveProduct(xmlHttpRequest,status){ $(xmlHttpRequest.responseXML) .find('Table') .each(function() { var ProjectName =$(this).find('ProjectName').text(); // i am able to get ProjectName as my data, now i want it to get into the select menu for which i have written the code bellow but that's not working. var optionlist=''; optionlist += '<option>' + ProjectName + '</option>'; $("#select-choice-3").html(optionlist).selectmenu('refresh', true); window.location.href="#requestPage"; }); }
0
[ 2, 184, 20, 6305, 1054, 37, 21, 7612, 77, 21, 5407, 11379, 60, 800, 3726, 3726, 31, 589, 1017, 51, 1054, 37, 21, 2741, 365, 568, 20624, 645, 9, 31, 589, 7599, 32, 19, 21, 7612, 15, 14, 1448, 31, 589, 4325, 25, 30, 31, 376, 2...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Memory allocation for Structure having an array in C === I have structure containing an array into it.Something like given below struct Node { int a; char a1[25]; }; main() { structure Node *p=malloc(size of(struct node)); p->a=10; } Now i would like to know is two different memory section is allocated for this piece of code one from stack for storing structure node and other from heap for storing node pointed to by pointer p ?
0
[ 2, 1912, 16840, 26, 1411, 452, 40, 7718, 19, 272, 800, 3726, 3726, 31, 57, 1411, 3503, 40, 7718, 77, 32, 9, 9099, 101, 504, 1021, 13, 10346, 15421, 13, 1, 19, 38, 21, 73, 4892, 21, 165, 2558, 1811, 12660, 13, 1, 73, 407, 5, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Pass a value using Request.QueryString when I doubleclick === I have a gridview and I want to pass a value from a row cell to another page. Based on the value which is a string, I can run a specific query and fill another gridview. My problem is, that when I double click the row, it won't pick up the value, however, it will for the other columns in the row when I change the row cell index. Let me know if more info is needed, thanks. protected void grdCowCard_RowDataBound(object sender, GridViewRowEventArgs e) { if (e.Row.RowType == DataControlRowType.DataRow) { string querystring = string.Empty; string id = e.Row.Cells[1].Text; //Session["selectedLactationEvent"] = "MMR"; e.Row.Attributes["ondblclick"] = string.Format("doubleClick({0})", id); //won't pick up the value("MMR") at Row.Cells[1] //but will pick up the value("1") at Row.Cells[0] } } <script type="text/javascript"> function doubleClick(queryString) { window.location = ('<%=ResolveUrl("LactationDetails.aspx?b=") %>' + queryString); } </script> The value should get based to this session and then used to determine which method to use to fill the gridview. Session["selectedLactationEvent"] = Request.QueryString["b"].ToString(); //string test = (string)(Session["selectedLactationEvent"]); if ((string)(Session["selectedLactationEvent"]) == "MMR") { GetExtraMMRdetails(); } else if ((string)(Session["selectedLactationEvent"]) == "LAC") { GetExtraLACdetails(); } else GetExtraEBIdetails();
0
[ 2, 1477, 21, 1923, 568, 3772, 9, 8190, 93, 11130, 76, 31, 1494, 150, 10129, 800, 3726, 3726, 31, 57, 21, 7354, 4725, 17, 31, 259, 20, 1477, 21, 1923, 37, 21, 3131, 1667, 20, 226, 2478, 9, 432, 27, 14, 1923, 56, 25, 21, 3724, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Regex in php preg_match function === I have a regex pattern <?php if(preg_match("/shop[0-9]/", '/shop43')){ echo "YES"; } else { echo "NO"; } ?> It is working, but when i write if(preg_match("/shop[0-9]/", '/shop43d')){ echo "YES"; } it is working too.The problem is that i need to have ony digits after word "shop",for example shop1,shop2,...,shop123 What I need to change in my pattern?) I would be very thankful if somebody could give me a link with some examples of my problem in regex.Thank you :)
0
[ 2, 7953, 1706, 19, 13, 26120, 782, 263, 1, 12280, 1990, 800, 3726, 3726, 31, 57, 21, 7953, 1706, 3732, 13, 1, 60, 26120, 100, 5, 3515, 263, 1, 12280, 5, 7, 118, 18, 5347, 2558, 387, 8, 518, 500, 118, 7, 15, 13, 22, 118, 18, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
SignalR javascript hub method not firing in IE after a period of inactivity === I have a SignalR (v0.5.2) Hub sending a message to a JavaScript client. c# public Task SendData(ClassName classData){ return Clients["groupid"].renderData(classData); } javascript var _client = $.connection.myHub; _client.renderData = function(data){ /* do stuff */ }; $.connection.hub.start({ transport:activeTransport }, function(){ }); All works fine except that after a period of inactivity in IE9, the JavaScript method fails to run. I have looked at the Response Body of the `/signalr/connect?transport=foreverFrame` network log within IE9 developer tools and can see that I am receiving the message: <script>r(c, {"MessageId":"54","Messages":[{"Hub":"myHub","Method":"renderData","Args":[....]]}],"Disconnect":false,"TimedOut":false,"TransportData":{"Groups":["LiveBid.999"]}});</script> <div>{"MessageId":"54","Messages":[{"Hub":"myHub","Method":"renderData","Args":[....]]}],"Disconnect":false,"TimedOut":false,"TransportData":{"Groups":["LiveBid.999"]}}</div> Yet the JavaScript method never fires?
0
[ 2, 2800, 139, 8247, 8741, 5814, 2109, 52, 7139, 19, 13, 660, 75, 21, 620, 16, 19, 19348, 800, 3726, 3726, 31, 57, 21, 2800, 139, 13, 5, 710, 387, 9, 264, 9, 135, 6, 5814, 4907, 21, 2802, 20, 21, 8247, 8741, 6819, 9, 272, 591...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Open Gl fails to render scene using Visual C++ compiler === I am trying to build a hexagon model using OpenGl in Visual C++. I somehow didn't manage to retrieve the correct output. #include <windows.h> #include <glut.h> #include <math.h> float x, inc = 3.14/6, pi = 3.14; void RenderScene() { glColor3f(1,1,0); for ( x=0.0; x<2*pi; x=x+inc ) { glBegin(GL_LINE_STRIP); glVertex2f(cos(x),sin(x)); glEnd(); } } void myDisplay(void) { glEnable(GL_CULL_FACE); glEnable(GL_DEPTH_TEST); glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT); glPushMatrix(); RenderScene(); glPopMatrix(); glFlush(); } void SetupRC(void) { glClearColor(0.0, 0.0, 1.0, 1.0); glOrtho(-5.0,5.0,-5.0,5.0,-5.0,5.0); } void main(void) { glutInitDisplayMode(GLUT_SINGLE | GLUT_RGB); glutInitWindowSize(640,480); glutInitWindowPosition(10,15); glutCreateWindow("Rofans Manao"); glutDisplayFunc(myDisplay); SetupRC(); glutMainLoop(); } Above is my code. My code used to be working previously. I believe I did some unseen mistakes. All advice are appreciated.
0
[ 2, 368, 13, 8430, 13614, 20, 16535, 1691, 568, 3458, 272, 20512, 21486, 800, 3726, 3726, 31, 589, 749, 20, 1895, 21, 24, 396, 13247, 1061, 568, 368, 8430, 19, 3458, 272, 20512, 9, 31, 3625, 223, 22, 38, 4705, 20, 11917, 14, 4456, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Paypal SetExpressCheckout returning token, then displaying "This transaction is invalid..." upon redirect === class ExpressCheckout { static function PPHttpPost($methodName_, $nvpStr_) { require_once("DataClass.php"); $API_Data = Data::GetPayPalData(); // Set up your API credentials, PayPal end point, and API version. $environment = $API_Data['enviro']; $API_UserName = urlencode($API_Data['user']); $API_Password = urlencode($API_Data['pass']); $API_Signature = urlencode($API_Data['sig']); $API_Endpoint = "https://api-3t.paypal.com/nvp"; if("sandbox" === $environment || "beta-sandbox" === $environment) { $API_Endpoint = "https://api-3t.$environment.paypal.com/nvp"; } $version = urlencode('72.0'); // Set the curl parameters. $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $API_Endpoint); curl_setopt($ch, CURLOPT_VERBOSE, 1); // Turn off the server and peer verification (TrustManager Concept). curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, FALSE); curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, FALSE); curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); curl_setopt($ch, CURLOPT_POST, 1); // Set the API operation, version, and API signature in the request. $nvpreq = "METHOD=$methodName_&VERSION=$version&PWD=$API_Password&USER=$API_UserName&SIGNATURE=$API_Signature$nvpStr_"; // Set the request as a POST FIELD for curl. curl_setopt($ch, CURLOPT_POSTFIELDS, $nvpreq); // Get response from the server. $httpResponse = curl_exec($ch); if(!$httpResponse) { exit("$methodName_ failed: ".curl_error($ch).'('.curl_errno($ch).')'); } // Extract the response details. $httpResponseAr = explode("&", $httpResponse); $httpParsedResponseAr = array(); foreach ($httpResponseAr as $i => $value) { $tmpAr = explode("=", $value); if(sizeof($tmpAr) > 1) { $httpParsedResponseAr[$tmpAr[0]] = $tmpAr[1]; } } if((0 == sizeof($httpParsedResponseAr)) || !array_key_exists('ACK', $httpParsedResponseAr)) { exit("Invalid HTTP Response for POST request($nvpreq) to $API_Endpoint."); } return $httpParsedResponseAr; } static function send() { require_once("DataClass.php"); $API_Data = Data::GetPayPalData(); // Set request-specific fields. $paymentAmount = urlencode($API_Data['pay']); $currencyID = urlencode($API_Data['currency']); // or other currency code ('USD', 'EUR', 'JPY', 'CAD', 'AUD') $paymentType = urlencode($API_Data['type']); // or 'Sale' or 'Order' $returnURL = urlencode($API_Data['return']); $cancelURL = urlencode($API_Data['cancel']); $bad = urlencode("MESS subscription"); // Add request-specific fields to the request string. $nvpStr = "&CANCELURL=$cancelURL&REQCONFIRMSHIPPING=0&NOSHIPPING=1&PAYMENTREQUEST_0_AMT=$paymentAmount&PAYMENTREQUEST_0_ITEMAMT=$paymentAmount&PAYMENTREQUEST_0_TAXAMT=0&RETURNURL=$returnURL&L_BILLINGTYPE0=RecurringPayments&PAYMENTREQUEST_0_DESC=$bad&L_BILLINGAGREEMENTDESCRIPTION0=$bad&PAYMENTREQUEST_0_PAYMENTACTION=$paymentType&PAYMENTREQUEST_0_CURRENCYCODE=$currencyID"; // Execute the API operation; see the PPHttpPost function above. $httpParsedResponseAr = ExpressCheckout::PPHttpPost('SetExpressCheckout', $nvpStr); if("SUCCESS" == strtoupper($httpParsedResponseAr["ACK"]) || "SUCCESSWITHWARNING" == strtoupper($httpParsedResponseAr["ACK"])) { // Redirect to paypal.com. $token = urldecode($httpParsedResponseAr["TOKEN"]); $payPalURL = "https://www.paypal.com/webscr&cmd=_express-checkout&token=$token"; if("sandbox" === $environment || "beta-sandbox" === $environment) { $payPalURL = "https://www.$environment.paypal.com/webscr&cmd=_express-checkout&token=$token"; } //header("Location: $payPalURL"); //commented out to view token and parsed response return array($token, $httpParsedResponseAr); } else { return 'SetExpressCheckout failed: ' . print_r($httpParsedResponseAr, true); } } } My code above works correctly for retrieving the token (the response is ACK = 'SUCCESS') but when I redirect to paypal with the token i get the following error: > This transaction is invalid. Please return to the recipient's website > to complete your transaction using their regular checkout flow. I have tried several ways of doing this, searched online, still no luck for 3 days now. Can anyone see where I'm going wrong? Thanks in advance. oh and this is called with: `var_dump($token = ExpressCheckout::send($_SESSION['email']));` `var dump()` being used to see the token and response when `header("Location: $payPalURL");` is commented out.
0
[ 2, 1372, 6720, 309, 21230, 12542, 1320, 2485, 20, 2853, 15, 94, 17418, 13, 7, 1565, 12799, 25, 16671, 9, 9, 9, 7, 685, 302, 14706, 800, 3726, 3726, 718, 2999, 12542, 1320, 13, 1, 12038, 1990, 3273, 21127, 6962, 5, 4403, 5909, 1807...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
common language for any RDBMS technology === we are looking for a common language for any RDBMS technology.means if i write q query in SQL SERVER that query have to work on any RDBMS like oracle ,mysql....please help me.
4
[ 2, 757, 816, 26, 186, 13, 897, 13178, 18, 1099, 800, 3726, 3726, 95, 50, 699, 26, 21, 757, 816, 26, 186, 13, 897, 13178, 18, 1099, 9, 22183, 18, 100, 31, 2757, 2593, 25597, 19, 4444, 255, 8128, 30, 25597, 57, 20, 170, 27, 186,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Paypal Sandbox Test Tool IPN Simulator in Localhost === How to use Instant Payment Notification Simulator in local machine? What will be provided in IPN handler URL? I don't have access to our router. Thanks
0
[ 2, 1372, 6720, 1965, 5309, 1289, 5607, 31, 17479, 24565, 19, 375, 11694, 800, 3726, 3726, 184, 20, 275, 6322, 7582, 52, 4634, 24565, 19, 375, 1940, 60, 98, 129, 44, 1173, 19, 31, 17479, 24641, 287, 6362, 60, 31, 221, 22, 38, 57, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
Why I can run the Apps from App Store without any Profile? === I have recently running into some issues with the Provisioning Profile. Now I understand to test my locally developed App on another iPad, I need to install the Provisioning Profile on that iPad. But what about the Apps from App Store? Why I can run them without any Profile? Thanks.
0
[ 2, 483, 31, 92, 485, 14, 4865, 18, 37, 4865, 1718, 366, 186, 5296, 60, 800, 3726, 3726, 31, 57, 1989, 946, 77, 109, 1549, 29, 14, 8738, 68, 5296, 9, 130, 31, 1369, 20, 1289, 51, 6680, 885, 4865, 27, 226, 31, 8240, 15, 31, 37...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How to get FQL Stream with full names === I would like to show stream data from FQL fql?q=SELECT post_id, app_id, source_id, updated_time, created_time, filter_key, attribution, actor_id, target_id, message, app_data, action_links, attachment, impressions, comments, likes, place, privacy, permalink, xid, tagged_ids, message_tags, description, description_tags, type FROM stream WHERE filter_key in (SELECT filter_key FROM stream_filter WHERE uid=me() AND type='newsfeed') but the problem is that that table doesn't have name of the users/pages, only ids. Is there any way to get names to those results too? And not only actor_id, but also name for the people who has made comments. Do I need to make multiquery and search against all those ids in the stream, and then fetch from user and page tables. And then loop those results for every single stream result, seems kind of heavy. Any easier way?
0
[ 2, 184, 20, 164, 398, 22402, 3766, 29, 503, 1817, 800, 3726, 3726, 31, 83, 101, 20, 298, 3766, 1054, 37, 398, 22402, 398, 22402, 60, 1251, 3726, 18, 16964, 678, 1, 1340, 15, 4865, 1, 1340, 15, 1267, 1, 1340, 15, 6372, 1, 891, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Switching between div tags breaks my code === I have been working on a project recently and have been required to learn jQuery to do it. Not such an easy thing to learn for a beginner ha. Anyway I have been trying to have a few div tags that are switched between depending on which one the user has clicked on. The first one, "Add field" should switch to a div that contains a button to add a new field. Now instead of putting a large amount of code here I instead put it into http://jsfiddle.net/9acEk/ so you could see a working example, or rather not working. My problem is that when I change a tab and click back on "Add field" tab the buttons no longer work. the page opens with a button that when clicked adds a text box. However even if I just click on the "Add field" tab the button no longer does anything, I have used alert boxs to display the code and it is exactly the same. I have no idea why this does not work after clicking on the tab, it makes no sense to me as the code, as mentioned, is exactly the same. Apologies if the question makes no sense, any questions on it just ask me and I shall do my best to clear it up. Thanks a lot in advance to any help given, it is appreciated.
0
[ 2, 13027, 128, 13, 12916, 3383, 18, 7947, 51, 1797, 800, 3726, 3726, 31, 57, 74, 638, 27, 21, 669, 1989, 17, 57, 74, 1390, 20, 2484, 487, 8190, 93, 20, 107, 32, 9, 52, 145, 40, 2010, 584, 20, 2484, 26, 21, 26931, 1458, 9, 27...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Regular expression for csv with commas and no quotes === I'm trying to parse really complicated csv, which is generated wittout any quotes for columns with commas.<br /> The only tip I get, that commas with whitespace before or after are included in field. Jake,HomePC,Microsoft VS2010, Microsoft Office 2010 Should be parsed to Jake HomePC Microsoft VS2010, Microsoft Office 2010 Can anybody advice please on how to include "\s," and ,"\s" to column body.
0
[ 2, 1290, 1803, 26, 272, 18, 710, 29, 11951, 472, 17, 90, 18901, 800, 3726, 3726, 31, 22, 79, 749, 20, 2017, 870, 510, 8343, 272, 18, 710, 15, 56, 25, 6756, 14709, 1320, 186, 18901, 26, 7498, 29, 11951, 472, 9, 1, 5145, 13, 118...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How to edit an array from a textarea in Ember js? === I'm trying to update an array from a textArea, each line of which would be a new item. Here is what I tried to do, but the textArea doesn't update the array: **Handlebars**: <script type="text/x-handlebars"> {{view Ember.TextArea valueBinding="App.listController.formattedContent"}} </br> {{#each App.listController}} {{this}} {{/each}} </script> **JavaScript**: App = Ember.Application.create({}); App.listController = Ember.ArrayController.create({ content: ['some', 'items', 'in', 'an', 'array'], formattedContent: function() { return this.get('content').join('\n'); }.property('content') }); and the [jsFiddle](http://jsfiddle.net/YDe5p/2/) I know it can't be that simple, but I have no idea where to start. Any idea?
0
[ 2, 184, 20, 9392, 40, 7718, 37, 21, 1854, 17760, 19, 13, 19603, 487, 18, 60, 800, 3726, 3726, 31, 22, 79, 749, 20, 11100, 40, 7718, 37, 21, 1854, 17760, 15, 206, 293, 16, 56, 83, 44, 21, 78, 9101, 9, 235, 25, 98, 31, 794, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How to write a table literal in Oracle? === A table with one column and one row can be created with: select 1 as col from dual; This can be used to build table joins: with a as (select 1 as ac from dual), b as (select 2 as bc from dual) select * from a left outer join b on (ac = bc); Now I would like to have two rows. I did it in this way: select 1 as col from dual union select 2 as col from dual; But is there a more compact notation for this? I tried select (1, 2) as col from dual; but it does not work.
0
[ 2, 184, 20, 2757, 21, 859, 20665, 19, 15759, 60, 800, 3726, 3726, 21, 859, 29, 53, 4698, 17, 53, 3131, 92, 44, 679, 29, 45, 5407, 137, 28, 3313, 37, 5747, 73, 48, 92, 44, 147, 20, 1895, 859, 10612, 45, 29, 21, 28, 13, 5, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How to stop 'Conform form resubmission' dialog while refreshing the page === I am using an subscribe script to add the user email address to mysql record. I used the below code for this process .It works fine .after user submit the email the page is refreshed and database is also updated to mysql :-) . But the issue is ,When i refresh the page after submitting the email ,i'm getting an conform form resubmission dialog .If i click continue button the same email (dublicate) is updating in new record.my db is updating with same email address when the i refresh page. How to disable this message and stop updating the same duplicate records in mysql. <form id="myForm" action="" onsubmit="return validateForm();"method="post"> <input type="hidden" name="action" value="update" /> <input type="text" name="email" id="email" value="Enter your email here" onfocus="if (this.value == 'Enter your email here') {this.value = '';}" onblur="if (this.value == '') {this.value = 'Enter your email here';}" onwebkitspeechchange = "this.value = this.value.replace('Enter your email here','')"; style=" margin:0px 0px 0px 26px;color:#999; border:4px solid #bbb;border- radius:6px;font-size:1em;width:260px;height:30px; font-style:italic; font-family:"Times New Roman", Times, serif;"/> <br><center><input class="button" type="image" src="rss.png" /></center> </form> <?php $email = $_POST['email']; mysql_connect ("localhost", "root", "") or die ('Error: ' . mysql_error()); mysql_select_db ("test"); $query="INSERT INTO newsletter_emails (email)VALUES ('".$email."')"; mysql_query($query) or die ('Error updating database'); ?> <script> function validateForm() { var x=document.forms["myForm"]["email"].value; var atpos=x.indexOf("@"); var dotpos=x.lastIndexOf("."); if (atpos<1 || dotpos<atpos+2 || dotpos+2>=x.length) { alert("Not a valid e-mail address"); return false; } else{ alert("thankyou"); } } </script>
0
[ 2, 184, 20, 747, 13, 22, 1126, 4190, 505, 302, 7563, 12385, 22, 28223, 133, 27134, 14, 2478, 800, 3726, 3726, 31, 589, 568, 40, 13, 20330, 3884, 20, 3547, 14, 4155, 8517, 3218, 20, 51, 18, 22402, 571, 9, 31, 147, 14, 1021, 1797,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
ViewBag Content not available to Partial Views? === I have a PartialView called TopPanel. This Panel is responsible for displaying error messages generated on any page in my application. To handle this, when any exception occurs on a page, I have it call an "ErrorHandler" action in the TopPanel controller. ErrorHandler updates the ViewBag with the error message and calls the Index action which just returns the partial view(for now, since im testing. I will have it call the Main Controllers Index Action later to display the whole page). My understanding is that calling the Index action will reload the view and the ErrorDiv that I have on TopPanels PartilaView will be able to display the new error message in ViewBag. However, nothing gets displayed and I'm not sure why. Heres some code - The ErrorHandler Action - public ActionResult ErrorHandler(string message) { ViewBag.ErrorMsg = message; return RedirectToAction("Index"); } I've checked in the debugger, "message" does have a valid value. And ViewBag.ErrorMsg does get populated as well. Index Action of TopPanel - public ActionResult Index() { return PartialView(); } TopPanels PartialView contains this lone which displays the error - <div id="errorMsgBox">@ViewBag.ErrorMsg</div> Can anyone point out what the issue is?
0
[ 2, 1418, 8632, 2331, 52, 904, 20, 7284, 4146, 60, 800, 3726, 3726, 31, 57, 21, 7284, 4725, 227, 20, 13031, 7440, 9, 48, 4113, 25, 1864, 26, 17418, 7019, 7561, 6756, 27, 186, 2478, 19, 51, 3010, 9, 20, 3053, 48, 15, 76, 186, 53...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
how to build multiple property file using ANT build in cmd === I have two property file. I want to dynamically build the property files in `ant` Ex: Property file name pro1, pro2 my build file name is build.xml i need to run these properties dynamically in `ant` build
0
[ 2, 184, 20, 1895, 1886, 1354, 3893, 568, 40, 38, 1895, 19, 2390, 43, 800, 3726, 3726, 31, 57, 81, 1354, 3893, 9, 31, 259, 20, 7782, 1326, 1895, 14, 1354, 6488, 19, 13, 1, 1830, 1, 1396, 45, 1354, 3893, 204, 895, 165, 15, 895, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
NHibernate ClassMap<T> code not executing === I'm setting up a new project and have gotten NHibernate to work with structuremap...sorta. I'm using the NHibernate.Mapping.ByCode.Conformist setup with ClassMaps. No errors occur, but when I query over a session and there are records present in the database for a particular type, nothing comes back. Upon further examination, it appears that the mappings that I've set up for these types are not executing. Here's my code that wires up things for structuremap. I can confirm that it is being executed. public class OrmRegistry : Registry { public OrmRegistry() { var sessionFactory = BuildSessionFactory(); For<ISessionFactory>().Singleton().Use(sessionFactory); For<ISession>().HybridHttpOrThreadLocalScoped().Use(s => sessionFactory.OpenSession()); } public ISessionFactory BuildSessionFactory() { var cfg = new Configuration().DataBaseIntegration(db => { db.ConnectionStringName = "LocalSqlServer"; db.Dialect<MsSql2008Dialect>(); db.Driver<SqlClientDriver>(); db.KeywordsAutoImport = Hbm2DDLKeyWords.AutoQuote; db.IsolationLevel = IsolationLevel.ReadUncommitted; db.BatchSize = 500; }).AddAssembly(Assembly.GetExecutingAssembly()); if(HttpContext.Current != null) { cfg.CurrentSessionContext<WebSessionContext>(); } else { cfg.CurrentSessionContext<ThreadStaticSessionContext>(); } return cfg.BuildSessionFactory(); } } I'm nearly certain I'm just missing something extremely obvious here, but I've been looking at it for a few hours and haven't had any success. I also got downsized a couple days ago, so I don't have a coworker around to look at it.
0
[ 2, 12109, 15191, 8820, 718, 15022, 1, 38, 1, 1797, 52, 25836, 800, 3726, 3726, 31, 22, 79, 2697, 71, 21, 78, 669, 17, 57, 4094, 12109, 15191, 8820, 20, 170, 29, 1411, 15022, 9, 9, 9, 22843, 58, 9, 31, 22, 79, 568, 14, 12109, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Why does Facebook Credits callback payments_get_items occasionally not pass user ID? === Our facebook canvas app is having this problem where now, several times a day, the credits callback is passing a signed_request with the following contents: Array ( [algorithm] => HMAC-SHA256 [credits] => Array ( [order_id] => 9005967273834 [order_info] => "item104" ) [issued_at] => 1319329443 [user] => Array ( [country] => do [locale] => es_LA [age] => Array ( [min] => 0 [max] => 12 ) ) ) Notice anything missing? That's right! No user_id, buyer, or receiver is given! We can't tell facebook what the price or description of an item is without knowing who is receiving the item. This seems like a bad bug! This problem started happening on Oct 11, 2011
0
[ 2, 483, 630, 9090, 5748, 645, 1958, 11161, 1, 3060, 1, 2119, 79, 18, 4533, 52, 1477, 4155, 4924, 60, 800, 3726, 3726, 318, 9090, 9696, 4865, 25, 452, 48, 1448, 113, 130, 15, 238, 436, 21, 208, 15, 14, 5748, 645, 1958, 25, 2848, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
JAVA_HOME issue with logging class === I get the following error even when my JAVA_HOME is set correctly. C:\workspace-sts-2.8.0.RELEASE\JBClient\target>echo %JAVA_HOME% <br> C:\jdk1.6.0_31 <br> <br> <br> I am not doing any logging I just have the following dependencies on my classpath (ALONGWITH THE JRE) - concurrent.jar - hornetq-core-client-java5.jar - hornetq-jms-client-java5.jar - jboss-aop-client.jar - jboss-aspect-jdk50-client.jar jboss-client.jar jboss-common-core.jar - jboss-ejb3-common-client.jar jboss-ejb3-core-client.jar - jboss-ejb3-proxy-impl-client.jar jboss-ejb3-proxy-spi-client.jar - jboss-ejb3-security-client.jar jboss-integration.jar jboss-javaee.jar - jboss-logging.jar jboss-remoting.jar jboss-security-spi.jar - jbossall-client.jar jbosssx-client.jar jnp-client.jar Exception in thread "main" java.lang.Error: Can't find java.home ?? at java.util.logging.LogManager.readConfiguration(Unknown Source) at java.util.logging.LogManager$2.run(Unknown Source) at java.security.AccessController.doPrivileged(Native Method) at java.util.logging.LogManager.readPrimordialConfiguration(Unknown Source) at java.util.logging.LogManager.getLogManager(Unknown Source) at java.util.logging.Logger.<init>(Unknown Source) at java.util.logging.LogManager$RootLogger.<init>(Unknown Source) at java.util.logging.LogManager$RootLogger.<init>(Unknown Source) at java.util.logging.LogManager$1.run(Unknown Source) at java.security.AccessController.doPrivileged(Native Method) at java.util.logging.LogManager.<clinit>(Unknown Source) at java.util.logging.Logger.getLogger(Unknown Source) at com.sun.jmx.remote.util.ClassLogger.<init>(Unknown Source) at javax.management.remote.JMXServiceURL.<clinit>(Unknown Source) at main.java.JBClient.main(Unknown Source) Exception in thread "Thread-0" java.lang.NoClassDefFoundError: Could not initialize class java.util.logging.LogManager at java.util.logging.LogManager$Cleaner.run(Unknown Source)
0
[ 2, 8247, 1, 8167, 1513, 29, 13, 13919, 718, 800, 3726, 3726, 31, 164, 14, 249, 7019, 166, 76, 51, 8247, 1, 8167, 25, 309, 12044, 9, 272, 45, 1, 3783, 5582, 8, 10044, 8, 135, 9, 457, 9, 387, 9, 15202, 1, 728, 7229, 18513, 38,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Is there a Java continuous testing plugin for Maven? === I'm looking for a plugin that would run in a console continuously to scan a Maven project's test sources directory, and when it detects a change kicks off a test cycle. Something analogous to `mvn scala:cc` or the Scala Build Tool, but for Java. Can anyone point me towards one?
0
[ 2, 25, 80, 21, 8247, 6357, 4431, 10922, 108, 26, 1216, 3124, 60, 800, 3726, 3726, 31, 22, 79, 699, 26, 21, 10922, 108, 30, 83, 485, 19, 21, 8650, 11738, 20, 8313, 21, 1216, 3124, 669, 22, 18, 1289, 2662, 16755, 15, 17, 76, 32,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Android Sprite Animation Move To position X (should be simple but, I'm stuck) === I'm trying to move sprites to stop the frames in center(or move them to certain x position) when right or left pressed on screen. There are 3 sprites created using box.java in the view, placed one after another with padding, stored in arraylist. <b>The problem:</b> No smooth movement and doesn't stop in the center of each frames after movement has begun, sometimes all boxes are moving on top of each others, padding is totally lost. Please let me know what I'm doing wrong, thanks a lot! //BEGINING OF BOX.JAVA >> The problem is in this class! //This goes in Update(); private void boxMove() { int get_moved_pos = getMovedPos(); //get moved pos int sprite_size = view.getSpriteSize(); //get sprite arraylist size currentDirection = view.getDirection(); //get direction "left" or "right" from view if(currentDirection == "right" && isMoving == false) { setSpriteMovedNext(); }else if(currentDirection == "left" && isMoving == false) { setSpriteMovedPrev(); } if(currentDirection != lastDirection) { lastDirection = currentDirection; //MOVE RIGHT if(currentDirection == "right" && get_moved_pos > 0) //move left and make sure that moved pos isn't overlapping / or moving to empty space { //Animate left until it reaches the new x position if(x > get_new_pos_left) { x -= pSpeedX; } Log.d("RIGHT","POS: " + get_moved_pos); }else //MOVE LEFT if(currentDirection == "left" && get_moved_pos < sprite_size-1) //move left and make sure that moved pos isn't overlapping / or moving to empty space { //Animate right until it reaches the new x position if(x < get_new_pos_right) { x += pSpeedX; } } } } //Call when screen is touched (in View.java), to set a new position to move to. public void resetMoving() { isMoving = false; this.lastDirection = ""; Log.d("RESET", "MOVING RESET"); } public int getMovedPos() { return this.smoved_pos; } private void setSpriteMovedNext() { int get_max_moved = getMovedPos(); int s_size = view.getSpriteSize(); if (isMoving == false) //take a break between movements { if(get_max_moved < s_size-1) { Log.d("NEXT", "CALLED"); this.get_new_pos_right = x + view.getNextPosX(); //current x and next stop position this.smoved_pos += 1; this.isMoving = true; //set to avoid double touch Log.d("NEXT", "X POS SET: " + get_max_moved); } } } private void setSpriteMovedPrev() { int get_max_moved = getMovedPos(); if (isMoving == false) //take a break between movements { if(get_max_moved > 0) { Log.d("PREV", "CALLED"); this.get_new_pos_left = x - view.getNextPosX(); //get current x pos and prev stop position this.smoved_pos -= 1; //to limit the movements this.isMoving = true; //set to avoid double touch Log.d("PREV", "X POS SET: " + get_max_moved); } } } //END OF BOX.JAVA //VIEW //Add boxes public void addBox() { int TOTAL_BOXES = 3; int padding_left = 200; int padding_tmp = this.getWidth()/2; box.clear(); //clear old //Box 1 box.add(new Boxes(box, this, "box1", padding_tmp, this.getHeight()/2, boxSpriteImage, 1, 2, 0, 0)); padding_tmp += boxSpriteImage.getWidth()/TOTAL_BOXES + padding_left; //Box 2 box.add(new Boxes(box, this, "box2", padding_tmp, this.getHeight()/2, boxSpriteImage, 1, 2, 1, 1)); padding_tmp += boxSpriteImage.getWidth()/TOTAL_BOXES + padding_left; //Box 3 box.add(new Boxes(box, this, "box3", padding_tmp, this.getHeight()/2, boxSpriteImage, 1, 2, 2, 1)); } public boolean onTouchEvent(MotionEvent event){ if (System.currentTimeMillis() - lastClick > 100){ lastClick = System.currentTimeMillis(); float x = event.getX(); float y = event.getY(); synchronized (getHolder()) { if(x >= this.getWidth()/2) { Direction = "right"; }else { Direction = "left"; } } } //called in box.java to get next x pos to move public float getNextPosX() { int PADDING = 200; //padding between frames next_pos_x = boxSprite.getWidth()/TOTAL_COLUMNS + PADDING; return next_pos_x; }
0
[ 2, 13005, 27902, 6236, 780, 20, 649, 993, 13, 5, 14941, 44, 1935, 47, 15, 31, 22, 79, 4549, 6, 800, 3726, 3726, 31, 22, 79, 749, 20, 780, 27902, 18, 20, 747, 14, 12809, 19, 459, 5, 248, 780, 105, 20, 1200, 993, 649, 6, 76, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Apache HttpComponents: org.apache.http.client.ClientProtocolException === So I use apache HttpComponents to handle http request in java. Now I want to reuse the `DefaultHttpClient`, what should be possible accoarding to this example: http://wiki.apache.org/HttpComponents/QuickStart. The example itselfs give a ssl error so I modefied and simplefied it a bit. Now I always get a `org.apache.http.client.ClientProtocolException` Here is my example program, basicly I just request 2 webpages using the same `DefaultHttpClient`. import java.io.ByteArrayOutputStream; import java.io.IOException; import java.io.InputStream; import org.apache.http.HttpEntity; import org.apache.http.HttpResponse; import org.apache.http.client.methods.HttpGet; import org.apache.http.impl.client.DefaultHttpClient; public class ClientFormLogin { public static void main(String[] args) throws Exception { DefaultHttpClient httpclient = new DefaultHttpClient(); //Handle first request. HttpGet httpget = new HttpGet("http://tweakers.net/nieuws/82969/amazon-nederland-opent-digitale-deuren-in-september.html"); HttpResponse response = httpclient.execute(httpget); System.out.println("Execute finished"); HttpEntity entity = response.getEntity(); String page = readInput(entity.getContent()); System.out.println("Request one finished without problems!"); //Handle second request HttpGet httpost = new HttpGet("http://gathering.tweakers.net/forum/list_messages/1506977/last"); response = httpclient.execute(httpost); entity = response.getEntity(); page = readInput(entity.getContent()); System.out.println("Request two finished without problems!"); } private static String readInput(InputStream in) throws IOException { ByteArrayOutputStream out = new ByteArrayOutputStream(); byte bytes[] = new byte[1024]; int n = in.read(bytes); while (n != -1) { out.write(bytes, 0, n); n = in.read(bytes); } return new String(out.toString()); } } When runnig my example I get the folowing error Request one finished without problems! Exception in thread "main" org.apache.http.client.ClientProtocolException at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:909) at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:805) at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:784) at ClientFormLogin.main(ClientFormLogin.java:29) Caused by: org.apache.http.HttpException: Unable to establish route: planned = {}->http://gathering.tweakers.net; current = {}->http://tweakers.net at org.apache.http.impl.client.DefaultRequestDirector.establishRoute(DefaultRequestDirector.java:842) at org.apache.http.impl.client.DefaultRequestDirector.tryConnect(DefaultRequestDirector.java:645) at org.apache.http.impl.client.DefaultRequestDirector.execute(DefaultRequestDirector.java:480) at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:906) ... 3 more Any one can give me some pointers how I can solve this problem, except use a new `DefaultHttpClient` for every request. **Edit** I just found out if I stay on the same domain I have no problems so: `page1: http://tweakers.net/nieuws/82969/amazon-nederland-opent-digitale-deuren-in-september.html page2: http://tweakers.net/nieuws/82973/website-nujij-belandt-op-zwarte-lijst-google-door-malware.html` I have no problems if I got to: `page1: http://tweakers.net/nieuws/82969/amazon-nederland-opent-digitale-deuren-in-september.html page2: http://gathering.tweakers.net/forum/list_messages/1506076/last` I get the error. Ofc I see this one minute after posting my question. Except if someone can tell me how I can go 2 sperate domains with the same `DefaultHttpClient` my question is already answered.
0
[ 2, 17140, 7775, 11103, 849, 14128, 45, 13, 5583, 9, 7738, 2569, 9, 21127, 9, 150, 18513, 38, 9, 150, 18513, 38, 2740, 262, 7771, 10066, 872, 800, 3726, 3726, 86, 31, 275, 17140, 7775, 11103, 849, 14128, 20, 3053, 7775, 3772, 19, 8...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Entity Framework generates inefficient select when using Find() === I am noticing that the Entity Framework is generated some inefficient queries when using the `Find()` method. For example here is my C# code. Model model = unit.Repository.DbSet.Find(model.ID); **Generate Find() Query** DECLARE @p0 int = 1 SELECT [Limit1].[ID] AS [ID], [Limit1].[UserID] AS [UserID], [Limit1].[Started] AS [Started], [Limit1].[Updated] AS [Updated], [Limit1].[Completed] AS [Completed] FROM ( SELECT TOP (2) [Extent1].[ID] AS [ID], [Extent1].[UserID] AS [UserID], [Extent1].[Started] AS [Started], [Extent1].[Updated] AS [Updated], [Extent1].[Completed] AS [Completed] FROM [dbo].[Table] AS [Extent1] WHERE [Extent1].[ID] = @p0 ) AS [Limit1] It seems to be running a whole other select query which is unnecessary. Here is the output using the `SingleOrDefault()` method. **Generate SingleOrDefault() Query** DECLARE @p__linq__0 int = 1 SELECT TOP (2) [Extent1].[ID] AS [ID], [Extent1].[UserID] AS [UserID], [Extent1].[Started] AS [Started], [Extent1].[Updated] AS [Updated], [Extent1].[Completed] AS [Completed] FROM [dbo].[Table] AS [Extent1] WHERE [Extent1].[ID] = @p__linq__0 Is there a reason why `Find()` is generating two selects? Should the `Find()` method be avoided in favor of the `SingleOrDefault()` method?
0
[ 2, 9252, 6596, 7920, 18, 19, 23702, 5407, 76, 568, 477, 5, 6, 800, 3726, 3726, 31, 589, 18130, 30, 14, 9252, 6596, 25, 6756, 109, 19, 23702, 9386, 2829, 76, 568, 14, 13, 1, 19811, 5, 6, 1, 2109, 9, 26, 823, 235, 25, 51, 272,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
JBoss 6.1.0.Final and ActiveMQ 5.6.0 - any way to work around AMQ-3868? === I would ideally like to add ActiveMQ 5.6.0 to my JBoss 6.1.0.Final. But then you will of course hit: https://issues.apache.org/jira/browse/AMQ-3868 Due to some library conflicts. Is there any way to use the classloading isolation to work around this issue? Or any other way to work around this issue?
0
[ 2, 487, 10349, 18, 400, 9, 165, 9, 387, 9, 4932, 17, 1348, 79, 1251, 331, 9, 379, 9, 387, 13, 8, 186, 161, 20, 170, 140, 589, 1251, 8, 3665, 4279, 60, 800, 3726, 3726, 31, 83, 5628, 102, 101, 20, 3547, 1348, 79, 1251, 331, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Learning jQuery selectors. How to alert the value of the selector? === Take this code for example: $('.photo').hover( function() { //display heading and caption $(this).children('div:first').stop(true,false).animate({top:0},{duration:200, easing: 'easeOutQuart'}); $(this).children('div:last').stop(true,false).animate({bottom:0},{duration:200, easing: 'easeOutQuart'}); }, Lets say I want to know which element was selected with this line: $(this).children('div:first') Is it possible somehow to alert the targeted element? I tried: something = $(this).children('div:first').val(); alert (something); or something = $(this).children('div:first'); alert (something); With the first example I get blank alert. With second - Objext object. Regards,
0
[ 2, 2477, 487, 8190, 93, 23946, 18, 9, 184, 20, 7863, 14, 1923, 16, 14, 23946, 60, 800, 3726, 3726, 247, 48, 1797, 26, 823, 45, 5579, 5, 22, 9, 25445, 22, 6, 9, 252, 2549, 5, 1990, 5, 6, 13, 1, 12894, 2906, 5438, 4582, 17, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Base64 encode very large files in objective C to upload file in sharepoint === I have a requirement where user can upload files present in app to SharePoint via same app. I tried using http://schemas.microsoft.com/sharepoint/soap/CopyIntoItems method of sharepoint. But it needs file in base64 encoded format to be embedded into body of SOAP request . My code crashed on device when I tried to convert even a 30 MB file in base64 encoded string? Same code executed just fine on simulator Is there any other alternative to upload files (like file streaming etc) onto sharepoint?? I may have to upload files upto 500 MB? Is there more efficient library to convert NSData into base64 encoded string for large file??? Should I read file in chunks and then convert that into base64 encoded string and upload file once complete file is converted? Any other appraoches???
0
[ 2, 1000, 3470, 20523, 253, 370, 6488, 19, 7038, 272, 20, 71, 8294, 3893, 19, 1891, 3132, 800, 3726, 3726, 31, 57, 21, 8981, 113, 4155, 92, 71, 8294, 6488, 734, 19, 4865, 20, 1891, 3132, 1197, 205, 4865, 9, 31, 794, 568, 7775, 69...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Write file need to optimised for heavy traffic part 4 === this is a continuation of part 3 <http://stackoverflow.com/questions/11526856/write-file-need-to-optimised-for-heavy-traffic-part-3> as my code changed somewhat i think it is better to open a new thread. public class memoryStreamClass { static MemoryStream ms1 = new MemoryStream(); static MemoryStream ms2 = new MemoryStream(); static int c = 1; public void fillBuffer(string outputString) { byte[] outputByte = Encoding.ASCII.GetBytes(outputString); if (c == 1) { ms1.Write(outputByte, 0, outputByte.Length); if (ms1.Length > 8100) { c = 2; Thread thread1 = new Thread(() => emptyBuffer(ref ms1)); thread1.Start(); } } else { ms2.Write(outputByte, 0, outputByte.Length); if (ms2.Length > 8100) { c = 1; Thread thread2 = new Thread(() => emptyBuffer(ref ms2)); thread2.Start(); } } } void emptyBuffer(ref MemoryStream ms) { FileStream outStream = new FileStream(string.Format("c:\\output.txt", FileMode.Append); ms.WriteTo(outStream); outStream.Flush(); outStream.Close(); ms.SetLength(0); ms.Position = 0; Console.WriteLine(ms.Position); } there are 2 things i have changed changed from the code in part 3. 1. the class and method is changed to non-static, the variables are still static tho. 2. i have move the memorystream reset length into the emptyBuffer method, and i use a ref parameter to pass the reference instead of a copy to the method. this code compiled fine and runs ok. However, i run it side by side with my single thread program, using 2 computers, one computer runs the single thread, and one computer runs the multithread version, on the same network. i run it for around 5 mins. and the single threaded version collects 8333KB of data while the multithread version collects only 8222KB of data. (98.6% of the single thread version) its first time i have do any performance comparison between the 2 version. Maybe a should run more test to confirm it. but base on looking the code, any masters out there will point out any problem? i haven't putting any code on lock or threadpooling at the moment, maybe i should, but if the code runs fine, i dont want to change it and break it. the only thing i will change is the buffer size, so i will eliminate any chance of the buffer fill up before the other is emptied. any comments on my code?
0
[ 2, 2757, 3893, 376, 20, 19259, 2541, 26, 1278, 2227, 141, 268, 800, 3726, 3726, 48, 25, 21, 15503, 16, 141, 203, 13, 1, 21127, 6903, 25325, 2549, 9990, 9, 960, 118, 24652, 18, 118, 19275, 23994, 3776, 118, 23716, 8, 16877, 8, 556,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How to stop Java web app on server remotely === I remotely ran a Java web application on a server using TightVNC. One of the tasks of the web app was that it would schedule and do a specific task every 15 minutes. Turns out the code is incorrect and produces a SQL Exception: Invalid column index ever 15 minutes. Basically I'm trying to kill the version of the web app running on the server and run an old one. Normally I would use `kill -9 *PID*` and then run the older version. However no comman on TightVNC seems to do anything. If I type `clear` and press enter nothing happens so I just have a growing list of the Invalid column index errors. If I type `kill -9 *PID*` or any other comman then when I press enter the cursor just moves to the next line to no affect. Anybody Know how I can stop this so I can revert back to the old version of the web app. Greatly appreciate any help.
0
[ 2, 184, 20, 747, 8247, 2741, 4865, 27, 8128, 23288, 800, 3726, 3726, 31, 23288, 717, 21, 8247, 2741, 3010, 27, 21, 8128, 568, 2618, 16578, 150, 9, 53, 16, 14, 8674, 16, 14, 2741, 4865, 23, 30, 32, 83, 4345, 17, 107, 21, 1903, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
split line in C# Graphics === i draw a line with Graphics gg = this.CreateGraphics(); Pen pern = new Pen(Color.Blue, 2); gg.DrawLine(pern, Lines[0].StartPoint.X , Lines[0].StartPoint.Y , Lines[0].EndPoint.X , Lines[0].EndPoint.Y); how can i split this line into two parts... when i right click by mouse and choose split from a contextMenuStrip ,,, the line splite into three parts gg.DrawLine(pern, Lines[0].StartPoint.X , Lines[0].StartPoint.Y , mouseposition.X , mouseposition,Y); gg.DrawLine(pern, mouseposition.X , mouseposition,Y ,Lines[0].EndPoint.X , Lines[0].EndPoint.Y);
0
[ 2, 2132, 293, 19, 272, 5910, 8351, 800, 3726, 3726, 31, 2003, 21, 293, 29, 8351, 13, 4572, 800, 48, 9, 6037, 1373, 12084, 18, 5, 6, 73, 2402, 416, 103, 800, 78, 2402, 5, 11282, 9, 6997, 15, 172, 6, 73, 13, 4572, 9, 43, 12404...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
stl vector size on 64-bit machines === I have an application that will use millions of vectors. It appears that most implementations of std::vector use 4 pointers (_First, _Last, _End, and _Alloc), which consumes 32 bytes on 64-bit machines. For most "practical" use cases of vector, one could probably get away with a single pointer and two 'unsigned int' fields to store the current size & allocated size, respectively. Ignoring the potential challenge of supporting customized allocation (instead of assuming that allocations must go through the global new & delete operator), it seems that it is possible to build an STL compliant vector class that uses only 16 bytes (or at worst 24 bytes to support the _Alloc pointer). Before I start coding this up, 1) are there any pitfalls I should be aware of and 2) does an open source implementation exist?
0
[ 2, 354, 255, 7497, 1072, 27, 4384, 8, 3326, 6035, 800, 3726, 3726, 31, 57, 40, 3010, 30, 129, 275, 11999, 16, 7497, 18, 9, 32, 1780, 30, 127, 6123, 18, 16, 354, 43, 45, 45, 28033, 275, 268, 454, 445, 13, 5, 1, 3552, 15, 13, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
ASP.NET How to hide custom control after certain time === I have a custom control which displays results of some operations. It is hidden by default and its made visible on the code-behind of some other class. Now I want to hide it after a certain amount of time. How do I do it? I maybe could call javascript code from the other class to hide it. But is there a way to implement this logic in the custom control?
0
[ 2, 28, 306, 9, 2328, 184, 20, 3077, 5816, 569, 75, 1200, 85, 800, 3726, 3726, 31, 57, 21, 5816, 569, 56, 9412, 1736, 16, 109, 1311, 9, 32, 25, 3689, 34, 12838, 17, 82, 117, 4560, 27, 14, 1797, 8, 24878, 16, 109, 89, 718, 9, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Performance Issue - JFreeChart (XYDataSet) === I'm pretty much new to JFreeChart and am facing a performance issue while trying to render a huge dataset. The dataset in my scenario comes from a csv file which has well over 46700 rows (lines) and around 2666900+ data points to plot. My current code for plotting is as follows: public void doPlot(String plotTitle, HashMap<Integer, ArrayList<PlotCheckBox>> plotDataList, boolean dotOnly) { plotDialog.dispose(); DefaultXYDataset xyDataSet; try { if (plotDataList.isEmpty()) { return; } xyDataSet = new DefaultXYDataset(); /** * Populate Data Set */ boolean[] optionList; int countPlotPoints = 0; for (Integer tabIndex : plotDataList.keySet()) { ArrayList<PlotCheckBox> checkBoxList = plotDataList.get(tabIndex); try { if (checkBoxList == null) { continue; } else if (checkBoxList.isEmpty()) { continue; } optionList = new boolean[checkBoxList.size()]; for (int index = 0; index < checkBoxList.size(); index++) { optionList[index] = checkBoxList.get(index).isSelectedForPlot(); } /** * The getTabXYData() method builds up the xyDataSet by loading values from a given csv file and the * attributes chosen by the user to plot */ countPlotPoints += getTabXYData(xyDataSet, tabIndex, optionList, jTabbedPane_results.getTitleAt(tabIndex)); } finally { checkBoxList = null; optionList = null; } } System.out.println("Plot Points In This Graph: "+countPlotPoints); if (countPlotPoints == 0) { print("No options selected.\n"); JOptionPane.showMessageDialog(this, "No Plot Points Were Selected!", "Warning", JOptionPane.WARNING_MESSAGE); return; } JFreeChart chart = ChartFactory.createXYLineChart(plotTitle, "time(ms)", "---", xyDataSet, PlotOrientation.VERTICAL, true, true, false); XYPlot plot = (XYPlot) chart.getPlot(); XYLineAndShapeRenderer renderer = new XYLineAndShapeRenderer(); for (int i = 0; i < countPlotPoints; i++) { if (dotOnly) { renderer.setSeriesLinesVisible(i, false); } else { renderer.setSeriesLinesVisible(i, true); } renderer.setSeriesShapesVisible(i, true); } plot.setRenderer(renderer); ChartPanel chartpanel = new ChartPanel(chart); chartpanel.setDefaultDirectoryForSaveAs(new File(lastAnalyzedPath)); JFrame frame = new JFrame(); frame.setTitle(plotTitle); frame.add(new JScrollPane(chartpanel)); frame.pack(); frame.setVisible(true); frame.addWindowListener(new java.awt.event.WindowAdapter() { @Override public void windowClosing(java.awt.event.WindowEvent evt) { try { System.out.println(":: Clearning Memory ::"); System.out.println("\tFree Memory (Before cleanup): "+Runtime.getRuntime().freeMemory()); Component component = getComponent(0); if(component instanceof ChartPanel){ JFreeChart chart = ((ChartPanel) component).getChart(); XYPlot plot = (XYPlot) chart.getPlot(); plot = null; chart = null; component = null; } } finally { System.runFinalization(); System.gc(); System.out.println("\tFree Memory (Post cleanup): "+Runtime.getRuntime().freeMemory()); } } }); } finally { xyDataSet = null; System.runFinalization(); System.gc(); } } Because of this huge dataset, the plot takes a lot of time to load and trying to change the size of the plot window throws an OutOfMemoryError and the application crashes. What I would like to know are suggestions for improving performance. Here's what I've thought of (any comments/suggestions/feedback on this would really be appreciated): 1. Restricting users to a specific range to plot. Problem is I don't know how much of data can JFreeChart handle. Any suggestion on this? I would preferably won't want to use a magic number or just a trial and error method. 2. Use a scrollable XYDataSet. I'm pretty much new to this and don't have much idea about the implementation. Any sample code and a comment on efficacy of using this technique would be highly appreciated. I'm open to exploring new ideas. Please do let me know what you think about this issue. Many a thanks in advance!
0
[ 2, 956, 1513, 13, 8, 487, 4639, 5433, 38, 13, 5, 15161, 18768, 3554, 6, 800, 3726, 3726, 31, 22, 79, 1772, 212, 78, 20, 487, 4639, 5433, 38, 17, 589, 4325, 21, 956, 1513, 133, 749, 20, 16535, 21, 2329, 1054, 3554, 9, 14, 1054,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Rails: Good practice to always use ":dependent => :destroy?" === I recently came across an instance when I deleted a User from the database, but the index page for Posts broke because the User that wrote a specific post did not exist anymore. This made me wonder whether it is good practice to always use :dependent => :destroy? Or is there a not-so-complicated alternative solution to not make the entire page break when the User is deleted? I guess it's more of a business decision, but I think I don't necessarily want to delete all the content when a User removes his account. I suppose I could use something like <%= link_to post.author.username unless post.author.blank? ...... %> but that would make it a very tedious and messy task to have to include that in every line. Any suggestions/tips on this matter?
0
[ 2, 2240, 18, 45, 254, 1345, 20, 550, 275, 13, 7, 45, 19374, 800, 1, 13, 45, 28764, 60, 7, 800, 3726, 3726, 31, 1989, 281, 464, 40, 4851, 76, 31, 19584, 21, 4155, 37, 14, 6018, 15, 47, 14, 4348, 2478, 26, 9868, 1842, 185, 14,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
python pexpect sendcontrol key characters === I am working with pythons pexpect module to automate tasks, I need help in figuring out key characters to use with sendcontrol. how could one send the controlkey ENTER ? and for future reference how can we find the key characters? here is the code i am working on. #!/usr/bin/env python import pexpect id = pexpect.spawn ('ftp 192.168.3.140') id.expect_exact('Name') id.sendline ('anonymous') id.expect_exact ('Password') *# Not sure how to send the enter control key id.sendcontrol ('???')* id.expect_exact ('ftp') id.sendline ('dir') id.expect_exact ('ftp') lines = id.before.split ('\n') for line in lines : print line
0
[ 2, 20059, 351, 6899, 11557, 2660, 12898, 1246, 1766, 800, 3726, 3726, 31, 589, 638, 29, 20059, 18, 351, 6899, 11557, 12613, 20, 3108, 5281, 8674, 15, 31, 376, 448, 19, 25379, 70, 1246, 1766, 20, 275, 29, 2660, 12898, 9, 184, 110, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Is there a really simple way to process EDIFACT for example D96A? === We are a modern company using modern technology like XML interfaces, but many of our customers want for example electronic invoices from us in an EDIFACT format like D96A. No we cannot use already existing libraries, as they are not written in the C/AL programming language our Navision software uses. So in order to parse it in C/AL I need to understand its specification. But it looks extremely difficult and complicated. So can someone give me an overview how to interpret say D96A and how to parse it?
0
[ 2, 25, 80, 21, 510, 1935, 161, 20, 953, 13, 69, 49, 16839, 26, 823, 13, 43, 4060, 58, 60, 800, 3726, 3726, 95, 50, 21, 773, 237, 568, 773, 1099, 101, 23504, 6573, 18, 15, 47, 151, 16, 318, 5279, 259, 26, 823, 3253, 19, 13379...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
jQuery selectable list with nested table not sized properly in jQuery tab === I'm implementing a jQuery tab in my MVC3 application, but one of the tabs is not sized properly. That is, some of the content is inside the tab, but the following strange formatting on my part is only partially inside the tab: <div id="tabs"> <ul> <li><a href="#tabs-1">Edit Schedule</a></li> ... </ul> <div id="tabs-1"> ... <div id = "scheduleData"> @Html.Partial("_partialView", ViewData["data"]) </div> </div> ... </div> My partial view renders many tables, one with just a head, and the rest nested _inside_ a jQuery selectable list: <table> <thead> <tr> <td>ID</td> ... </tr> </thead> </table> <ol id="selectable> @foreach (var obj in Model) { <li class="ui-widget-content"> <table> <tr> <td>@obj.ID</td> ... </tr> </table> </li> } </ol> I'm not sure whether the tab sizing problem is happening because of the partial view, or my very strange formatting, or both. It is worth noting that only the first table is inside the tab, and any other tables are consistently not in the tab, no matter how large or small the partial view is. This is obviously a sloppy solution, and I was wondering if there is a better way to render a table row inside a selectable list so the jQuery tab is sized correctly. I appreciate your input.
0
[ 2, 487, 8190, 93, 5407, 579, 968, 29, 5618, 69, 859, 52, 13, 6560, 7428, 19, 487, 8190, 93, 6523, 800, 3726, 3726, 31, 22, 79, 17333, 21, 487, 8190, 93, 6523, 19, 51, 307, 8990, 240, 3010, 15, 47, 53, 16, 14, 6523, 18, 25, 5...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
MySQL eating 80-100% CPU starting July 1 Midnight, a day or so following a EBS connectivity issue === I am extremely curious about a recent issue that I experienced with all of my EC2 instances running MySQL. On July 1st at 12:00 AM UTC, both of my Amazon EC2 instances (running in US-EAST region) fired an alarm indicating high CPU usage. I investigated to find that it was MySQL that was eating all of the CPU. I logged in and ran `SHOW PROCESSLIST` to find that **no queries were running** (these servers don't get hit much after business hours). I stopped MySQL, CPU utilization dropped back down to 1-3% (as normal). I restarted MySQL, and it started eating a lot of CPU again. Then, I restarted the server `shutdown -r now`, and the problem went away. Both servers had the exact same problem (running Ubuntu 12.04 LTS). The only relevant item I see in the syslog is: ``` Jun 30 23:59:59 hostname kernel: [14152976.187987] Clock: inserting leap second 23:59:60 UTC ``` I don't think that I have logging enabled for MySQL; whatever the default setting is for Ubuntu 12.04 is what I'm using. If it makes any difference, most of the databases are InnoDB. A day prior, the one instance was affected by a EBS connectivity issue, which caused the server to respond extremely slowly when accessing the disk. I don't believe the other instance was effected (it's in another AWS account and responded okay during the "outage"), but I can't be 100% sure. I wonder if this might have caused MySQL to go crazy? But why wait until midnight? (Watch out! This might be the "red herring" in this mystery) Any thoughts on what might have caused this issue?
0
[ 2, 51, 18, 22402, 5320, 2972, 8, 1036, 3621, 17578, 1422, 313, 137, 6373, 15, 21, 208, 54, 86, 249, 21, 11817, 18, 24026, 1513, 800, 3726, 3726, 31, 589, 3898, 7686, 88, 21, 1764, 1513, 30, 31, 3882, 29, 65, 16, 51, 6695, 135, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Strange behaviour for unique_pointer in Visual Studio 2010 === I tried writing this class #include <memory> class ContainerUnique { public: ContainerUnique(void); ~ContainerUnique(void); private: std::unique_ptr<UniqueElement> u; }; Where UniqueElement is a POD class defined elsewhere. I now define the constructor body like this: ContainerUnique::ContainerUnique(void) { auto tmp = new UniqueElement(1); this->u(tmp); // u is a unique_ptr<UniqueElement>. Should this call compile? } And it complies without exceptions. Running the program I find that after the constructor of `ContainerUnique` has been called, `u` contains a null pointer. Is this the intended behaviour? And what unique_ptr method am I actually calling?
0
[ 2, 2578, 7727, 26, 2619, 1, 3132, 106, 19, 3458, 1120, 498, 800, 3726, 3726, 31, 794, 1174, 48, 718, 6926, 22640, 13, 1, 790, 5171, 93, 1, 718, 12147, 1020, 5312, 13, 1, 317, 45, 12147, 1020, 5312, 5, 2625, 1340, 6, 73, 13, 1,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Full outer join on full column list first, otherwise partial column list === I would like to know whether I could perform a full outer join between two tables on a full column list first, and if this fails, a partial column list. For example: Table A | a | b | c | +-----+-----+-----+ | x | y | z | | q | r | s | Table B | a | b | c | d | e | +-----+-----+-----+-----+-----+ | q | r | s | t | u | | q | r | | x | y | | | | | x | y | Failed query: SELECT * FROM A FULL OUTER JOIN B ON (A.a = B.a AND A.b = B.b AND A.c = B.c) OR (A.a = B.a AND A.b = B.b) Desired result | a | b | c | d | e | +-----+-----+-----+-----+-----+ | x | y | z | | | | q | r | s | t | u | | q | r | | x | y | | | | | x | y | I am using Postgresql. Thanks for your assistance.
0
[ 2, 503, 4896, 1865, 27, 503, 4698, 968, 64, 15, 3190, 7284, 4698, 968, 800, 3726, 3726, 31, 83, 101, 20, 143, 1472, 31, 110, 2985, 21, 503, 4896, 1865, 128, 81, 7484, 27, 21, 503, 4698, 968, 64, 15, 17, 100, 48, 13614, 15, 21,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
PCRE Windows Command Line === I have found an error in PHP's PCRE but before I post a bug report I want to test the same expression via the command line in Windows to see if it has the same error. If the error is in PCRE itself I need to post the report on the PCRE site, otherwise on the PHP site. Are there any tools to run a PCRE directly from the Windows command line using the library I already have installed?
0
[ 2, 5168, 99, 1936, 1202, 293, 800, 3726, 3726, 31, 57, 216, 40, 7019, 19, 13, 26120, 22, 18, 5168, 99, 47, 115, 31, 678, 21, 6256, 1330, 31, 259, 20, 1289, 14, 205, 1803, 1197, 14, 1202, 293, 19, 1936, 20, 196, 100, 32, 63, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
raphael js drawing multiple lines requested by user === I am using raphael js in the following way to create multiple circles or rectangles according to an user input: var xx =parseFloat(document.getElementById("Fem").value); for(var i = 0; i < xx; i+=1) { paper.circle(10 + (20*i) , 20 , 5).attr("fill","#FF2"); } var xy =parseFloat(document.getElementById("Male").value); for(var i = 0; i < xy; i+=1) { paper.rect(35 + (20*i), 15 ,10 , 10 ).attr("fill","#FF2"); //paper.path("M 15 +(20*i) , 420 ,l 0 , -40 z"); } This does the job more or less as I want to, but I would like to have a vertical line from the top of each shape when the iteration is run. paper.path does not work. Would someone please help. I am using this for the first time
0
[ 2, 13874, 487, 18, 3533, 1886, 1560, 6602, 34, 4155, 800, 3726, 3726, 31, 589, 568, 13874, 487, 18, 19, 14, 249, 161, 20, 1600, 1886, 7845, 54, 27181, 18, 496, 20, 40, 4155, 6367, 45, 4033, 13, 8962, 800, 3574, 870, 14712, 721, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How to get osmdroid to appear in Fragment on Android 4+ === I'm attempting to build an app that is natively Android API 15 (4.0.3) with an ActionBar Tabbed UI and a ViewFlipper to switch between tabs. What I can't figure out is how to have OpenStreetMaps (osmdroid) load in a Fragment. Is there any way I can do this without any TabHost or Compatibility Library hacks? A code sample would greatly help, I've been trying to figure this out for days without any luck on Google. Thanks!
0
[ 2, 184, 20, 164, 13, 759, 79, 43, 18524, 20, 1893, 19, 14847, 27, 13005, 268, 2430, 800, 3726, 3726, 31, 22, 79, 6314, 20, 1895, 40, 4865, 30, 25, 1275, 102, 13005, 21, 2159, 357, 13, 5, 300, 9, 387, 9, 240, 6, 29, 40, 1028,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Horizontal list (ul) with multiline list item? === I have a horizontal list (for a nav bar) and i want an individual list item to be multilined. I tried using a `<br />` but that causes the entire list to skip a line Here's what i got for html : <ul class="nav_list"> <li><a href="#">Home<a></li> <li><a href="#">Bar/Bat Mitzvah<br />Tutoring<a></li> <li><a href="#">Early <br />Childhood<a></li> <li><a href="#">Home<a></li> <li><a href="#">Home<a></li> </ul> and css: .nav_list { float:right; height:30px; margin-top:55px; width:510px; } .nav_list li { display:inline; list-style-type:none; } .nav_list li a { font-size:18px; font-family: arial; color:#b64366; text-decoration:none; padding:4px 4px 5px 10px; background-image:url('../images/nav_divider.png'); background-repeat:no-repeat; background-position:right; font-weight:bold; cursor:pointer; } And this is what it should look like (photoshop): ![enter image description here][1] Any suggestions? [1]: http://i.stack.imgur.com/66Pf4.png
0
[ 2, 10095, 968, 13, 5, 1287, 6, 29, 1889, 1143, 968, 9101, 60, 800, 3726, 3726, 31, 57, 21, 10095, 968, 13, 5, 1106, 21, 16048, 748, 6, 17, 31, 259, 40, 1359, 968, 9101, 20, 44, 1889, 15875, 9, 31, 794, 568, 21, 13, 1, 5145, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Decline paypal payments programatically asp.net c# === Hi I have developed an asp.Net MVC3 application which allows a user to view their orders online. I need to integrate functionality that allows a user to decline an order, orders are paid for via PayPal by a customer therefore we are storing the customer's email and the unique transaction ID from PayPal. Is there any way in which I can build functionality to decline this order therefore cancelling the payment and refunding the customer in PayPal? I understand that refunds would be classed as another transaction and commission will be chargeable again, so if it is possible to avoid this then that would be preferable. Any help would be greatly appreciated. thanks in advance
0
[ 2, 5215, 1372, 6720, 11161, 625, 721, 8438, 28, 306, 9, 2328, 272, 5910, 800, 3726, 3726, 4148, 31, 57, 885, 40, 28, 306, 9, 2328, 307, 8990, 240, 3010, 56, 2965, 21, 4155, 20, 1418, 66, 3204, 2087, 9, 31, 376, 20, 18399, 18548,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Web Audio API. Play sound on click of button === I am a complete novice with HTML5 and coding for that matter. I have been trying to get to grips with the web audio API. I want a sound to play at a click of a button. I used a tutorial posted on HTML5Rocks, but cannot get it to work. I have tried to use jfiddle to help me troubleshoot, but to no avail. here's my code: http://jsfiddle.net/ue8WP/
0
[ 2, 2741, 4023, 21, 2159, 9, 418, 646, 27, 10840, 16, 5167, 800, 3726, 3726, 31, 589, 21, 1279, 21999, 29, 13, 15895, 264, 17, 13, 15458, 26, 30, 1161, 9, 31, 57, 74, 749, 20, 164, 20, 4466, 18, 29, 14, 2741, 4023, 21, 2159, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
SQL Server 2012 Insert statement not working === I made an insert statement that runs inside a asp.net page. It gave me an error, so I went to the sql server and ran the statement as it should be and used it to compare with what I wrote in the asp.net page. The thing is, it it writen properly but it doesn't work. It can't seem to detect the database or the tables at all and tells me the table doesn't exist and neither do the colums. The statement looks like this: INSERT [Remisiones].[dbo].[Places] (Name, Type) VALUES ("Planta 1", "Planta") I have also tried using `[dbo].[Places]` and simply `Places` but it gives me an error at the place of the table saying it is an `Invalid object name`. What is it doing?
0
[ 2, 4444, 255, 8128, 563, 14692, 3331, 52, 638, 800, 3726, 3726, 31, 117, 40, 14692, 3331, 30, 1461, 572, 21, 28, 306, 9, 2328, 2478, 9, 32, 492, 55, 40, 7019, 15, 86, 31, 296, 20, 14, 4444, 255, 8128, 17, 717, 14, 3331, 28, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How to print variables inside quotes in message() === I have the following variables: min.v<-5 max.v<-10 and i want to message the following Test this. You entered "5 10" Is this possible to print this with `message()` or `paste()`, since both functions regard quotes as strings. **The variables in the message should be inside double quotes** I have tried `message(as.character(paste(min.v, " ",max.v)))` but the double quotes are ignored. This question is probably the exact opposite of this http://stackoverflow.com/questions/11117321/solve-the-double-qoutes-within-double-quotes-issue-in-r
0
[ 2, 184, 20, 4793, 12157, 572, 18901, 19, 2802, 5, 6, 800, 3726, 3726, 31, 57, 14, 249, 12157, 45, 4232, 9, 710, 1, 8, 264, 2049, 9, 710, 1, 8, 1036, 17, 31, 259, 20, 2802, 14, 249, 1289, 48, 9, 42, 1297, 13, 7, 264, 332, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
PlaceResult object returns latitude/longitude as object, not sure how to get them individually === I'm testing out the Google Places autocomplete feature here: https://developers.google.com/maps/documentation/javascript/examples/places-autocomplete I want to get the latitude and longitude of the Place, but I'm having some troubles. When I use the following code: var place = autocomplete.getPlace(); console.log(place.geometry.location); I get this returned: ![enter image description here][1] When I use it in an infoWindow like this: infowindow.setContent(' <div><strong>' + place.name + '</strong><br>' + place.geometry.location); `place.geometry.location` is then displayed like this: > (53.539834, -113.49402099999998) All I want to do is get the lat and lng separately. `place.geometry.location.lat` doesn't work. Not sure what else to do. [1]: http://i.stack.imgur.com/tOr4u.png
0
[ 2, 209, 29955, 3095, 4815, 16337, 118, 2701, 16731, 28, 3095, 15, 52, 562, 184, 20, 164, 105, 16579, 800, 3726, 3726, 31, 22, 79, 4431, 70, 14, 8144, 1489, 3108, 15990, 1580, 235, 45, 7775, 18, 6903, 26051, 445, 9, 16111, 4875, 9,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
i need Update Query from Mssql to Mysql in LINKED Server === Actually i need to connect Mssql to Mysql , Fortunately i did with MSSQL 2008 R2 linked server i made connection for Mysql Now i want to write some queries for update at a time in both databases when i am trying this query update products set Stock=A.Stock from (Select * FROM OPENQUERY(MYSQL,'Select * From products where Id=8')) A inner join products B on b.Id=a.Id the rows of MSSQL is updated from MYSQL i need to update MSSQL to MYSQL also please help me out ,i am working since last 4 days
0
[ 2, 31, 376, 11100, 25597, 37, 4235, 18, 22402, 20, 51, 18, 22402, 19, 4727, 8128, 800, 3726, 3726, 1121, 31, 376, 20, 6379, 4235, 18, 22402, 20, 51, 18, 22402, 13, 15, 18401, 31, 144, 29, 4235, 18, 22402, 570, 761, 135, 4727, 81...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How can I turn on/off cache L1 for Thrust's algorithms? === How can I switch between cudaFuncCachePreferShared/cudaFuncCachePreferL1 for Thrust algorithms, an example turn off for sort? PS And an additional if you know, how to specify compilation flag in MS VS 2010 to turn off L1 cache in cuda, where must i write (-Xptxas -dlcm=cg)?
0
[ 2, 184, 92, 31, 805, 27, 118, 1299, 16522, 644, 165, 26, 5777, 22, 18, 15935, 60, 800, 3726, 3726, 184, 92, 31, 5521, 128, 272, 5729, 16638, 6909, 2569, 3515, 2407, 16608, 43, 118, 150, 5729, 16638, 6909, 2569, 3515, 2407, 255, 16...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Stubbing File.open with Rspec === I'm attempting to stub File.open in order to test a method I have that reads a CSV file. Here's the model: class BatchTask def import(filename) CSV.read(filename, :row_sep => "\r", :col_sep => ",") end end Here's the spec code: let(:data) { "title\tsurname\tfirstname\rtitle2\tsurname2\tfirstname2\r"} let(:result) {[["title","surname","firstname"],["title2","surname2","firstname2"]] } it "should parse file contents and return a result" do File.stub(:open).with("file_name","rb") { StringIO.new(data) } person.import("file_name").should == result end However, when I attempt to do this I get: No such file or directory - file_name I've been banging my head against this one and can't figure out what I'm doing wrong. Any help would be greatly appreciated!
0
[ 2, 21354, 8136, 3893, 9, 10157, 29, 13, 1224, 12610, 800, 3726, 3726, 31, 22, 79, 6314, 20, 21354, 3893, 9, 10157, 19, 389, 20, 1289, 21, 2109, 31, 57, 30, 11137, 21, 272, 18, 710, 3893, 9, 235, 22, 18, 14, 1061, 45, 718, 1306...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Check for header in csv and ignore header in php === **I would like to check if csv file contain a header and ignore the header.** I have to do a check if the first column is not a character csv file has format : avgTemperature, minTemperature, maxTemperature > $f = fopen("./uploads/" .$filename, "r"); > $string = "avgTemperature"; > if (fgetcsv($f)==$string){ > // read the first line and ignore it > fgets($f); > }
0
[ 2, 2631, 26, 157, 106, 19, 272, 18, 710, 17, 7174, 157, 106, 19, 13, 26120, 800, 3726, 3726, 13, 1409, 49, 83, 101, 20, 2631, 100, 272, 18, 710, 3893, 3717, 21, 157, 106, 17, 7174, 14, 157, 106, 9, 1409, 31, 57, 20, 107, 21,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Include an existing album photo when posting with Facebook Graph API === I already have an Facebook application that I use to upload photos to an user's album, the photo is uploaded to Facebook from the client's hard drive. Now, I want to know if there is a way to include in a Facebook post an already existing image previously uploaded (to an Facebook photo album) so I dont have to upload the image everytime I do the post. I am using the Facebook Graph API and PHP as my coding language, this is what I do to post the image from PHP (all permissions and tokens are fine): //upload authorization $facebook->setFileUploadSupport(true); //post photo to user wall $image = 'image.png'; $facebook_photo_array = array( 'message' => 'this is the image caption', 'source' => '@'.$image ); I will appreciate some help! Thanks in advance
0
[ 2, 468, 40, 3149, 244, 3056, 76, 15669, 29, 9090, 7210, 21, 2159, 800, 3726, 3726, 31, 614, 57, 40, 9090, 3010, 30, 31, 275, 20, 71, 8294, 7064, 20, 40, 4155, 22, 18, 244, 15, 14, 3056, 25, 23782, 20, 9090, 37, 14, 6819, 22, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
gunicorn vs fastcgi for Django deployment === I'm using nginx + fastcgi( manage.py runfcgi ...) on production for some of my Django projects. A lot of people suggests to use nginx + gunicorn. What is advantage of using gunicorn instead of using Django's fastcgi server?
0
[ 2, 1223, 49, 8559, 4611, 1512, 150, 2234, 26, 3857, 14541, 10475, 800, 3726, 3726, 31, 22, 79, 568, 13, 2723, 108, 396, 2754, 1512, 150, 2234, 5, 4705, 9, 6448, 485, 7061, 2234, 13, 9, 9, 9, 6, 27, 637, 26, 109, 16, 51, 3857, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How to use CSS to position a div in the middle of the page while support a dynamic width? === please see the jsFiddle here: http://jsfiddle.net/xv9Wq/9/ What I'm trying to do is create a header banner that is centered and supports a dynamic width. Previously, I had a header banner wrapper that was width 100% to then center the header banner. The problem with that is then the banner blocks the page beneath the header banner. How can I position the header banner in the center of the page while supporting a dynamic content length inside the header banner? Thanks
0
[ 2, 184, 20, 275, 272, 18, 18, 20, 649, 21, 13, 12916, 19, 14, 772, 16, 14, 2478, 133, 555, 21, 7782, 9456, 60, 800, 3726, 3726, 2247, 196, 14, 487, 18, 1707, 12312, 235, 45, 7775, 6903, 728, 18, 1707, 12312, 9, 2328, 118, 396,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Library reference imports ok, intellisense sees everything, objects instatiated... then I build and it can't find anything? === I run into this every once in a while and I never really figured out how to fix it. I have a class library that is in the same solution as the test console project. when I add a reference to the library in the console project and add the using statement, intellisense sees all of the classes just fine. So I write some code and use those classes. All of the class members are showing just fine. Then I hit build. I get an error that the classes from the library cannot be found (are you missing a using directive or an assembly reference?). Now all of a sudden, all my objects are underlined in red and no longer color coded as classes, and the using statement is also underlined in red. The reference to the library is still in the references folder. Wtf If I remove the reference and readd it, its the same thing. It'll see everything just fine until i build. ![enter image description here][1] [1]: http://i.stack.imgur.com/FcqR1.png
0
[ 2, 1248, 2801, 20617, 5854, 15, 14635, 3159, 6498, 6895, 796, 15, 3916, 19, 10631, 49, 1669, 9, 9, 9, 94, 31, 1895, 17, 32, 92, 22, 38, 477, 602, 60, 800, 3726, 3726, 31, 485, 77, 48, 352, 382, 19, 21, 133, 17, 31, 243, 510,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Python: Why is elementtree.ElementTree.iterparse using so much memory? === I am using elementtree.ElementTree.iterparse to parse a large (371 MB) xml file. My code is basically this: context = iterparse('copyright.xml') context = iter(context) dummy, root = context.next() for event, elem in context: if elem.tag == 'foo': author = elem.text elif elem.tag == 'bar': if elem.text is not None and 'bat' in elem.text.lower(): outf.write(elem.text + '\n') elem.clear() #line A root.clear() #line B My question is two-fold: First - Do I need both A and B (see code snippet comments)? I was told that root.clear() clears unnecessary children so memory isn't devoured, but here are my observations: using B and not A is the same as using neither in terms of memory consumption (plotted with task manager). Using only A seems to be the same as using both. Second - Why is this still consuming so much memory? As the program runs, it uses about 100 MB of RAM near the end. I assume it has something to do with outf, but why? Isn't it just writing to disk? And if it is storing that data before outf closes, how can I avoid that? Other information: I am using Python 2.7.3 on Windows. Thanks, Dale
0
[ 2, 20059, 45, 483, 25, 4520, 8101, 9, 27567, 8101, 9, 242, 106, 3574, 870, 568, 86, 212, 1912, 60, 800, 3726, 3726, 31, 589, 568, 4520, 8101, 9, 27567, 8101, 9, 242, 106, 3574, 870, 20, 2017, 870, 21, 370, 13, 5, 25686, 14023, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
jQuery BBQ split URL state into useable chunks === Trying really hard to understand jQuery BBQ and not doing so well. There are a few things I need to figure out, but I'll try to focus this on what I believe is the most important in hopes that knocking that part out will guide me to solving the others. I've got a page with three sections that are each hidden. When a user clicks a nav link, the corresponding section expands and others (if active) are hidden. The URL is updated with a hash representing the page. So `localhost` becomes `localhost/#work`. In my code, this works correctly. Within the `#work` section, there are multiple thumbnails that correspond to different videos and I'm trying to add values into the URL to allow bookmarking and other love, hence using jQuery BBQ. This sort of works, there's a minor issue of the url becoming ugly. `localhost` becomes `localhost/#work=&misery=`. Ugly, but it is updated correctly (and the section stays open as intended). Here's the goods: When a `hashchange` event occurs, my super duper hash-bash function runs and checks the URL for the hash value, then opens the appropriate section. **How, using jQuery BBQ's `.getState()` method, can I pull the videos value from the URL and then click on that thumbnail?** Thanks so much, I know that was long winded but I want to be as clear and descriptive as possible. Please find a jsFiddle below (though I can't get the hashes to show up at all in that environment... ugh!) as well as the raw code. http://jsfiddle.net/danielredwood/n2KWv/2/ JavaScript: function navi(){ var hash = window.location.hash, hspl = hash.split('=')[0], acti = $('.out') test = $.bbq.getState(); console.log(test); if (!$('body').hasClass('work')){ acti.removeClass('out').slideUp(400); $(hash).addClass('out').slideDown(400); } else { if (hspl != '#work') { $('body').removeClass('work'); acti.removeClass('out').slideUp(400); $(hash).addClass('out').slideDown(400); } } } /* Nav */ $(window).bind('hashchange', function(){ navi(); }); /* Thumbnail Clicks */ $('.thumbnail a').click(function(){ $('body').addClass('work'); var name = $(this).attr('id'); $.bbq.pushState(name); return false; }); ​
0
[ 2, 487, 8190, 93, 13, 3490, 1251, 2132, 287, 6362, 146, 77, 275, 579, 15009, 18, 800, 3726, 3726, 749, 510, 552, 20, 1369, 487, 8190, 93, 13, 3490, 1251, 17, 52, 845, 86, 134, 9, 80, 50, 21, 310, 564, 31, 376, 20, 1465, 70, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
syntax for dynamic controls? in asp.net and vb.net === Welp, I'm frustrated now.. partly because I'm new to asp and this seems so simple and I cant get it to work but have in vb several times. I've volunteered for a simple webform survey for customers and I've stuck on creating dynamic controls/ lables for the questions.. The number of questions will vary so I'd hate to change this webform everytime. I'm stumbling over lines 6, 8 & 10: QuestionLabel1.Text = SQLRead.GetString(0) I'd rather do something like this: QuestionLabel(cntr).Text = SQLRead.GetString(0) or ("QuestionLabel" & cntr).Text = SQLRead.GetString(0) or even Me.Controls.Add("QuestionLabel" & cntr) For cntr = 1 To 5 Dim QuestionLabel As New Label() Dim Panel1 As New Panel() Me.Controls.Add(QuestionLabel) QuestionLabel.ID = "QuestionBox" & cntr QuestionLabel1.Text = SQLRead.GetString(0) SQLRead.Read() QuestionLabel2.Text = SQLRead.GetString(0) SQLRead.Read() QuestionLabel3.Text = SQLRead.GetString(0) I know that the syntax is wrong but I'm hoping you guys can look it over, get a sense of what I'm trying to accomplish and tell me if asp.net will allow this and if so what I'm missing. THANKS!
0
[ 2, 22649, 26, 7782, 8671, 60, 19, 28, 306, 9, 2328, 17, 13, 20468, 9, 2328, 800, 3726, 3726, 95, 5478, 15, 31, 22, 79, 10645, 130, 9, 9, 5794, 185, 31, 22, 79, 78, 20, 28, 306, 17, 48, 2206, 86, 1935, 17, 31, 2973, 164, 32...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
MVC3 / Partial Views / Multiple Paginated Lists === **How to I render out two paginated lists on my Home Page?** I am willing to do what it takes - If it means tailoring my code to fit a solution or tailoring an existing solution to fit my code. I have successfully rendered one paginated list to the home page using a partial view. Take a look at my code: Views ..Home > Index.cshtml @foreach (var m in Model.First) { Html.RenderPartial("FirstSummary", m); } <div class="pager"> @Html.PageLinks(Model.PagingInfo, x => Url.Action("Index", new { page = x })) </div> Views ..Shared > FirstSummary.cshtml @model MovinMyStuff.Domain.Entities.First @{ if (@Model.IsActive) { <div class="first-list-item"> <ul> <li> <span class="first-name"> @Model.Property.ToString() @Model.Property.ToString() @Model.Property.ToString() - @Model.Property.ToString() @Model.Property.ToString() @Model.Property.ToString() </span> </li> <li> @Html.ActionLink("Details", "Details", "First", new { area = "", id = @Model.FirstId }, new { @class = "button" }) </li> </ul> </div> } } Controllers > HomeController.cs public ViewResult Index(int page = 1) { FirstListViewModel viewModel = new FirstListViewModel { First = repository.First .OrderByDescending(m => m.FirstId) .Skip((page - 1) * PageSize) .Take(PageSize), PagingInfo = new PagingInfo { CurrentPage = page, ItemsPerPage = PageSize, TotalItems = repository.First.Count() } }; return View(viewModel); } Models > FirstListViewModel.cs using System.Collections.Generic; using MovinMyStuff.Domain.Entities; namespace MovinMyStuff.WebUI.Models { public class FirstListViewModel { public IEnumerable<First> Firsts { get; set; } public PagingInfo PagingInfo { get; set; } } } ViewModels > FirstAndSecond.cs using System; using System.Collections.Generic; using System.Linq; using System.Web; using MovinMyStuff.WebUI.Models; namespace MovinMyStuff.WebUI.ViewModels namespace MovinMyStuff.WebUI.ViewModels { public class MovesAndMovers { public MovesListViewModel movesList { get; set; } public MoversListViewModel moversList { get; set; } public MovesAndMovers() { movesList = new MovesListViewModel(); moversList = new MoversListViewModel(); } } }
0
[ 2, 307, 8990, 240, 13, 118, 7284, 4146, 13, 118, 1886, 19006, 12721, 7227, 800, 3726, 3726, 13, 1409, 1544, 20, 31, 16535, 70, 81, 19006, 12721, 7227, 27, 51, 213, 2478, 60, 1409, 31, 589, 4452, 20, 107, 98, 32, 1384, 13, 8, 100...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How to show tool tip on click on static control and hide tool tip when clicked elsewhere using specifically win32 c++ api === I know how to normally make tool tip. But the problem is tool tip appears when mouse pointer is over control. I want tool tip to appear when static control is clicked. I want to show tool tip only when user clicks the static control and hide the tool tip if user clicks outside the control. What messages should be handled and how to proceed? Any help will be highly appreciated...
0
[ 2, 184, 20, 298, 5607, 4265, 27, 10840, 27, 12038, 569, 17, 3077, 5607, 4265, 76, 15802, 6040, 568, 3524, 628, 3125, 272, 20512, 21, 2159, 800, 3726, 3726, 31, 143, 184, 20, 4147, 233, 5607, 4265, 9, 47, 14, 1448, 25, 5607, 4265, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
DataGrid to excel not showing automatic gridlines === Wondering if anyone can assist. I have an .ashx file which creates an excel document which is populated with a C# DataGrid. This all works well the only problem is when I open the excel document the automatic gridlines are turned off. Is there a way to enable them? Thanks in advance, Air
0
[ 2, 1054, 16375, 20, 20700, 52, 3187, 6715, 7354, 7939, 800, 3726, 3726, 5712, 100, 1276, 92, 5404, 9, 31, 57, 40, 13, 9, 6031, 396, 3893, 56, 9695, 40, 20700, 4492, 56, 25, 11111, 29, 21, 272, 5910, 1054, 16375, 9, 48, 65, 693, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Mysql replication is not working === I'm using mysql 5.22 version for master and slave replication. when I execute the show slave status command it's showing slave_io_state as connecting. how to solve this problem. Please help me the same. Regards, Yasar
0
[ 2, 51, 18, 22402, 23841, 25, 52, 638, 800, 3726, 3726, 31, 22, 79, 568, 51, 18, 22402, 331, 9, 2287, 615, 26, 1129, 17, 5217, 23841, 9, 76, 31, 15644, 14, 298, 5217, 1782, 1202, 32, 22, 18, 3187, 5217, 1, 1963, 1, 3859, 28, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How to achieve functionlity i.e. controlling "Incr Pool Size" or "Decr Pool Size" while establishing connection to SQL? similar to ORACLE === I have asked a question about "Incr Pool Size" or "Decr Pool Size" http://stackoverflow.com/questions/11427362/how-to-resolve-sqlconnection-error-keyword-not-supported-decr-pool-size/11427442#comment15077277_11427442 This is another but different question related to that , in brief ORACLE connection string provides these two option to increase/decrease connection objects when connection pool is empty or full respectively. how can we achieve this with SQL.
0
[ 2, 184, 20, 4689, 1990, 255, 856, 31, 9, 62, 9, 10106, 13, 7, 108, 6711, 3067, 1072, 7, 54, 13, 7, 9522, 139, 3067, 1072, 7, 133, 6814, 2760, 20, 4444, 255, 60, 835, 20, 15759, 800, 3726, 3726, 31, 57, 411, 21, 1301, 88, 13,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Transition from ER way to OOP way === Coming from a traditional E-R diagram Database centric approach to desigining applications, implementing classes using OO approach is causing confusions like shown in examples below 1) Implementing classes for a Many to Many relation. Suppose you have two entities, Professor and College with following relations (I do not know how to draw in SO otherwise I would have illustrated the examples with diagrams): - One Professor may work in different Colleges in different capacities e.g. Lecturer, Guest Lecturer, Lab Assistant, Researcher etc. - One College may/will have many Professor working in different positions like Lecturer, Guest Lecturer, Lab Assistant, Researcher etc. Doing this the ER way, we would have tables like this > CollegeTable (CollegeId, CollegeName)<br/> ProfessorTable > (ProfessorId, ProfessorName))<br/> LecturerTable (LecturerId, > CollegeId, ProfessorId, Timings))<br/> So the many to many relation is a table containing primary keys of both the entities and other relation specific data. If I had to create classes to represent rows of my table they would be like <!-- language: c# --> class CollegeData { string CollegeId; string CollegeName; } class ProfessorData { string ProfessorId; string ProfessorName; } class LecturerData { string CollegeId; string ProfessorId; DateTime Timings; } But doing the same in OOP and mapping entities to class we would have as follows <!-- language: c# --> class College { string CollegeId; string CollegeName; } class Professor { string ProfessorId; string ProfessorName; } class Lecturer { College aCollege; Professor aProfessor; DateTime Timings; } So now doing proper OO way is introducing more load on the system since now we are creating full blown class objects in the many-to-many class instead of only having the ID fields. Consider this implication when we have say a Lecturer add/edit page where we can edit the Timings or change the Professor. We don't need full blown Professor or College objects (since they will have their own master pages for add/edit), only their IDs. 2) Implementing classes for a One to One relation. Extending above example, suppose we have have a Dean Entity with following constraint(for simplicity assume Dean is not a Professor) - One College can have one Dean and one person can work as a Dean in only one college. Again the ER way we will have <!-- language: c# --> class DeanData { string DeanId; int DeanExp; } class CollegeData { string CollegeId; string CollegeName; string DeanId; } , while doing it the OOP way <!-- language: c# --> class Dean { string DeanId; int DeanExp; } class College { string CollegeId; string CollegeName; Dean aDean; } Also are the issues of mapping OO objects with their table structure representation in a relational database when saving or loading the data. Is there any way I could have done above in proper OO way but without having "redundancy"? Or is this a penalty to be paid for doing things the OO way ?
0
[ 2, 4513, 37, 13, 106, 161, 20, 13, 21709, 161, 800, 3726, 3726, 880, 37, 21, 1361, 13, 62, 8, 139, 14161, 6018, 13, 20829, 2141, 20, 1746, 49, 5831, 68, 3767, 15, 17333, 2684, 568, 13, 4328, 2141, 25, 3242, 5677, 18, 101, 1721, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
to get the right media queries to cover phones, tables and regular screens for this widths === I'm working on a project and we are gone do a responsive design and use media queries. Now I read <a href="http://easy-readers.net/books/adaptive-web-design/">Adaptive Web Design</a> by Aaron Gustavson, <a href="http://www.packtpub.com/responsive-web-design-with-html-5-and-css3/book">Responsive Web Design with HTML5 and CSS3 by Ben Frain</a> and other online sites. It's one thing tho I'm still kinda not sure how I'm gone do and thats the media queries for my selected widths. We decided to do it twitter bootstrap style (not using it tho) where it snaps into place rather then having it fluid. 3 types<br /> mobile - size?<br /> tablet - 980px (both landscape and portrait<br /> screen - 1160px My question is what media queries should i go with to cover that? I truly appreciate help, this is one of the hardest parts for me.
0
[ 2, 20, 164, 14, 193, 941, 9386, 2829, 20, 1227, 14830, 15, 7484, 17, 1290, 14236, 26, 48, 9456, 18, 800, 3726, 3726, 31, 22, 79, 638, 27, 21, 669, 17, 95, 50, 1042, 107, 21, 13, 22153, 704, 17, 275, 941, 9386, 2829, 9, 130, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
concat char in sysout gives weird output? === when i run the following code it is giving me weird output. please anybody can explain this to me ? public class T { public static void main(String arg[]) { char a='3'; System.out.println(a+a); } } output : 102 please explain ?
0
[ 2, 1065, 5782, 4892, 19, 10315, 18, 1320, 2352, 5455, 5196, 60, 800, 3726, 3726, 76, 31, 485, 14, 249, 1797, 32, 25, 1438, 55, 5455, 5196, 9, 2247, 11181, 92, 3271, 48, 20, 55, 13, 60, 317, 718, 13, 38, 13, 1, 317, 12038, 1136...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
CSS @keyframes animation flicker === How to fix [`@-webkit-keyframes`][1] animation flicker at the end of its iteration? It is very noticeable on Android 2 on animating with CSS3 [`transform`][2] values `translate`, `translate3d` and `opacity`. You might notice in some posts a suggestions to fix it with: -webkit-transform: translate3d(0,0,0); or -webkit-perspective: 1000; -webkit-backface-visibility: hidden; But after testing it on Android 2.3, I noticed than non of them really fixes the issue. [1]: http://www.w3schools.com/cssref/css3_pr_keyframes.asp [2]: http://www.w3schools.com/cssref/css3_pr_transform.asp
0
[ 2, 272, 18, 18, 13, 1, 4237, 8361, 18, 6236, 18709, 800, 3726, 3726, 184, 20, 6098, 636, 1, 8, 14113, 13703, 8, 4237, 8361, 18, 1, 500, 2558, 165, 500, 6236, 18709, 35, 14, 241, 16, 82, 23534, 60, 32, 25, 253, 20206, 27, 13005...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Adding Comments to Parameter in DLL === I had created a DLL in .NET ,which includes several function.Now I am suing this DLL in another App ![enter image description here][1] I want that whenever the client uses my DLL,somesort of comments must be shown that shows return type,Parameters etc.like this ![enter image description here][2] [1]: http://i.stack.imgur.com/Ayqks.png [2]: http://i.stack.imgur.com/LZDXd.png i see people this using XML files.Is there any alternative way? Thanks in meekness
0
[ 2, 4721, 7534, 20, 18906, 19, 13, 43, 211, 800, 3726, 3726, 31, 41, 679, 21, 13, 43, 211, 19, 13, 9, 2328, 13, 15, 2140, 1103, 238, 1990, 9, 1387, 31, 589, 2538, 68, 48, 13, 43, 211, 19, 226, 4865, 13, 187, 2558, 13679, 1961...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Using XPath with PERL === So, I have never used PERL before, but I am trying to replicate what my c#&XPath code does on Linux using PERL. So, I am using this guide for this most part - http://docstore.mik.ua/orelly/perl3/pxml/ch08_02.htm And I copied and pasted the code in Example 8-6 (The example code won't copy and past over properly) So, if I understand right, I should be able to run that PERL code, put this code in terminal - xmlPerl.pl mydatafile.xml "/inventory/category/item/name" But when I try to run the PERL file, it doesnt work. Here is the error. [root@Perl ~]# perl xmlPerl.pl Can't locate XML/XPath.pm in @INC (@INC contains: /usr/lib64/perl5/site_perl/5.8.8/x86_64-linux-thread-multi /usr/lib64/perl5/site_perl/5.8.7/x86_64-linux-thread-multi /usr/lib64/perl5/site_perl/5.8.6/x86_64-linux-thread-multi /usr/lib64/perl5/site_perl/5.8.5/x86_64-linux-thread-multi /usr/lib/perl5/site_perl/5.8.8 /usr/lib/perl5/site_perl/5.8.7 /usr/lib/perl5/site_perl/5.8.6 /usr/lib/perl5/site_perl/5.8.5 /usr/lib/perl5/site_perl /usr/lib64/perl5/vendor_perl/5.8.8/x86_64-linux-thread-multi /usr/lib64/perl5/vendor_perl/5.8.7/x86_64-linux-thread-multi /usr/lib64/perl5/vendor_perl/5.8.6/x86_64-linux-thread-multi /usr/lib64/perl5/vendor_perl/5.8.5/x86_64-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.8 /usr/lib/perl5/vendor_perl/5.8.7 /usr/lib/perl5/vendor_perl/5.8.6 /usr/lib/perl5/vendor_perl/5.8.5 /usr/lib/perl5/vendor_perl /usr/lib64/perl5/5.8.8/x86_64-linux-thread-multi /usr/lib/perl5/5.8.8 .) at xmlPerl.pl line 3. BEGIN failed--compilation aborted at xmlPerl.pl line 3. What am I doing wrong :( I think it has something to do with the XML and XPath names in the beginning of my code? Do I need to install something to use the XPath framework?
0
[ 2, 568, 993, 8353, 29, 416, 255, 800, 3726, 3726, 86, 15, 31, 57, 243, 147, 416, 255, 115, 15, 47, 31, 589, 749, 20, 22156, 98, 51, 272, 5910, 1569, 396, 8353, 1797, 630, 27, 13024, 568, 416, 255, 9, 86, 15, 31, 589, 568, 48...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How do you render Arrays entries dynamically in JSRender === I'm using jQuery mobile and jsRender to template some JSON objects. I have created a listview in jQuery mobile which outputs: <li><a href="#product-detail" data-ID="2" data-array="0">Product A</a></li> <li><a href="#product-detail" data-ID="5" data-array="2">Product B</a></li> <li><a href="#product-detail" data-ID="8" data-array="3">Product C</a></li> When the list link is clicked (tapped) I wish to render the product-detail page which consists of Array specific Product information and some top level JSON (language related). <h2 id="h2test">{{:productArray[0].Title}}</h2> <div class="row"> <div class="from-column"> <div class="from">{{:language.products.from}}</div> <div class="price">£929.99</div> </div> <a href="#" class="buy-now">{{:language.products.buyNow}}</a> </div> There is a lot more to the template which includes more Array specific Product information and the language stuff. How do I access the {{:productArray[0].Title}} dynamically? i.e. rendering a passed variable for the productArray node? Thanks, Nick
0
[ 2, 184, 107, 42, 16535, 7718, 18, 11399, 7782, 1326, 19, 487, 18, 99, 16706, 800, 3726, 3726, 31, 22, 79, 568, 487, 8190, 93, 3241, 17, 487, 18, 99, 16706, 20, 22894, 109, 487, 528, 3916, 9, 31, 57, 679, 21, 968, 4725, 19, 487...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
parse html table by column NOT row php dom === Ho do you parse an html table td by COLUMN and not by row, using php dom parser(domdocument/ domxpath), meaning parsing a td element based on the column of the table it is in, not which tr it is in?
0
[ 2, 2017, 870, 13, 15895, 859, 34, 4698, 52, 3131, 13, 26120, 11859, 800, 3726, 3726, 2189, 107, 42, 2017, 870, 40, 13, 15895, 859, 15596, 34, 4698, 17, 52, 34, 3131, 15, 568, 13, 26120, 11859, 2017, 4104, 5, 5555, 28132, 118, 1185...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Multiple colour-scaling with lower level plots of ggplot2 === I would like to achieve a different colour gradient every time I add another a geom_line() to my main plot, each time with 'colour' as the scale. Here is a data frame just as an example: df <- data.frame("letter"=c(rep("a",5),rep("b",5)),"x"=rep(seq(1,5),2),"y1"=c(seq(6,10),seq(6,10)/2),"y2"=c(seq(1,5),seq(1,5)/2),"y3"=c(seq(3,7),seq(3,7)/2)) For which I first plot: y1 <- ggplot(df,aes(x=x,y=y1,colour=letter))+geom_line() y1 I then would like to add y1 and y2, which I can do as follows: y2 <- geom_line(data=df,aes(x=x,y=y2,colour=letter)) y3 <- geom_line(data=df,aes(x=x,y=y3,colour=letter)) y1+y2+y3 But I would like the colour gradient (or hue) to be different for y1, y2 and y3! Is it possible to assign something like scale_colour_hue() to each geom_line, or is this only possible for the ggplot? Thanks!
0
[ 2, 1886, 4609, 8, 18, 3430, 68, 29, 987, 662, 18205, 16, 13, 4572, 13221, 38, 135, 800, 3726, 3726, 31, 83, 101, 20, 4689, 21, 421, 4609, 17442, 352, 85, 31, 3547, 226, 21, 6389, 79, 1, 1143, 5, 6, 20, 51, 407, 3798, 15, 206...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Biopython, PYTHONPATH, problems finding modules === Thanks in advance for the help. I installed Biopython, but I am unable to get the computer to recognize the modules. For example, I create a text file in Komodo like this: from Bio.Alphabet import IUPAC from Bio import Seq my_prot=Seq.Seq("AGTACACTGGT",IUPAC.protein) and run it in terminal and receive: Traceback (most recent call last): File "bio.py", line 1, in <module> from Bio.Alphabet import IUPAC ImportError: No module named Bio.Alphabet For the record, I can't get modules to import in interactive mode either. The documentation states that I can append the module search path by exporting to an environmental variable called PYTHONPATH (like with PATH), but when I type 'env' into the terminal, I see no environmental variable of the sort. I'm a biologist--not a computer scientist or programmer. Please bear with my naiveté if this sounds like nonsense.
0
[ 2, 3136, 6448, 11570, 15, 20059, 8353, 15, 1716, 3007, 17113, 800, 3726, 3726, 3669, 19, 3612, 26, 14, 448, 9, 31, 4066, 3136, 6448, 11570, 15, 47, 31, 589, 2343, 20, 164, 14, 1428, 20, 5844, 14, 17113, 9, 26, 823, 15, 31, 1600,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Writing to the plist file === I can load my plist to get my initial starting data by doing the following self.aList = [[NSMutableArray alloc] initWithArray:[[Global sharedInstance] loadPlistFile:@"Data"]]; So i can edit the dictionary and change the values all as I would like. How can I write back to this file so the changes persist through to the next launch of the app? Many Thanks, -Code
0
[ 2, 1174, 20, 14, 351, 5739, 3893, 800, 3726, 3726, 31, 92, 6305, 51, 351, 5739, 20, 164, 51, 2104, 1422, 1054, 34, 845, 14, 249, 1119, 9, 192, 702, 800, 636, 2558, 2172, 7903, 579, 8576, 93, 65, 2499, 500, 19, 242, 1410, 8576, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How can I change which master page is used for a web page? === When creating a new item - "Web Form using Master Page" I get a dialog for choosing the master page. Can I get that dialog for an existing page so I can change its master page?
0
[ 2, 184, 92, 31, 753, 56, 1129, 2478, 25, 147, 26, 21, 2741, 2478, 60, 800, 3726, 3726, 76, 2936, 21, 78, 9101, 13, 8, 13, 7, 14113, 505, 568, 1129, 2478, 7, 31, 164, 21, 28223, 26, 10883, 14, 1129, 2478, 9, 92, 31, 164, 30, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0...
Multiple Line Variable into SQLPlus from Shell Script === What is the best way to pass multiple values from one variable into separate records in an oracle db? I want to take the output from: `hddlist=`\``iostat -Dl|awk '{print ""$1"="$(NF)}'` This returns output like this: hdisk36=0.8 hdisk37=0.8 hdisk38=0.8 hdisk40=5.5 hdisk52=4.9 I want to insert them into a database like so: sqlplus -s /nolog <<EOF1 connect / as sysdba set verify off insert into my_table ##Single Record Here EOF1 How can I systematically separate out the values so i can create individual records that look like this: Disk Value --------- ------- hdisk36 0.8 hdisk37 0.8 hdisk38 0.8 hdisk40 5.5 hdisk52 4.9 I originally tried a while loop with a counter but could not seem to get it to work. An exact solution would be nice but some directional advice would be just as helpful.
0
[ 2, 1886, 293, 7612, 77, 4444, 255, 13349, 37, 3593, 3884, 800, 3726, 3726, 98, 25, 14, 246, 161, 20, 1477, 1886, 4070, 37, 53, 7612, 77, 1725, 742, 19, 40, 15759, 13, 9007, 60, 31, 259, 20, 247, 14, 5196, 37, 45, 13, 1, 252, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Ruby 1.9 thread pools === As I understand, Ruby 1.9 uses OS threads but only one thread will still actually be running concurrently (though one thread may be doing blocking IO while another thread is doing processing). The threading examples I've seen just use `Thread.new` to launch a new thread. Coming from a Java background, I typically use thread pools as to not launch to many new threads since they are "heavyweight." Is there a thread pool construct built into ruby? I didn't see one in the default language libraries. Or are there is a standard gem that is typically used? Since OS level threading is a newer feature of ruby, I don't know how mature the libraries are for it.
0
[ 2, 10811, 137, 9, 518, 9322, 15230, 800, 3726, 3726, 28, 31, 1369, 15, 10811, 137, 9, 518, 2027, 13, 759, 20396, 47, 104, 53, 9322, 129, 174, 1121, 44, 946, 17651, 13, 5, 9371, 53, 9322, 123, 44, 845, 11828, 13, 1963, 133, 226, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Devise + Active Admin Redirect === I am having trouble setting up the redirect for my application. Users should go to their profile (users/show) and admins should go to the admin dashboard.. How do i set this up? Currently getting the following error: NameError in ActiveAdmin::Devise::SessionsController#create undefined local variable or method `admin' for #<ActiveAdmin::Devise::SessionsController:0x007febe12667e8> **Application controller** def after_sign_in_path_for(resource_or_scope) if admin redirect_to admin_dashboard_path else @user end end end
0
[ 2, 29276, 2754, 1348, 21, 43, 2160, 302, 14706, 800, 3726, 3726, 31, 589, 452, 2572, 2697, 71, 14, 302, 14706, 26, 51, 3010, 9, 3878, 378, 162, 20, 66, 5296, 13, 5, 16704, 18, 118, 9303, 6, 17, 21, 43, 2160, 18, 378, 162, 20, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Can't send POST in C# === I have the following problem. I have the method that sends json via POST: public string request (string handler, string data) { WebRequest request = WebRequest.Create(baseUri + "/?h=" + handler); request.Method = "POST"; request.ContentType = "text/json"; string json = "json=" + data; byte[] bytes = Encoding.ASCII.GetBytes(json); request.ContentLength = bytes.Length; Stream str = request.GetRequestStream(); str.Write(bytes, 0, bytes.Length); str.Close(); WebResponse res = request.GetResponse(); StreamReader sr = new StreamReader(res.GetResponseStream()); lastResponse = sr.ReadToEnd(); return lastResponse; } When using the method on the server does not come data in POST. As if this code is not executed. Stream str = request.GetRequestStream(); str.Write(bytes, 0, bytes.Length); str.Close(); On the server i'm using following php script for debug: <?php print_r($_POST); ?> Also tried to write to the stream as follows: StreamWriter strw = new StreamWriter(request.GetRequestStream()); strw.Write(json); strw.Close(); The result - a zero response. In response comes an empty array.
0
[ 2, 92, 22, 38, 2660, 678, 19, 272, 5910, 800, 3726, 3726, 31, 57, 14, 249, 1448, 9, 31, 57, 14, 2109, 30, 11350, 487, 528, 1197, 678, 45, 317, 3724, 3772, 13, 5, 11130, 24641, 15, 3724, 1054, 6, 13, 1, 2741, 99, 10351, 3772, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Attaching files in signature by default on gmail === I notice that people sometimes send emails with their vcards attached. How are they doing this, and is there any way to do it on gmail? Thanks SOCommunity!
0
[ 2, 19514, 68, 6488, 19, 7810, 34, 12838, 27, 489, 8079, 800, 3726, 3726, 31, 3551, 30, 148, 1030, 2660, 8517, 18, 29, 66, 566, 6648, 18, 3638, 9, 184, 50, 59, 845, 48, 15, 17, 25, 80, 186, 161, 20, 107, 32, 27, 489, 8079, 60...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
in socket.io, how do I get the event name from within the functioin === in `node.js` and `socket.io`, many events can be handled by one function: socket.on( 'async.popular_qtns', rows.bind(socket) ); socket.on( 'async.recent_qtns', rows.bind(socket) ); socket.on( 'async.enum_chn', rows.bind(socket) ); socket.on( 'async.enum_tag', rows.bind(socket) ); function rows() { var socket = this; switch( socket.?? ) { case 'async.popular_qtns': // blah blah break; case 'async.recent_qtns': // blah blah break; } } how do I get the event name, eg, 'async.enum_tag' associated with the `socket.on()`?
0
[ 2, 19, 18482, 9, 1963, 15, 184, 107, 31, 164, 14, 807, 204, 37, 363, 14, 2414, 14468, 111, 108, 800, 3726, 3726, 19, 13, 1, 251, 546, 9, 728, 18, 1, 17, 13, 1, 18, 5668, 1198, 9, 1963, 1, 15, 151, 963, 92, 44, 9006, 34, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
ASP.Net MVC 3 with Oracle === I am working on a project using Asp.net mvc 3 and planning to have oracle 11g database as back-end. I was able to access oracle server with no problem and data loaded successfully into an html table. The problem comes when I try to add, edit or delete a record. I believe it is a very simple issue, but till now, I couldn't figure it out. The following simple model is used: class Country { public int CountryId { get; set; } public string CountryName { get; set; } } The CountryId feild was created at Oracle using NUMBER(10) as I thought this will work as SQL Server Integer. But an exception was raised, indicates that it couldn't take the value as Edm.decimal ! I tried to make it NUMBER(19) and changed the CountryId to long and still getting the same exception. I spent long hours searching for an open source project that is using asp.net mvc with oracle, but I couldn't find any! Any idea, why oracle is not supporting integer, long? how to make it working as expected with my MVC project?
0
[ 2, 28, 306, 9, 2328, 307, 8990, 203, 29, 15759, 800, 3726, 3726, 31, 589, 638, 27, 21, 669, 568, 28, 306, 9, 2328, 307, 8990, 203, 17, 2334, 20, 57, 15759, 547, 263, 6018, 28, 97, 8, 2451, 9, 31, 23, 777, 20, 1381, 15759, 81...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
RewriteRule to cause subdomain to load another DocumentRoot? === Apache (mostly) noob here... could sure use a little help with what I am trying to do with a `RewriteRule` in `.htaccess`: ...to causes URLs using our `sharpedge.` subdomain to auto-load from the `Internet_IE` directory - one level deeper than the site root. I have this in `httpd.conf`: [snip] NameVirtualHost 11.22.33.44 <VirtualHost 11.22.33.44> Options All +ExecCGI ServerAdmin hostmaster@ourhost.com DocumentRoot /var/www/html/ourdomain.com ServerName ourdomain.com ServerAlias www.ourdomain.com DirectoryIndex index.htm index.html index.dna #--------------------------------- <IfModule mod_rewrite.c> RewriteEngine on RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization},L] </IfModule> #--------------------------------- </VirtualHost> <VirtualHost 11.22.33.44> Options All +ExecCGI ServerAdmin hostmaster@ourhost.com DocumentRoot /var/www/html/ourdomain.com ServerName sharpedge.ourdomain.com DirectoryIndex index.htm index.html index.dna #--------------------------------- <IfModule mod_rewrite.c> RewriteEngine on RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization},L] </IfModule> #--------------------------------- </VirtualHost> [snip] ...and this in .htaccess (in the site root, here: /var/www/html/ourdomain.com/) Options -Indexes <IfModule mod_rewrite.c> RewriteEngine On RewriteBase / RewriteCond %{HTTP_HOST} ^sharpedge\.ourdomain\.com$ # years ago this next line was used here, but in httpd.conf: (I don't know what it was supposed to do) # RewriteRule ^(.+) %{HTTP_HOST}$1 [C] RewriteRule ^sharpedge\.ourdomain\.com(.*) /var/www/html/ourdomain.com/Internet_IE/$1 [L] </IfModule> ..but nothing happens from the RewriteRule; it is as if the RewriteRule was not there. I'd much appreciate any suggestions.
0
[ 2, 27891, 16154, 20, 1679, 972, 537, 6232, 20, 6305, 226, 4492, 14032, 60, 800, 3726, 3726, 17140, 13, 5, 18397, 6, 90, 4995, 235, 9, 9, 9, 110, 562, 275, 21, 265, 448, 29, 98, 31, 589, 749, 20, 107, 29, 21, 13, 1, 99, 9657,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...