text
stringlengths
8
267k
meta
dict
Q: Why does my function get called twice in jQuery? I have the following jQuery $('img[title*=\"Show\"]').click(function() { //$e.preventDefault(); var position = $('img[title*=\"Show\"]').parent().position(); $('#popover').css('top', position.top + $('img[title*=\"Show\"]').parent().heigh...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621616", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How can I use Visual Studio 2010 with the Visual C++ 2008 compiler? I want to use Visual Studio 2010 with the 9.0 compiler, how can I do this? I need this so I can use DarkGDK, however I do not want to switch the IDE. A: It's right there in your project properties, "Platform Toolset" defaults to "v100". Just chan...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621621", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: int(int(-2)/unsigned(2)) = 2147483647 no warning I have a code similar to this: template<typename Ta, typename Tb> Ta doStuff(Ta a, Tb b) { ... return a/b; } As the title says such code would return wrong values with Ta=int Tb=unsigned. Is there a way to get a warning by g++ for this case ? A: Yes. Use -W...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621622", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Deleting file from static method error: Access to the path ... is denied My host swears the ASPNet account has full access to the folder some photos reside in. I'm trying to delete a photo, here's the C#: public static bool Delete(string pathAndFilename) { var path = HttpContext.Current.Server.MapPath(pathAndFil...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621623", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to implement jquery ajax call client->server method in mvc3? Q1: Can somebody provide code example for jquery ajax to server method call in mvc3? Q1a: Does the server return have to be a Json result returned from server side? What are my options with the returned data from the server side method (json, just re...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621624", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Multi-server file storage and sharing causes website to hang - other websites on same server remain accessible I'm trying to make a system where files are stored on Main Servers, and if a user chooses, these files can be copied over to Backup Servers to prevent data loss at a HDD crash but it's not going as planned....
{ "language": "en", "url": "https://stackoverflow.com/questions/7621625", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: What does the 'hash' method do in Objective-C Occasionally, when I am looking down the list of selectors that a object responds to, I see hash come up. For a while now, I have wondered what it meant, but I never came around to finding out. I would really appreciate it if you could tell me what the selector does and ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621626", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: Advice on Rails and CI, how often does this run exactly? or what is common practice First off, is autotest and cruisecontrol performing the same sort of CI tasks? I want to setup something that will run my unit tests, and also integration tests on my local MBP computer i.e. I don't have a seperate computer for this ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621633", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Software protection / code obfuscation that does not trigger antivirus false positives I'm looking for software protection and/or code obfuscation software like Oreans Themida, VSProtect, ASPRotect and similar. However, antivirus false positives is a deal-breaker for me. I cannot inconvenience or scare away our legi...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621638", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "9" }
Q: How do you add indexes to your Mongoid database in Padrino? I need to be able to add indexes to my Mongoid database in a Padrino project. I saw that they added rake tasks for this here: https://github.com/padrino/padrino-framework/commit/ec8a267f477ac4dc88a66c84fffb17ac26190a22 And it seems that they should be acce...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621641", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Need suggestion in creating an AlertDialog in Android I have the following code called when a button is pressed in my activity. AlertDialog.Builder alertDialog = new AlertDialog.Builder(this).create(); alertDialog.setTitle("Alert 1"); alertDialog.setMessage("This is an alert"); ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621650", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Load category specific to device I have an iPhone app that I'd like to make universal, most views can be kept the same, but there are some minor modifications that need to be made for the iPad. Is it possible to load a category depending on what device the user is using? Or is there a better way of doing this? A gen...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621652", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Android Custom Gallery Widget crashes with java.lang.OutOfMemoryError: bitmap size exceeds VM budget When scrolling back and forth a bunch of times on the image gallery my app crashes with: java.lang.OutOfMemoryError: bitmap size exceeds VM budget I need the gallery to show two images vertically: * *The top one...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621655", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Matrix Multiplication in Python Changes the Result Dimension I have 1X2 matrix, Mu_I.transpose(), and a 2x2 matrix, Covariance_I_Inverse. The result of multiplication should be a 1x2 matrix, but my output is a 2x2 matrix. Why? How can I get a 1x2 Matrix? >>> Mu_I.transpose() [[ 10.02010924 9.99184818]] >>> Mu_I.t...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621656", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Element of Matrix is the Memory addres and not the value of element I have a matrix homework. When I run the program, in the console It always returns by the memory address and not by the values. I am European, I used the German locale. I've thought that maybe the localization is the problem, so I've changed to US, ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621657", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Why isn't my div position getting dynamically calculated? I have the jQuery: $('img[title*=\"Show\"]').live('click', function(e) { //$e.preventDefault(); e.stopImmediatePropagation(); var position = $('img[title*=\"Show\"]').parent().position(); $('#popover').css('top', position.top + $('img[t...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621660", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How do I plug into socket.io's built in logging system to generate my own messages? socket.io seems to have a basically sensible logging system for all its internals. How do I get at that logging object myself so I can generate my own log messages at appropriate levels? It bugs me that my console.log() messages are ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621662", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "7" }
Q: ode solver event location index in MATLAB Suppose I am trying to solve a system of differential equations using an ode solver in MATLAB. Suppose also that I have defined an events functions to locate three different events which are all terminal. I have noticed that on some occasions the ie quantity that is returned...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621664", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: matlab to python: get matlab cell array values I am very new to matlab and python and need to use some values in python from the matlab cell array. I have a cell array of integers that after i execute this line of code and print the result, i get this: a = loadmat('file.mat') print a {'__version__': '1.0', '__head...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621685", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: grails message.properties - how to debug I have entries added in message.properties to display customized error messages that totally work, e.g. address.street1.blank=Please provide a street address or P.O. Box I have other entries that all the sudden can't be found after the rename of a class, e.g.: billingshippin...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621688", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: An Int argument in the ArrayList, what is it? What is the difference between this: ArrayList<String> test = new ArrayList<String>(); and this: ArrayList<String> test = new ArrayList<String>(3); I just tested the Array and I really see no difference.. I always see people using a number there, what is it for ? A: I...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621691", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-3" }
Q: observe bookmark added/updated/removed in android browser I am using Content-Observer to observe the Android-Boroswers browser.db which stores information about both history & bookmarks. My requirement is that i want to get notified only if a BOOKMARK is added/updated/removed & update my bookmarks list. But my liste...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621692", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: OCR library for Java: compiling tesseract on Windows 64-bit I'm using ImageJ for processing document images (business documents) and I am looking for a good OCR library to retrieve text from some regions. Currently I am using Asprise, but the results aren't very reliable. Certain characters often get confused (0 be...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621700", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Combining two lists in Scala From 2 lists of the form List[(Int, String): l1 = List((1,"a"),(3,"b")) l2 = List((3,"a"),(4,"c")) how can I combine the Integers where the Strings are the same to get this third list: l3 = List((4,"a"),(3,"b"),(4,"c")) Right now I'm traversing both of the lists and adding if the strin...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621705", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "19" }
Q: Confused about Andengine Coordinate system(s) When I create a sprite at (0,0) and it is centered on the screen and I ask the camera what it's center is (getCenterX and getCenterY) it says (640,400). I am pretty new with Andengine so there's clearly something basic about coordinates that I am not understanding. A: N...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621708", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: how to prevent blur() running when clicking a link in jQuery? i have: <input type="text" /> and $('input').blur(function(){ alert('stay focused!'); }); I want to prevent the blur function running when I'm "blurring" by clicking on an anchor element. I.E. if i tab to another input, click somewhere on the page e...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621711", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "34" }
Q: How do I initialize the mutex locks and condition variables pthread_mutex_t qlock[5] = PTHREAD_MUTEX_INITIALIZER; pthread_cond_t qcond[5] = PTHREAD_COND_INITIALIZER; It is giving me error as follows... error: array must be initialized with a brace-enclosed initializer .. Please, can somebody debug this or tell me ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621713", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: using the Camera api with phonegap on symbian I can't figure out why this isn't working.. can't check this on the nokia simulator because it doesn't simulate a camera.. and the phone app either crashes or just don't bring any picture I tried both Base64 method and imageURI method (with different buttons on the html...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621717", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to check validaty of variables names dynamically generated by URI I am building router for my custom MVC project. In my router, for pretty URL names, I ran into problem. What is the best practice for dealing with dynamically generated variables names via URI? Example: http://knjiskicrv.comoj.com/book/id/2/ Will ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621719", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: My application tries replace another my application My application tries replace another my application. I add aplication on git https://github.com/szalek/AndroidLevel1. When I install the application 'Vinyl' and next install the application 'TeamLeader1/'. I see message 'The application you are installing will r...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621723", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Split a string into words by multiple delimiters I have some text (meaningful text or arithmetical expression) and I want to split it into words. If I had a single delimiter, I'd use: std::stringstream stringStream(inputString); std::string word; while(std::getline(stringStream, word, delimiter)) { wordVector...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621727", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "40" }
Q: Get and set values of a form How can I get the values of all visible fields in a form (with several fields) and set them in a array or something else? After I would like to get these values from the array and set them to the visible fields in the same form (such as a clear and undo function of a form)? My form has s...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621729", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: iOS - How to display data from plist when there is more than one key? I am able to get data from plist but it seems my cellForRowAtIndexPath is not getting called as none of NSLog printing anything from inside the method. here is my code :- - (void)viewDidLoad { NSString *path = [[NSBundle mainBundle] pathForRe...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621731", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Arranging 3 letter words in a 2D matrix such that each row, column and diagonal forms a word You are given a dictionary of 3 letter words and have to find a matrix of 3x3 such that each row, column and diagonal forms a word in the dictionary. The words in the dictionary are sorted and you can assume O(1) time for re...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621733", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "12" }
Q: JDBC and MySQL, how to persist java.util.Date to a DATETIME column? I'm struggling to understand how to get it to work. I have a prepared statment, and I want to persist a java.util.date. It doesn't work. I tried to cast it to java.sql.Date, and it still doesn't work. what's the issue with java date framework, it's ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621736", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: Make child div match height of parent div, and make padding apply to a border in a div I have two questions applying to my website. Please view the source to help answer these two questions. * *I want the border inside the div "nav-cont-seperator" to be shifted down 10px. I can't get padding to fix this problem, ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621737", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: VB.Net form as part of desktop I've spent a while searching around and I can't find a solution to this: I have a transparent, borderless form that displays a clock. I can load this just fine, but I want the clock to be part of the desktop, so it cannot take focus, is behind other applications, and is not hidden with...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621738", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: XCode 4 Interface Builder: How to access a drawn object I'm very new to iPhone development. I drew a View using the Interface Builder in XCode 4. Currently the only thing inside is a Label (taken from the Object Library in the Interface Builder (So this is a UILabel, right?) ). I've set the tag of it to 6543 as reco...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621739", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: 1px shared :hover border on two elements Two inline-block elements next to each other. .e{border:1px #ccc solid} .e:hover{border-color:#555} What I'd like is to reduce the 1px+1px border between them to a shared 1px border. To illustrate. --------- | | | --------- Select first element. +++++----- + + | ++...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621749", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "8" }
Q: How do I retrieve Haystack SearchQuery parameters I am looking for a way to serialize a Haystack search query (not the query results) so that I can reconstruct it later. Is there a way to do this without having to intercept the parameters from off of the request object? For context, I want users to be able to sub...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621760", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Strange issues with drop down list of Combobox Once again I can't find a neat solution for a simple UI problem in WPF. I want the combo box drop down list to appear whenever combo box gets focus. So I wrote this in the got focus event: private void comboBoxAC_Cat_GotFocus(object sender, RoutedEventArgs e) { ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621765", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: What's the appropriate way to colorize a grayscale image with transparency in Java? I'm making an avatar generator where the avatar components are from PNG files with transparency. The files are things like body_1.png or legs_5.png. The transparency is around the parts but not within them and the images are all gray...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621774", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: JQuery not sliding folder I am trying to get a iPhone looking folder menu bar. When i click each item (info tab_(number), it should open the appropriate "infotab_(number)_s" div. _s standing for "show". When one is open and the user click another item on the menu bar, it should close and open the one they clicked. M...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621776", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Visual studio 2005 debugging is very slow on windows7 When i debug apps on windows7 using VS 2005, it's very slow. just general slowness. works fine on xp. running outside of the debugger is normal. Even when i start apps outside the debugger then attach and debug it is normal. im running VS 2005 in Vista compatib...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621780", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: jQuery tmpl display loading image on images I have a template like so <script id="itemtemplate" type="text/x-jquery-tmpl"> <img id="photo${id}" src="${$item.image(filename)}" /> </script> which works nicely with displaying images but between the page loading and the image actually being displayed, I would like ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621788", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Parsing xml with jquery with conditional for attributes I was tryng to parse this xml: http://henriquebarone.animatubo.com/spider/jquery/teste.xml Writing this code: $(document).ready(function(){ $.ajax({ type: "GET", url: "teste.sif", dataType: "xml", success: Parser });...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621790", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How to apply Toggle method for another method? I have a script with jquery, and it is running but not as expected, I do not know where the location is wrong. <img onclick="$(this).click('toggle', function(){ $(this).animate({width : '1024px', height : '500px'}); },function(){ $(this).animate({width : '100px...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621795", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How do I sort an array of ints in cocoa? I'm brand new to programming on the Mac (i.e. xcode and cocoa) and I'm trying to simply perform a bubble sort and am having a lot of difficulty with this. The goal of this is to filter an image using a median filter by using a 9 pixel kernel. I take in the grey scale values ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621799", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How to fire window.onresize event? I am trying to fire the resize event on window programmatically: var evt = document.createEvent('HTMLEvents'); evt.initEvent('resize', true, false); window.dispatchEvent(evt); That unfortunately does not work. I am trying to make ExtJS library to do recalculations, and it uses DOM...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621803", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "9" }
Q: Destroy jScrollPane How to remove jScrollPane using destroy. Please can you give a simple example for the following code: $(document).ready(function() { $(".div1").jScrollPane(); }); <div class="div1">Some text...</div> A: To destroy an instance of jscrollpane (v2): var element = $('.div1').jScrollPane({}); ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621805", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "7" }
Q: An error occurred during the compilation of a resource required to service this request What this means? Server Error in '/' Application. Compilation Error Description: An error occurred during the compilation of a resource required to service this request. Please review the following specific error details and mod...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621809", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "17" }
Q: Hibernate parent/child relationship. Why is object saved twice? I am looking into Hibernate's parent/child relationships. I have 3 entities Employee Customers and Orders. Their relationship is Employee 1 <-> N Orders Customer 1 <-> N Orders I want to be able to save/update/delete Customer objects and Employees ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621810", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Web Printing Multiple Printers I'm building a web application that is primarily ASP.NET MVC / Javascript. The application needs to be able to print certain content to a label printer and other content to a standard printer. I'd prefer for the user to be able to select a default printer for each one rather than havin...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621813", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: JavaMonkey Canvas I've been trying to get Java monkey engine-3 to render to a canvas/panel object so it can be embedded in a GUI. I'm sure this must be possible but searching around every program i can find just extends the simpleapplication class. Any advice on how to do this? Even just a link to some good example...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621815", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: C++ 'AND' evaluation - standard guaranteed? Possible Duplicate: Safety concerns about short circuit evaluation What does the standard say about evaluating && expressions - does it guarantee that evaluation of parameters will stop at the first false? E.g.: Foo* p; //.... if ( p && p->f() ) { //do something } ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621817", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Java regex patterns I need help with this matter. Look at the following regex: Pattern pattern = Pattern.compile("[A-Za-z]+(\\-[A-Za-z]+)"); Matcher matcher = pattern.matcher(s1); I want to look for words like this: "home-made", "aaaa-bbb" and not "aaa - bbb", but not "aaa--aa--aaa". Basically, I want the following...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621821", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Access local files through Google chrome extension? I need to load a list of names into my google chrome extension from a local file, How can this be done? what if the file is shipped with the extension itself? A: If this file is shipped with your extension then you can just load it with XMLHttpRequest inside backg...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621822", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "10" }
Q: Framework for CSS in Rails 3.1 Which framework do you use in Rails 3.1? I basically want to have a standard set of mixins like gradient and rounded corner etc, but maybe there are other advantages of certain frameworks that I am not aware of. Can you please recommend a framework to use with Rails 3.1 to cover most o...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621824", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Architecture more suitable for web apps than MVC? I've been learning Zend and its MVC application structure for my new job, and found that working with it just bothered me for reasons I couldn't quite put my finger on. Then during the course of my studies I came across articles such as MVC: No Silver Bullet and thi...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621832", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "51" }
Q: How would you receive a file sent with 'sendfile'? I'm trying to implement a basic file server. I have been trying to use the sendfile command found here: http://linux.die.net/man/2/sendfile I'm using TCP. I can have it send fine, but its sending in binary and I'm not sure if thats the hang up. I am trying to recei...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621837", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Facebook iOS Application Cannot Log In On Device This is a very frustrating issue. The DemoApp project from the iOS SDK from Facebook works just fine on the simulator but when I put it on the device it won't get past the log in page. The only changes made to the code were: 1) Replaced the appID in the view control...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621841", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Can't get UILabel to show properly on top of UITableView I am struggling to achieve what I thought was nothing but a 1' coding but apparently adding a UILabel above my UITableView in a UITableViewController is not a piece of cake...? Here is the code (yes basic, I know): UILabel *label = [[UILabel alloc] initWit...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621844", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Using JQuery for CSS vs Stylesheet Because I like keeping all source code in one file (per class), I decided to add all style and CSS using JQuery objects, i.e: jquery : $('<div/>', { id:'Object', css:{ height:'100%', width:'69%', color:'white', ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621846", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-1" }
Q: C# Garbage collection Say we have: public void foo() { someRefType test = new someRefType (); test = new someRefType (); } What does the garbage collector do with the first heap object? Is it immediately garbage collected before the new assignment? What is the general mechanism? A: No, there is nothing that ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621848", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: What is the best way to build php from source CentOS I am building php from source on a new CentOS box and as usual I have to wrangle up all the various configuration options I might need. This gets tricky because there are various extensions that I want and certain options that I always for get to put in the .confi...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621853", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Reusing jQuery Code ? I have some jQuery Code, which I am planning to use in many pages in my asp.net web form application. Example: Create User using jQuery dialog box code. In Asp.net we employ a user control to reuse the same piece of code over and over. Any ideas on how can I reuse jQuery code? A: Typically yo...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621854", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: template specialization for all subclasses I would like to define a C++ template specialization that applies to all subclasses of a given base class. Is this possible? In particular, I'd like to do this for STL's hash<>. hash<> is defined as an empty parametrized template, and a family of specializations for specif...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621856", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "14" }
Q: Approach for file Uploads to service from Web Server I have to create service that can get files from any authorized source and save them on file server. Then return back response with url for that resource. The issue is that the service could be accessible from any web site or app. In case of Web site, what would b...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621857", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Why does my table tr td:hover only work for the th header row?, not for any other rows? I have this code in jsfiddle and I would like the rows to highlight when I hover over them. I have tried the usual technique that works for me, but on this one, it only highlights the th header row, and not the table rows. View t...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621864", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Passing (ID) argument from aspx page to javascript function which updates ID somewhere else on the page So imagine I have a table which is a list of videos, with associated descriptions and links. On the page there is only ever one video shown. When a link is clicked, I want that click to take the ID of the correspo...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621867", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Use of __attribute__'s in ARC-managed Code When ARC came to Objective-C, I did my best to read through the Objective-C Automatic Reference Counting (ARC) guide posted on the Clang project website to get a better hang of what it was about. What I found there (and no where else) was mention of using __attribute__ decl...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621869", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Where does Windows PowerShell set $profile? I would like to move my default "My Documents\WindowsPowerShell" folder. However, when I try this, PowerShell of course can't find $profile. Is there a file or something that I can edit to point PowerShell to a different startup folder? A: What I can suggest is that you d...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621872", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "7" }
Q: how to enable java file in realm to all users i have a web service that i want to enable for use to all users (web service is written as java class). I use realm to configure my website security. How can i enable this resource in web.xml? thanks A: This allows everyone (without login) to access the resource (there ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621876", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Writing data to file but file still contain NULL Related to my previous post but its not a duplicate of that.Now I have tried something and Here I am asking you about the logical error in code. /*u_int8_t ....etc are alias for uint8_t...etc so don't bother about them*/ void crypt(u_int8_t *key, u_int32_t keylen, ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621885", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to display intent chooser when long click listview item? I have a list view that contains some data, I want to share it by through intent chooser. I found long click on a listview item will trigger context menu event, and the common way to use a context menu is the build a menu in onCreateContextMenu() and then ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621892", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to get Missed call & SMS count I want to get the count of missed calls and unread messages in my application. and I'd like to open the relevant application when user click on the count. Now biggest problem is how to get the count? I searched online but couldn't find any solution. Thanks in advance. A: http://de...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621893", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: Android MarketPlace: reserve namespace I have heard the best way to stop someone stealing/publishing your signed .apk before you publish it yourself to the Google Android markeyplace is to upload a dummy release .apk with the same namespace /name, ahead of the publish date. I have done this but it is in an 'unpublis...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621895", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Python: logging module - globally I was wondering how to implement a global logger that could be used everywhere with your own settings: I currently have a custom logger class: class customLogger(logging.Logger): ... The class is in a separate file with some formatters and other stuff. The logger works perfectly...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621897", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "74" }
Q: How To Parse Date From any datetime format to dd/mm/yyyy? i want to parse any datetime format to dd/MM/yyyy format. here is my code // dates i am providing are // Sat, 01 Oct 2011 17:30:00 +0400 // and // Sat, 01 October 2011 12:21:23 EST Datetime dt = Convert.toDateTime(pubDate); which is giving me following ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621899", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to add the path for publickey.xml file to the InputStream in android? Where to put the file publickey.xml? //how to place the path for publickeyfile.xml here? InputStream in = //the objectipnutstream that gets the inputstream ObjectInputStream oin = new ObjectInputStream(new BufferedInputStream(in)); try { ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621900", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Updating mongodb references errors out due to field names I have a MongoDB collection and I'm trying to update all the entries in it to change the name of a field used to store a reference. The Query I'm using is db.products.find().forEeach(function(p) { p.newField = p.oldField; db.products.save(p); }); The pro...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621901", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: float to integer in python If I want to convert a float to an integer in Python, what function do I use? The problem is that I have to use a variable passed through the function math.fabs (Absolute Value) as an index for a list, so it has to be an int, while the function math.fabs returns a float. A: Use the int() ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621903", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Emulating Django models ? (Simple implementation - Missing something) I am trying to emulate django models : In Django : from django.contrib.auth.models import User if User.objects.get(pk=1) == User.objects.get(username='root') print 'True' else: print 'False' # True is printed My implementation : clas...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621904", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-1" }
Q: What's a good resizable, random access, efficient byte vector class in Java? I'm trying to find a class for storing a vector of bytes in Java, which supports: random access (so I can get or set a byte anywhere), resizing (so I can either append stuff to the end or else manually change the size), reasonable efficienc...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621905", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: What is the purpose of home/remote interfaces EJB 3.1 I have recently started reading about Java EE6 and in the examples I follow I need to make remote interface. What is the purpose of this? I also read about home interfaces, but I don't understand. I have never done enterprise programming before so I can't relate ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621907", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Send POST parameters in header()? I'm making a register page, signup.php, and basically what I want it to do is check for errors and if there are none, redirect to register.php. That is fine and whatnot, but register.php is the page where the actual account is made (e.g. mySQL query). Of course, in order to do that,...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621909", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Extracting text from a html file? I have a web page which contains a bunch of text and I want to extract just the text from the page and write it to a file. I am trying to use BeautifulSoup but am not sure it easily does what I want. Here is the story: I believe that the text I want to extract lies between: <td c...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621910", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: jquery live() and $this I'm having trouble with jQuery's live. The div one should slidedown when the div comment of the same container div is clicked on. What is happening is every div one is sliding down regardless of their containers. How do i fix this? I think it is the $this function but i don't know how to im...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621916", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: @Scope("prototype") bean scope not creating new bean I want to use a annotated prototype bean in my controller. But spring is creating a singleton bean instead. Here is the code for that: @Component @Scope("prototype") public class LoginAction { private int counter; public LoginAction(){ System.out.println...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621920", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "158" }
Q: Fill an array with random numbers android/ java I'm having trouble doing the following and have no idea how to do it: I would like to fill an array generated with random numbers (1-40) and also make it so that the number doesn't repeat. Also, is there a way to make the array go to the next value on its own using. So...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621928", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: InnoDB maximum key length This is a fairly straight forward question but I'm having a problem finding a clear answer googling around. On MySQL 5.1.53, using InnoDB, and a varchar(1024) field (I'm indexing Exchange 2010 Event IDs). I'm wondering what the maximum key length is when I index this field. I'm wondering if...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621929", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: C++ stream polymorphy on stack? I would like to do something like this: std::wistream input = std::wifstream(text); if (!input) input = std::wistringstream(text); // read from input i.e. have text either interpreted as a filename, or, if no such file exists, use its contents instead of the file's contents. I could ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621944", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How could I block access from visitors from certain countries to a file on my site (xyz.com/thisFile.php)? I need to block visitors from certain countries from uploading images - but they should be able to access the site. For e.g. I've a site xyz.com. The way I have it set up currently, all visitors from blacklist...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621945", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Why did this source code allocate 16 bytes? (gdb) disas /m main Dump of assembler code for function main(): 2 { 0x080483f4 <+0>: push %ebp 0x080483f5 <+1>: mov %esp,%ebp 0x080483f7 <+3>: sub $0x10,%esp 3 int a = 1; 0x080483fa <+6>: movl $0x1,-0x4(%ebp) 4 int b = 10; 0x080...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621948", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: jquery-ui accordion issue: animation freezes + content not showing when clicking I was trying jQueryUI accordion. I created a test site, copied the code and put things in place. It works fine. Then I tried to put it in my website. In my website, I have two menu. One is horizontal, on the top. The other is vertical, ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621950", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: about android linkify for maps I am using linkify in my android app to auto recognize addresses. It works with some addresses but not others. One of the things that I noticed was that capitalization is an important thing for the address to be recognized. Spelling is also important. However, even with these, I have n...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621956", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: How to put span content on top of all other elements without wrapping? I have a span next to each form element on a page that shows an error if there is one. There are basically two columns on the page, a left and a right. I'm trying to get the span to display from the left column all the way across the page (not ge...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621959", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Unable to generate a temporary class (result=1) any idea? All of a sudden, out of nowhere, I get this response from my web service hosted locally Unable to generate a temporary class (result=1). error CS0009: Metadata file 'c:\Windows\Microsoft.NET\Framework\v2.0.50727\mscorlib.dll' could not be opened -- 'Unknown ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621960", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: A python web framework for google app engine (Please note that this question and some of the answers are old) I want to use an existing python framework to develop an application on google appengine. It should be quick and easy to start and support test driven development practices in an easy way. Can you recommend...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621984", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: Google Translate style select menus I want to style an HTML select menu with CSS in a similar style to how Google does it on Google Translate (translate.google.com). I have looked for tutorials online but everything used jQuery. How can I make something similar to this but using CSS to style it? I hope you can under...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621997", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }