text
stringlengths
8
267k
meta
dict
Q: What are good ruby-debug alternatives? I'd heard some discussion on a Ruby podcast about a debugger that allowed you to use linux style commands to traverse through an object. Like for example you have a object, with attributes foo and bar, you can actually cd to foo, ls to view it's attributes, cd to another objec...
{ "language": "en", "url": "https://stackoverflow.com/questions/7620926", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Aggregate 3rd dimension of a 3d array for the subscripts of the first dimension I have a 3 Dimensional array Val 4xmx2 dimension. (m can be variable) Val{1} = [1, 280; 2, 281; 3, 282; 4, 283; 5, 285]; Val{2} = [2, 179; 3, 180; 4, 181; 5, 182]; Val{3} = [2, 315; 4, 322; 5, 325]; Val{4} = [1, 95; 3, 97; 4, 99; 5, 101]...
{ "language": "en", "url": "https://stackoverflow.com/questions/7620929", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Eclipse features in Aptana? It seems to me that most of Eclipse's features do not work for me in Aptana. For instance, when editing Java in Eclipse one can press F3 when the cursor is in a class name to jump to the class definition. When editing PHP files in Aptana this does not work. Is it supposed to work, or must...
{ "language": "en", "url": "https://stackoverflow.com/questions/7620931", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Using a scroll in jQueryMobile + PhoneGap I've seen some ScrollView examples on the JqueryMobile website. I tried to dowload the required additional css and js files, reference them, and setup a scrollviewer, but it doesn't work (actually, all my website stops working, showing only a white-empty page). Any idea or a...
{ "language": "en", "url": "https://stackoverflow.com/questions/7620933", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: CUDA-GDB: Setting Up the Debugger Environment I'm following the CUDA-GDB guide (page 10, getting started) on Ubuntu Linux and got this: antonio@antonio-desktop:~$ export PATH=/usr/local/cuda/bin:$PATH antonio@antonio-desktop:~$ export LD_LIBRARY_PATH=/usr/local/cuda/lib64:/usr/local/cuda/ antonio@antonio-desktop:~$ ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7620935", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: calling method in a separate class I have my main class setup and a worker thread, one of my early requests that I make in run() is to call my second class called login. I do this like so: login cLogin = new login(); cLogin.myLogin(); class login looks like this: package timer.test; import android.app.Acti...
{ "language": "en", "url": "https://stackoverflow.com/questions/7620940", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How to get the link from a RSS Feed? I am trying to get the post link of a RSS feed. I load all the posts in an array correctly ( I successfully echo the content and other tags) but I have a problem to get the link. In the feed, the link can be found by two ways 1. <link rel="alternate" type="text/html" href="this ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7620942", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: .htacces rewrite condition not hitting? Lets say I have a two websites www.sample.com and files.sample.com. In an .htaccess file within the webroot of www.sample.com, I have the following: <IfModule mod_rewrite.c> RewriteEngine on RewriteCond %{QUERY_STRING} ^files\/uploads [NC] RewriteRule ^(.*)$ http://file...
{ "language": "en", "url": "https://stackoverflow.com/questions/7620951", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How To Get Google Maps link From Current location? I need to get the google maps link by pressing a button from the iPhone. I already know how to get the coordinate long/lang. Now I need to convert it to a link. I am working with CLLocation & MKMapview Can anyone help me with that? A: Read the "Apple URL Schemes" ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7620952", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Json Returning [object object] instead of array I have json data being fed into a Sencha touch app. Here's the json: http://pastie.org/2622260 - (modified for an example, of course) When I return the "images" and console.log it, it returns the following: images: "[object Object],[object Object],[object Object],[obje...
{ "language": "en", "url": "https://stackoverflow.com/questions/7620953", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: How to resize the Expander.Content? <Grid> <Grid.ColumnDefinitions> <ColumnDefinition Width="*" /> <ColumnDefinition Width="auto"/> </Grid.ColumnDefinitions> <Grid.RowDefinitions> <!-- … --> </Grid.RowDefinitions> <TextBlock Grid.Column="0"> This should be allways ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7620954", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: PHP Simple HTML DOM Parser Dies I am screen scraping page with a bunch of subpages using Simple HTML DOM Parser. For some reason it parses the first 40 subpages just fine but when it comes to number 41 it dies with no error. I have made this test page and tried to log everything I do in my script aswell as some of t...
{ "language": "en", "url": "https://stackoverflow.com/questions/7620955", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: LINQ - The difference between .Select(n => n.Name) and .Select(n => new { n.Name } ); I am completely new to Linq and wondering if you can help me understand the difference between the following Linq? For example... //normal select var contacts = entity.Contacts.Select(n => n.FirstName); //select new var contacts2...
{ "language": "en", "url": "https://stackoverflow.com/questions/7620957", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: Storyboards with bound properties (custom control: animate colour change) To put it simply, I have this within a ControlTemplate.Triggers condition EnterAction: <ColorAnimation To="#fe7" Storyboard.TargetProperty="Background.Color" Duration="00:00:00.1" Storyboard.TargetName="brd"/> But I want the 'to' colour (#fe7...
{ "language": "en", "url": "https://stackoverflow.com/questions/7620958", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: JSON to setAttribute() I've almost got the following working, but have run across many confusing approaches. The desire is using the key:value in the attr{} for the setAttribute() method properties, WITHOUT a framework. Please lend a slim solution: testDiv = document.getElementById("testDiv"); attr = { align:...
{ "language": "en", "url": "https://stackoverflow.com/questions/7620963", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: NHibernate + SQLite issues in .NET 3.5 I'm having a problem working in SharpDevelop using NHibernate and SQLite. I've seen people having my exact problem in Visual Studio 2010 working with .NET 4.0, but I'm working in .NET 3.5 and I've never had these problems earlier. I'm doing some unit testing and whenever I'm tr...
{ "language": "en", "url": "https://stackoverflow.com/questions/7620964", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: JavaScript program, what's wrong? Okay, I don't know where to look. Actually, my interpreter isn't giving me anything back. I'm not getting an alert or anything. var string, output = ""; var counter = number(prompt("Where to start?"); while(; ; counter++){ if(counter < 0){ alert("Error."); break; } ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7620967", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-2" }
Q: How to test against a DOM object in qUnit? I'm testing some JavaScript with qUnit. In one object I pass a DOM element, and some methods will change some properties of the element. How can I mock a DOM object in qUnit? I'd like to use a solution browser independent, as I test also XUL applications. A: You can always...
{ "language": "en", "url": "https://stackoverflow.com/questions/7620971", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "11" }
Q: ActionSheet within UISplitViewController acts different in Portrait Mode than Landscape Mode I created a new application using the Split View-based Application template. I then added an Action Button to the rootViewController navigation controller called actionButton. When the button is pressed, I display an ActionS...
{ "language": "en", "url": "https://stackoverflow.com/questions/7620972", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: Scan list in prolog I want to scan a list in Prolog. In particular, I want to write a predicate scan_list (list), and I want to make it check to see if the current element is a positive integer and if so print it. Thank's. A: If this is homework, be assured that the only way to learn any programming language is to ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7620973", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-2" }
Q: Odd CONCAT Error with Select/Insert Any reason why this will return rows: select users.user_fullname,concat(persons.first_name,' ',persons.last_name) from users, persons where users.user_id = persons.user_id and users.user_fullname = '0' Yet this throws a syntax error? update users set users.user_fullname = concat(...
{ "language": "en", "url": "https://stackoverflow.com/questions/7620975", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: What is wrong my code (trying to abbreviate)? I am using irb/ruby1.9.1. 1st step I wrote the code below: def isUppercase self>= ?A && self<= ?Z end class String def abbreviate abbr = "" each_byte do |c| if c.isUppercase abbr += c.chr end e...
{ "language": "en", "url": "https://stackoverflow.com/questions/7620976", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: My app working on android 2.2 and android 2.3.3 emulators but not on my phone galaxy s android 2.3.5 / Read facebook,twitter contacts? i have a problem with my app , In egypt they are going to add extra digit to mobile numbers to expand , so i made an app to modify the existing numbers to the new one. So basically ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7620977", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: Will Paginate: Limit number of results Im using the will paginate gem for ruby. I am using will paginate to get a bunch of people and sorting on a field. What I want is only the first 100 of those. Essentially the top people. I cant seeem to do this. How would i go about it? Thanks A: As far as my knowledge goes wi...
{ "language": "en", "url": "https://stackoverflow.com/questions/7620978", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: What language(s) are programs like ActiveInbox written in? I want to write something similar to ActiveInbox. In addition to original ActiveInbox, I need to add logic that will perform some actions on the emails that come. What language(s) are programs like ActiveInbox written in? Thank you A: Activeinbox is a bro...
{ "language": "en", "url": "https://stackoverflow.com/questions/7620988", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to insert image between layers in html5 canvas I need to be able to layer image in canvas... how it is possible to insert image between two, or order the image, more like layer in photoshop... on top or below. In fact, i alredy draw many images, i need to be able to inser one between those, or just use a dummy a...
{ "language": "en", "url": "https://stackoverflow.com/questions/7620994", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: jQuery round / circle thermometer possible? Possible Duplicate: Circular progress indicator with jQuery I've been hunting around on the net for hours now trying to find a jquery solution for a round progress meter / thermometer style plugin i need to set a target say 2000 and then pass amount raised such as 100,...
{ "language": "en", "url": "https://stackoverflow.com/questions/7620995", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Trying to receive text via a socket I'm trying to do a simple test off sending data to a socket where the server program then sends data back. I can send the data but don't seem to receive data back. I have checked the server program and I receive the data successfully and used wireshark to watch the traffic and the...
{ "language": "en", "url": "https://stackoverflow.com/questions/7620996", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Struct Alignment with PyOpenCL update: the int4 in my kernel was wrong. I am using pyopencl but am unable to get struct alignment to work correctly. In the code below, which calls the kernel twice, the b value is returned correctly (as 1), but the c value has some "random" value. In other words: I am trying to read...
{ "language": "en", "url": "https://stackoverflow.com/questions/7620999", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Use ajax to call a php method Hi i would like to use ajax in my website where all requests pass are loaded in index.php (i use htacess for rewriting urls) so when i use ajax i always reload the current page and then use if(expressio) to check if the user has called a function with ajax but this cause that all the pa...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621000", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Atom feed basics I want to provide a atom feed. My HttpServlet writes the following stuff (copied from wikipedia): <?xml version="1.0" encoding="utf-8"?><feed xmlns="http://www.w3.org/2005/Atom"><author><name>Autor des Weblogs</name></author><title>Titel des Weblogs</title><id>urn:uuid:60a76c80-d399-11d9-b93C-000393...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621004", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to load a a collection of users\factories? I am using Ruby on Rails 3.1.0, rspec-rails 2 and Factory gems. In order to test a controller index action I would like to load a collection of users\factories. Example (the following code doesn't work): describe "GET index" do let(:users) { 3.times(Factory(:user)) } ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621013", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Triple colon Scala I'm trying to pick up some scala. Reading through examples I came across this impossible-to-google nugget: case 3 => l ::: List(3) What does the triple colon accomplish? A: Concatenates two lists - javadoc A: To add to gkamal's answer, it's important to understand that methods whose names end ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621014", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "61" }
Q: Showing Google Maps Marker infoname on Mouseover of a Dynamically Generated DIV I want to introduce a functionality which allows a marker's infoname to appear or disappear upon mouseover or mouseout of a corresponding DIV element generated from jQuery. However, I am getting a "a is undefined" error on line 19 of mai...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621016", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Use nwalign() with any type of sequence I require an approximate string matching function for Matlab. I found out that the Bioinformatics toolbox has the Needleman–Wunsch algorithm by calling nwalign(). The only problem is that it only works with amino acid sequences. So when I try compare strings with numbers and o...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621017", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Start & Stop PHP Script from Backend Administrative Webpage I'm trying to create a webpage that will allow me to start and stop of a PHP script. The script is part of the backend of a site, and will need to access, read data from, process that data, and update a database on the same server the script exists on. Addi...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621025", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: What's the reason of disappearing of information on project's natures? I'm seeing strange behavior in Eclipse (I'm using INDIGO, Version: 3.7.1, Build id: M20110909-1335). Information on project's natures (Project/Properties/Project Natures) is not always visible. I can't find any pattern when it's visible and when ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621027", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Partial database recovery on Heroku Thankfully this is a hypothetical, planning-ahead sort of a question. Can you restore part of a database using Heroku's backup addon, or otherwise? So, for instance, only restore records in all tables which have a client_id of 5? A: No, that does not appear to be a feature inclu...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621031", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Algorithm to output the initials of a name I have just started the java programming and at the moment I am doing the basic things. I came across a problem that I can't solve and didn't found any answers around so I thought you might give me a hand. I want to write a program to prompt the user to enter their full nam...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621034", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-1" }
Q: WebSockets with node.js I'm trying an example of WebSocket to develop a simple chat. server.js: var app = require('http').createServer(handler) , io = require('socket.io').listen(app) , fs = require('fs') app.listen(8080); function handler (req, res) { fs.readFile(__dirname + '/test.html', function (err, dat...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621035", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How could I detect if a character close to another character on a QWERTY keyboard? I'm developing a spam detection system and have been alerted to find that it can't detect strings like this - "asdfsdf". My solution to this involves detecting if the previous keys were near the other keys on the keyboard. I am not ge...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621043", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: jScrollPane Trouble I have used jScrollPane on my site. I'm also using ajax to update the data on the same div where the jScrollPane is used. Now, when i append the returned data to the div, the scrollbar is not visible on the appended text. It may because the jQuery function is called when the document loads but no...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621048", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Better way to write this Regex? Negative Lookahead I think I've got this working for the most part, but was wondering if there is a better way to write it: /\b(Word)(?!.*?<\/a>)(?!.*?>)\b/ I'm trying to match Word when it's NOT linked, and it's NOT part of HTML tags (like <a href="" title="Word"> should not match)....
{ "language": "en", "url": "https://stackoverflow.com/questions/7621053", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Regex to add a space after each comma in Javascript I have a string that is made up of a list of numbers, seperated by commas. How would I add a space after each comma using Regex? A: Use String.replace with a regexp. > var input = '1,2,3,4,5', output = input.replace(/(\d+,)/g, '$1 '); > output "1, 2, 3, 4, ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621066", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "25" }
Q: How to paste xml to C++ (Tinyxml) I'm currently working on a project in C++ where I need to read some things from a xml file, I've figured out that tinyxml seams to be the way to go, but I still don't know exactly how to do. Also my xml file is a little tricky, because it looks a little different for every user tha...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621067", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: AjaxControlToolkit requires ASP.NET Ajax 4.0 scripts AjaxControlToolkit requires ASP.NET Ajax 4.0 scripts. Ensure the correct version of the scripts are referenced. If you are using an ASP.NET ScriptManager, switch to the ToolkitScriptManager in AjaxControlToolkit.dll. Izvorna datoteka: http://dostavahrane.si/Script...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621072", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Indexing and searching a MS excel using Lucene 3.1 I have a MS Excel sheet, with following columns title,cast,director,genre. The Excel sheet is parsed using jxl library. The indexing is working properly, but when I search I always get 0 hits found.I don't know where I am going wrong. The code is below : import ja...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621073", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Error signing user in with Umbraco Membership After setting the auth ticket from a successful login with the umbraco membership provider, the Page.User.Identity.IsAuthenticated remains false. if (Membership.ValidateUser(uname, pwd)) { FormsAuthentication.SetAuthCookie(uname, true); } Config: <add name="Umbr...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621075", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: difference between SDO and JDO in java what is the difference between JDO (JSR 243) and SDO (JSR 235) in Java; what set of open source providers are available for these java specifications A: From this article: [...] JDO looks at the persistence issue only [...] whereas SDO is more general and represents data th...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621077", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: C# return type of function What does GetNode return, a copy or a reference to the real value? public GraphNode GetNode(int idx) { return Nodes[idx]; } In other words will this code change the real value or it will change a copy returned from GetNode? GetNode(someIndex).ExtraInfo = something; Thanks A: Dependi...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621083", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Getting 'index 0 beyond bounds for empty array' error on non-empty array I have this code to add a row to a table view in the root view controller of my application: NSIndexPath *indexPath = [NSIndexPath indexPathForRow:0 inSection:0]; NSArray *myArray = [NSArray arrayWithObject:indexPath]; NSLog(@"count:%d", [myA...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621085", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: synchronization of several remote git repositories We have: * *Remote repository with some project. *Several remote repositories, which I want to synchronize with previous one. When something pushed in first project (1), I need to pull these changes to other remote repositories (2). I can pull from first repo ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621086", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: MSVCRT: Where is the implement (source code) of sin, cos et al? I wonder where the implemention of basic trigonometric functions can be found in the Visual C++ CRT. Find in files for "sin" in C:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\crt shows the definition in math.h but nothing more (except a mention i...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621089", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: Web development for a user profile enabled website I am developing a website that will contain user profiles with significant amount of their data. Beyond the general user profile information, I will also need to store their settings, interaction history with other users, and actions they've taken on my website(i.e....
{ "language": "en", "url": "https://stackoverflow.com/questions/7621094", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Jquery change div background inside tr I have been trying to get this to work for quite some time now. I am looking for a way to change the background of a div inside a tr onclick with jquery. What I mean by this is that when the tr (which is named by class) is clicked, then the div with a class name (that is inside...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621096", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: facebook "like box" for page I set up my website's facebook account as a Page on my facebook account (this was probably incorrect, but I didn't know better at the time). I have switched my account to Use Facebook as a Page. I am trying to create a like box with avatars for my website (www.zealforadeal.com). I get t...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621099", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: TableView Sliding in Code How can I make the tableview to stop sliding initially? But it should slide when keyboard is visible. I have written code for keyboarddidshow and hide methods, but it doesn't work if I deselect enable sliding option in IB. A: you can set the propery of setcontentOffset to the table A: i u...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621101", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-2" }
Q: easy_install downloading directory I'm trying to install a python script packaged in egg format using easy_install. The problem is that easy_install downloads dependencies to /tmp. However, my tmp dir only has 4mb of free space (I am working with a NAS drive, set up this way). Is there a way of specifying the down...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621103", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Adapters not working with datamapper I have the following code: require 'sinatra' require 'datamapper' DataMapper.setup :default, "postgres://localhost/mydb" However, when I try and run it, I get: LoadError: no such file to load -- dm-postgres-adapter /Library/Ruby/Site/1.8/rubygems/custom_require.rb:53:in `gem_o...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621106", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: PHP: Cookie not unsetting <? if($_POST["Login"]) { if (GetRightPassword($_POST["emaillogin"],$_POST["passwordlogin"])) { $_SESSION["email"] = $_POST["emaillogin"]; $_SESSION["password"] = $_POST["passwordlogin"]; echo "Keeping logged in: ".$_POST["keeploggedin"]; if ($_POST["k...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621115", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: CoffeeScript + KnockoutJS Function Binding I'm using CoffeeScript and KnockoutJS and have a problem getting the values of my view model from within a function. I have a view model: window.Application || = {} class Application.ViewModel thisRef = this searchTerm: ko.observable("") search: -> aler...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621116", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Jump to line in vim with relativenumber on In a normal situation it's possible to look at the line number and use [number]G to goto that line. But I like to work with the setting relativenumber on. The disadvantage is that I can't jump to lines anymore by looking at the displayed line number. Is it possible to rede...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621117", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "31" }
Q: Play splash movie every time app launch (with multi-task support) the app I'm working on supports iOS multi-task feature by default, and I want to stick with this. Upon app launch, a splash movie clip is played (code is in AppDelegate), after user hits the home button, and re-launches the app, I want to the same sp...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621130", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to get the functions (adresses) from a .DLL (Windows) to call them from Masm32 Im writing a Compiler for a Pascal-like language which converts the program in Masm32 (and then to a .exe). My goal is to let the coder include Windows Libraries (.DLL). So I need to read out the functionnames and the jump adresses fi...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621134", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Single page design using Orchard CMS I have a client who want's a single page design for his site where the content for each "page" is shown/hidden using javascript as the user navigates the site. I'm not sure on the best way to approach this using Orchard. One option would be to have the content all on a single pa...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621135", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: Can't add an IntPtr and an Int I have this lines in C# Visual Studio 2010: IntPtr a = new IntPtr(10); IntPtr b = a + 10; And it says: Operator '+' cannot be applied to operands of type 'System.IntPtr' and 'int'. MSDN says that this operation should work. A: If you are targetting .net 4 then your code will work....
{ "language": "en", "url": "https://stackoverflow.com/questions/7621140", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "9" }
Q: Incorporate PHP Into HTML Form I wonder whether someone may be able to help me please. I'm trying to put together functionality which allows an administrator to search for user details in a mySQL database using the email address as the search criteria. Once the search has taken place I would like the 'first' and 'su...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621141", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Google API - Static Maps Frankly, I'm not sure what I'm doing wrong. This is my code, but for some reason, the map is outputting a blank iFrame with a source URL that if I click will send me to the proper map, so the URL is being input correctly, but it's not actually being displayed on my website. <?php $addressSt...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621146", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Auto deletion from memory after indexing with solr because of lack memory i want to force solr to write the index into hard space and does not keep the file opened in memory,How can i do that in solrj? i add the solr.commit() after each document indexed but it does not work A: Few pointers :- To immediately commit ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621153", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to create a shortcut which copy line where cursor on Possible Duplicate: Eclipse copy/paste entire line keyboard shortcut I want to create an eclipse shortcut. Wherever line cursor on (without selection) when pressed Ctrl+C, eclipse will copy the whole line to clipboard. Is this possible? A: Key bindings ca...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621157", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Getting User's name from table when they login with e-mail The user table is setup as: ID | Name | Email | Password and they login with: Email | Password I'm wondering how I can display their 'Name' when they login with their e-mail. What I have so far that works with email is: session_start(); if (!isset($_SESS...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621159", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to dynamically set variable value with C#? For example, PHP code: $test = "hello"; ${$test} = $test; echo $hello; // return hello How to do this in C#? Thanks in advance. UPD: Dynamic variable in C#? - here is an answer. A: This isn't supported in C#. You could use an ExpandoObject and set a member on it, but...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621169", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How can you solve equations in PHP? I'm looking for a generalized equation solver in PHP. This could either be in the form of in-built functionality, a library, or even integration with another language if it comes to it. I am even comfortable with a joint solution that involves some combination of the above. I n...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621171", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: Exiting for-loop in c++ I have at least 2 problems with the code but I will start with this one. The following code does not seem to work correctly: cout<<"Vill du mata in en post till? (ja/nej)"<<endl; //I'm asking if the user wants to run the for-loop one more time or brake with ja(yes) or nej(no). cin>>svar; if ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621175", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-1" }
Q: Real Time Image Processing in Android using the NDK Using an Android (2.3.3) phone, I can use the camera to retrieve a preview with the onPreviewFrame(byte[] data, Camera camera) method to get the YUV image. For some image processing, I need to convert this data to an RGB image and show it on the device. Using the b...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621178", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Django form multiple select box size in template I have a template: ... <form action="/reportform/" method="post"> <p><label>Aircraft system:</label> <br>{{ Querry.system }} ... it looks like this How can I set a Size option for this box? for example, 10. A: Use the attrs attribute to define th...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621184", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: RewriteRule & Header set Expires : how to I'm using rewrite rules to create a /fr /en on my website and does folder don't exist, therefore if I try to use <Directory /fr> ExpiresDefault "access plus 1 day" </Directory> Apache complain because the folder does not exist, can't find a way to do it in the http.conf If...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621185", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Vertical Scroll Content within DIvs - Reload to top I'm using the simplest HTML 'overflow: scroll' type mark-up for creating a scroll bar within multiple div containers to display text and image content within the scroll. I have it setup within tabbed content areas, that are pulled together calling divs within the t...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621196", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: lockfile purpose in init.d daemon scripts (linux) When looking at various daemon scripts in /etc/init.d/, I can't seem to understand the purpose of the 'lockfile' variable. It seems like the 'lockfile' variable is not being checked before starting the daemon. For example, some code from /etc/init.d/ntpd: prog=ntpd l...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621203", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Sort NULL values to the end of a table Is there a way with PostgreSQL to sort rows with NULL values in fields to the end of the selected table? Like: SELECT * FROM table ORDER BY somevalue, PUT_NULL_TO_END A: Does this make the trick? ORDER BY somevalue DESC NULLS LAST Taken from: http://www.postgresql.org/docs/9...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621205", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "125" }
Q: Problematic make file for java JFLAGS = -d bin -cp lib/slick.jar:lib/lwjgl.jar JC = javac .SUFFIXES: .java .class .java.class: $(JC) $(JFLAGS) src/$*.java CLASSES = \ Game.java \ Block.java \ BlockMap.java \ default: classes classes: $(CLASSES:.java=.class) clean: $(RM) bin/*.cla...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621208", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How should platformer game's solid objects be implemented efficiently? I have been trying to write a platformer engine for a few times now. The thing is I am not quite satisfied with my implementation details on solid objects. (wall, floor, ceiling) I have several scenario I would like to discuss. For a simple platf...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621211", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Getting variables by scope Is it possible for a function in C++ to find the addresses of all variables in a certain scope? I'm talking about methods such as scanning the memory used by the program, or looking at a compiler's parse tree. Maybe there's even a mechanism added for it in C++11. This is something I've bee...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621212", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Java Regex Understanding I need help to understand regex. For some reason, i'v read lots of tutorials and lots of questions here on sof, and cannot manage to understand it. I want to use String.split function like in here: Java string.split - by multiple character delimiter. But i cant understand this part: String[]...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621214", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: json_decode variables php I'm simply trying to extract variables from a json_decode the resulting decoded code (a snippet of) is: auth_info: array(4) { ["profile"]=> array(13) { ["name"]=> array(3) { ["givenName"]=> string(6) "John" ["familyName"]=> string(7) "Doe" ["formatted"]=> string(14) "John ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621218", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: jQuery .css('right') not working I am making a simple game in jQuery. I am having trouble turning the spider image to north east. I have it working fine with north west but for some reason north east does not seem to be working. Here is my init code: // JavaScript Document function init(){ angel = $('<img class...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621223", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Delphi inline assembler pointer to structure Hi people is there a way i can access a pointer to a structure member directly from in line assembler i tried this procedure test(eu:PImageDosHeader);assembler; asm push eu._lfanew end; It won't compile but if i use this procedure test(eu:Pointer); var xx:TImage...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621224", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: Font not well rendered with freetype and Opengl ES 2 (IPhone device) I'm using freetype for writing text in an IPhone device, the result are rare. As you can see in the image same characters(like 'b', 'n' or 'u') aren't rendered equally. The texture is always the same. Any idea where is the problem or what's going ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621227", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Is drawrect more efficient for coregraphcs drawing than using core graphics in touches moved? My whole app uses touchesMoved for drawing (Coregraphics). Should I be calling [self setNeedsDisplay] from within touchesMoved instead of performing the drawing code in there? Would that stop some lag that I am experiencing...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621229", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Check if my app has permissions to read process info and read/write to files and directories How to check in my C# application if I have Permissions to get process list, kill processes, get directories, get files in directories, read and write files and etc? Thanks! A: If your has permission can do the operation wi...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621230", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How can i call a richfaces component from xhtml page I am including jasper report's exported xhtml to a jsf page. I want to put some export option to jasper report template and when user viewing report on browser if he click this option(pdf image) i want to pop up a pane and get export options (page ranges) and ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621234", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Is there a C++ allocator that prevent an STL container from being swapped? Has anyone seen an allocator that calls mlock(2) to prevent an STL container's contents from being swapped to disk? There is afaik only one tricky part to writing such an allocator, namely minimizing the number of mlocked pages by clustering...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621243", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: Wait for file to be unlocked - Windows I'm writing a TFTP server program for university, which needs exclusive access to the files it opens for reading. Thus it can be configured that if a file is locked by another process that it waits for the file to become unlocked. Is there any way on Win32 to wait for a file be...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621248", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: opening files from a website I asked a similar question yesterday but I included some code that basically took my question on a different tangent than I had intended. So I shall try again. I am rewriting a python script that crawls a website to find a few hundred text files, I have no interest in any content of the...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621249", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Symfony2 file and directory convention Am learning Symfony2 framework. the structure of files and directories make me very annoyed. It make me really hard to follow things ej: routing_dev.yml //use underscore AppCache.php // use camel case there is no unique convention. Can anyone tell me when to use camel cas...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621250", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to make a resizable JDialog? I'm using JOptionPane.showOptionDialog to show a JDialog. I would like to know how: * *set the dimension of the dialog (for now I'm using setPreferredSize() method on the given panel but I know that such method shouldn't be used). *make the showed dialog resizable. My code look...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621255", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Hadoop 0.20.2 reducer throws ArrayIndexOutOfBoundsException when iterating values I am fairly new to hadoop, however, I've been reading "Hadoop: The definitive guide", so I think I have an understanding of the basic concepts. I used Hadoop 0.20.2 to run a fairly simple job, but I get the following exception: java.la...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621257", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Solution for Visual Studio shows message "Error while trying tu run project:" after un signing assemblies? a couple of days ago I signed my assemblies to test ClickOnce deployment. All worked fine until I cannot deserialize my old binary-serialized-files, so I had to revert the code-signing of the assemblies. That's...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621258", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Move an image across a web page How can I move an image element across a page? As an example, Vimeo does this with an image of a cloud: http://www.vimeo.com/log_in A: They're just changing the position with JavaScript. You can do this yourself easily with jQuery .animate(). A: Place an absolutely-positioned image ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621259", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: protecting C++ code in program I realize this must be a somewhat naive question, but I have written C++ program for a client. He needs the program installed on his machine, but I don't want to give him the code obviously. How can I protect the code so he doesn't have access to the source code? any suggestions to hel...
{ "language": "en", "url": "https://stackoverflow.com/questions/7621263", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }