text stringlengths 8 267k | meta dict |
|---|---|
Q: Create java native method for constructor I am writing a program in Java and I would like to create a native interface for a library written in C++. But I am confused with how to write a native method declaration for a constructor.
Say I have this C++ class and constructor:
template <class _Tp,class _Val>
class A... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616791",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "10"
} |
Q: groovy.lang.MissingMethodException Hi I am trying to invoke a url using JQUery with parameters appended to it. The values of the parameters are from the text fields in the dialog box on the page. When I invoke the url with no values filled in the parameter (i.e url inside if) it execute fine, but when I enter value... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616793",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: sample() with list Is is possible to sample a single column at random from a list that looks similar to below.
list(combinations(4,3,1:4),combinations(4,2,1:4))
[[1]]
[,1] [,2] [,3]
[1,] 1 2 3
[2,] 1 2 4
[3,] 1 3 4
[4,] 2 3 4
[[2]]
[,1] [,2]
[1,] 1 2
[2,] 1 3... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616794",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Rails 3.1 and Stylesheet Frameworks I am building an application in Rails 3.1 and I really like the whole SASS feature.
I looked at Compass recently and did also come across some debate discussing the need to use compass anymore in Rails 3.1. Frankly, the things that attracted me to compass were the ready made mixin... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616796",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: ElementTree's iter() equivalent in Python2.6 I have this code with ElementTree that works well with Python 2.7.
I needed to get all the nodes with the name "A" under "X/Y" node.
from xml.etree.ElementTree import ElementTree
verboseNode = topNode.find("X/Y")
nodes = list(verboseNode.iter("A"))
However, when I trie... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616800",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "16"
} |
Q: Invalid Uri: The Uri scheme is not valid I am trying to make a connection via HttpWebRequest. I am reading url links from a text file.
However, I am getting 'System.UriFormatException' error.
I have tried to add http:// in front of the url links in my text file. But the result is the same.
What can be the solutio... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616803",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "4"
} |
Q: How can I refactoring test code for both JavaScript and HTML requests\responses? I am using Ruby on Rails 3.1.0 and the rspec-rails 2gem. Since I have to test both HTML and JavaScript requests for the same controller action and since sometime those responds by rendering different view files or behaving differently, ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616804",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Amazon S3 upload with public permissions I'm using the Amazon C# SDK and trying to upload a file, but by default it has restricted permissions. I would like to make it publicly available, but I can't seem to find out how to do it as part of the upload.
My bucket is public, but when I upload a new file using the c... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616810",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "31"
} |
Q: Getting SIGILL when trying to execute buffer overflow attack I'm working on my buffer overflow project for my security class, I think I have everything set up right but when I run it I get:
Program received signal SIGILL, Illegal Instruction.
0x08048500 in main(argc=4854718, argv=0x0804b008) at stack.c:22
22 f... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616813",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "5"
} |
Q: ExtJS 4: JSONRPC 2.0 as store protocol? I would like to implement a graphical user interface on the basis of ExtJS version 4. The web service I want to use provides data as result sets of jsonrpc-2.0 calls.
I cannot find anything in the docs on how to do this. Do I use AJAX proxy? If so, how do I generate the prope... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616815",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: Getting text from a form and evaluate in selenium using ruby I am testing a registration form and one of the questions before submitting is:
"What is 8 + 4?"
The values will be different every time. I am using Selenium 2 with Ruby and want to to see if anyone knows how to a) get the text from the question and then b... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616819",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Is it possible to read SharedPreferences held by another application? I am trying to read the value of the Android Contacts application setting used to display contacts with phone numbers only. (Accessible from the contact list, menu -> display settings, "only contacts with phone number").
According to the source c... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616821",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Monotouch mtouch arguments problems Having trouble getting these two arguments to play nice when compiling a project. Any help would be much appreciated.
-gcc_flags "-L${ProjectDir} -lflite -all_load" -nosymbolstrip -nostrip -cxx -gcc_flags " -lgcc_eh -L${ProjectDir} -ltestflight -ObjC"
flite is a native C library,... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616823",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Can you add ActionScript or other code to an flv I'm curious if it's possible for an flv file to contain code like ActionScript or if it can only contain the audio/video data for the video.
I'm specifically asking related to the security of allowing an FLV file to be uploaded a site.
Edit: assume that the contents h... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616827",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: flush during runtime: I've got a php script running constantly, during which I'm looking at a webpage with the logs. Is there any way to automatically scroll to the last entry when flushing?
My flush function (only way I could make it work):
function flush2 (){
echo(str_repeat(' ',256));
if (ob_get_length())... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616834",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Sample in Standing Wave 3 Actionscript Library I am trying to get my head around StandingWave 3. I can create IAudioSources and play them but I am trying to figure out how to use the Sample part.
I tried mixing an IAudioSource into a Sample by Sample.mixIn().
testSample.mixIn(mp1.getSample(mp1.frameCount));
player.... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616837",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: How to save a mix of strings and numbers into text files in specified format using numpy.savetxt? with one array of strings and the other array of numbers, like
str_arr = np.array(['object1_short', 'object2_intermidiate', 'object3_long'])
and
flt_arr = np.array([10.01234235, 11.01234235, 12.023432])
How can I spec... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616838",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: class hierarchy design - order of classes What is the best way to order a a group of classes. I've already made the decision to put them in one file. An opcode caching application well ensure efficiency.
Is alphabetical O.K? Does it matter? Here is the list.
/*CLASS LIST*/
/*bookmark*/
/*database*/
/*impor... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616839",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Label Html helper is show up as string literal contents instead of being rendered Q: How do I get this to render as a ? It' showing up as string literal text instead of being renderd into an actual element.
public static class HtmlExtensions
{
public static string LabelX(this HtmlHelper htmlHelper,
... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616842",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Images from my stylesheet will not load I currently using WAMP Server 2.1 on both my own computer and on my girlfriends laptop. I synchronizing my files through Dropbox and I link some images (the logotype, background-image, etc.) via my stylesheet to my personal website.
The images is visible on my own computer but... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616843",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Framework for Browser toolbar Is there a framework I can use to make cross-browser toolbar?
To make my self more clear : I want something like this but for browsers
http://www.phonegap.com/
As you can see , it uses a common technology (HTML+CSS+JS) to make cross-platform mobile apps.
A: Try this: http://kangoextens... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616844",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: ajax loading flash swf coming out empty im loading soundcloud embedded players in via jquery .load()
in IE whenever an swf is in it the load freezes and becomes incomplete.
if there isnt one the query works fine. it also works fine on chrome, Firefox and Safari.
function ajaxLoad(id){
var url = "http://www.kons... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616847",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: getting error after ugrading to sass-3.1.8 after upgrading to sass-3.1.8 form sass-3.1.7 I get this error:
Functions may only be defined at the root of a document.
any Idea how I can solve this?
I'm using some of bourbon's mixins and it's imported at the top of my stylesheets, that's all.
A: I have the same prob... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616850",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "6"
} |
Q: Is it possible to generate a constant sound in C# while adjusting its frequency? Is it possible to generate a constant sound in C# and manipulate its frequency as it goes?
I tried something like this:
for (int i = 500; i < 15000; i += 1)
{
Console.Beep(i, 500));
}
But being synchronous, the loop waits for each ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616852",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "8"
} |
Q: how to write this 404 rule in .htaccess I have a custom CMS. It works very well except for one thing. I am wondering how best to implement 404 functionality. The site should only have the following url types
index.php?upn=something
or
gallery.php?groupId=2
Any directories that are appended to the url after index.... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616856",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "3"
} |
Q: How do I insert a PHP code within another PHP code? I'm using WordPress. I appreciate being shown the code, but this is one I am interested in straight out learning how to do myself too - so if you know where I can find a tutorial or can give me information I'd appreciate it!
I'm calling posts and want to include a... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616857",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: SQL How To Group by Date Ranges Can someone help me figure out to group by a range of dates??
Right now I have query similar to this
Select date, count(x)
from data
group by date
This returns results that look like this
2011/1/1 10
2011/1/2 5
2011/1/3 8
2011/1/4 3
etc...
But I w... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616860",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "4"
} |
Q: How to draw variable-width UIBezierPath? I'm wondering how I should go about drawing a uibezierpath where the stroke width peaks at the center of the arc. Here's an example of what I mean:
Either I have to go through each point when drawing, and set the stroke width accordingly, or there's an easier way. Can anyon... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616861",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "4"
} |
Q: Google search preview style jQuery plugin I'm looking for a jQuery plugin which is similar than the new Google search page preview.
A: A quick search came up with these, I don't have any experience with any of them though..
http://cssglobe.com/post/1695/easiest-tooltip-and-image-preview-using-jquery
http://craigswo... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616862",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Div tag an JQuery UI I am working on a widget control. The widget is loaded dynamically into a widget container. The widget container contains a div which holds the widget, this is known as the widget area. The widget container is made to be draggable and resizable using JQuery UI.
The problem I am having is that t... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616864",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: SQL Server CE Enterprise Library 5 Cannot pass parameters I have an SQL CE(.sdf) database which I am trying to access from MVC3 application using MS Enterprise Library 5.0. I have referenced the SQLCE dll for Compact Edition 4.0.
I use the following code to execute a simple Select using Enterprise Library
> SqlCeD... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616865",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: how to test a string for letters only how could I test a string against only valid characters like letters a-z?...
string name;
cout << "Enter your name"
cin >> name;
string letters = "qwertyuiopasdfghjklzxcvbnm";
string::iterator it;
for(it = name.begin(); it = name.end(); it++)
{
size_t found = letters.find(... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616867",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "21"
} |
Q: Mergesort C++ Windows Form Application I am at work on a gui based mergesort application. I am trying to print the steps as the recursive mergesort moves along. I am having trouble with accessing the "richTextBox1" component within my mergesort/print_arr() so I can print the current array out to the window. I am get... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616873",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: why read-only access is writing to my db, in GORM? In my app, I have a code like this:
// 1
Foo.get(123).example = "my example" // as expected, don't change value in db
// 2
Foo.get(123).bars.each { bar ->
bar.value *= -1 // it's changing "value" field in database!! WHY?
}
*
*note: Foo and Bar are tables in... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616874",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: JQuery equivalent in prototype What is the form.serialize equivalent in JQuery if there is one?
$('person-example').serialize()
// -> 'username=sulien&age=22&hobbies=coding&hobbies=hiking'
$('person-example').serialize(true)
// -> {username: 'sulien', age: '22', hobbies: ['coding', 'hiking']}
A: It's the same, ho... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616876",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: How to define a CoffeeScript class that loads jQuery on first instantiation, then just fires a callback thereafter? I'm still pretty new to classical OOP using JavaScript; this seems like a general OOP question, but ideally I'm looking for an actual code example using CoffeeScript to help me learn.
I want to define ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616880",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: newbie want to create an animation to my website I'm writing a private website.
I want to add an animation of a paper (which moves a bit in its conrners).
I paln the user to add some text in the text area in that animated paper.
My program will read the text and save it.
The next time the user comes I'll show him th... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616882",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Lightweight inference engine interfaceable with Ruby I have a large Ruby application that is just crying out for the addition of an inference engine; I don't need a lot of functionality, am not afraid of integrating C libraries, and am coming up empty in my Googling.
There seem to be plenty of rules engines in Pyt... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616885",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "5"
} |
Q: Java Compiler API NullPointerException I am using this code to compile a Java file at runtime. First of all, here is my directory tree (in Eclipse).
+---- src
+----- package
+------ Compile.java
+
+
+---- temp
+----- anotherpackage
+------ Temp.java (file to compile)
Here is my code where I am getting the NullPoint... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616886",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: gprof command is not creating proper out.txt First of all I'm running MacOSX 10.7.1. I've installed all properly, Xcode 4 and all the libraries, to work with C lenguage.
I'm having troubles running gprof command in shell. I'll explain step by step what I'm doing and the output I'm receiving.
Step 1:
~ roger$ cd Path... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616890",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "6"
} |
Q: Items sql table I am building a textbased game, and I have problem of how to build/structur my SQL table for items.
Item can be anything from weapon, a fruit, armor, etc. But I'm not sure how to properly design this.
For example
Iron Sword Str +4 Health +3
(Or something like that)
But if its a fruit item
Fruit of ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616901",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Haskell "pseudo-functor" I have a polynomial
data Poly a = Poly [a]
I would like to be able to do something like fmap (take 3) polynomial but I can't since Poly isn't really a functor in that the f I use in fmap can only be of type [a] -> [b], not a -> b.
Is there an idiom or way I can express what I want?
EDIT: ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616904",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "5"
} |
Q: Android persistent HttpClient connection Would it be possible to setup an HttpClient such that on a website that updates periodically, perhaps due to AJAX, the resulting changes would be captured by the HttpClient. Similar to keeping a connection to a website alive, and if there were an update, the HttpClient would ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616910",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: What's the best way to sort class definitions in a python source file? I have a .py source with many class definitions, like so:
class C:
# code c
class A:
# code a
class B:
# code b
I want to turn it into:
class A:
# code a
class B:
# code b
class C:
# code c
Is there a tool for this? ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616911",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "4"
} |
Q: .htaccess and url rewriting challenge My problem is very simple.
I have several folders in my root:
[folder1]
[folder2]
[folder3]
And my domain is something like: http://johndoe.net
I keep my website in [folder1], so basically I access it by typing http://johndoe.net/folder1
My goal is this:
I want to type http://j... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616912",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: MYsql use same field as joined table I have site i need to modify without changing anything and only way i can do it is by adding mytable which has status field.
Now i have request like
if...{
$filter = "status = 0";
}
SELECT first_name, last_name, position, wage
FROM table1, mytable
WHERE table1.id = mytable... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616921",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Setting a Constant Size for a Pie Chart with External Labels All,
Hopefully the title should say it all. We're switching from the System.Web.Helpers to the System.Web.UI.DataVisualization charting controls because there's simply not enough options available in the former. Using some code "borrowed" from Simon Stee... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616926",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Optimal Binary Search Trees I have an assignment on optimal binary search trees and some questions came up while doing it. I have found many of the links online helpful (just from a Google search) but I was wondering...
Why must the keys must be initially sorted?
If I get a lower cost (for an optimal BST) when the k... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616931",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: Writing firefox extension: How to export private key from certificate database? Possible? I am writing a Firefox extension and am looking for a way to export the private key from an installed certificate.
This would be replacing the previous process of saving a backup PKCS12 .p12 file, then running using: "openssl p... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616934",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: what is the use of ()=> in silverllight Can you say what is the use of the ()=> and =>? I saw this in a code. I did not get any reference for this.
this.Dispatcher.BeginInvoke(()=>
{
//some thing..
};
A: => is the lambda operator in C# and is read as "goes to". A lambda expression is an anonymous function and ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616936",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "3"
} |
Q: HTTP 1.1 20 second delay compared to HTTP 1.0 I've written a program in C that sends a HTTP 1.1 POST request to a web server.
Well monitoring it with wireshark, takes less then a second for the server to respond and to get the HTTP/1.1 200 OK message, but then it takes another 20 seconds to get the FIN, ACK packet, ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616938",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "4"
} |
Q: Making an UILabel appear in another view once pressed in one view I have 2 views
*
*SoundViewController
*ShowViewController
The sound view has a sound on it (IBAction).
- (IBAction)oneSound:(id)sender; {
if (oneAudio && oneAudio.playing) {
[oneAudio stop];
[oneAudio release];
oneAud... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616948",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Cloning a mercurial repository, .hgsub refers to a dead external subrepo We're trying to clone a Mercurial repository A where it references a subrepository B that's moved hosts. We'd like to update .hgsub in A to point to the new location of B, but it's a chicken and egg problem if we can't hg clone A in the first ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616950",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "7"
} |
Q: Good way to store data that will be converted to PHP arrays? Can someone recommend a file format/dtd/programming language that is not too finnicky/verbose when it comes to syntax and would be appropriate for storing hierarchical data? I intend to convert the data into a PHP associative array for use during run tim... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616952",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: deprecation warning in Rails I'm a newbie to Rails and programming in general (currently learning from a book that's using 3.0.1 and ruby 1.9.2).
When I did the rake db:migrate command I got the following deprecation warning. I'm not sure if this is because I'm using a slightly older version of Rails, or if it would... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616953",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: How can I open a menu from the root window using PyGTK? I want to open a menu without a window, bar, status icon, etc, only on the root window, like the menu of openbox or something like this http://img404.imageshack.us/img404/7189/2010120112912208781680xx.png, that is a menu made it with pygtk but he never made it ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616961",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: MFC: How to get default button of child dialog to work? I have a child dialog which I created as a new dialog in the resource editor. Then I used a static control on the parent dialog to act as a placeholder. The child control is displayed where the place holder is using the following code:
CRect rect;
m_optionPan... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616962",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Making the List object compatible with post data from frontend in ASP.NET MVC3 I have the following controller that I am posting to in a form via AJAX:
[HttpPost]
public ActionResult Create(List<int> listOfSTuff)
{
try
{
service.Create(listOfSTuff);
}
catch
{
return null;
}
... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616964",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: Facebook App Domain disappears I've added a comment box to my site. I'm using an app_id. I've added my domain to "App Domain" in the settings section for the app. I save it. I then come back and the "App Domain" has disappeared. It's like it's not being saved.
What am I doing wrong?
A: I found how to do this - the... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616965",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "18"
} |
Q: Center Text Vertically Within I have a <div> element with a fixed height, and I'd like to center some text vertically within that element.
I've been trying to follow the instructions at http://phrogz.net/css/vertical-align/index.html. However, it doesn't seem to work for me.
I've posted what I'm trying at http://js... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616969",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "51"
} |
Q: Simple random query from database I currently have an ads listing site on which there are 3 ordering filters. By default, the ads are sorted with the following line:
$this->setState('filter_order', $app->getUserStateFromRequest('com_adsman.filter_order','filter_order', "start_date"));
When I change the start_da... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616972",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: how to check internal and external storage if exist How do i know if there are internal and external storage in android pragmatically? does anyone how to know how to check both internal and external storage
thanks in advance
A: it's already explained in android documentation.
Code taken from documentation
boolean m... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616974",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "41"
} |
Q: How to run code when you receive an email I'm making a mobile product for a social network and one of the features we would like to add is text-to-status. We are doing something different though, similar to YouTube's mobile upload. YouTube uses emails such as:
12598601913@m.youtube.com
I would like to something si... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616976",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: Need html checkbox label to wrap "nicely" I have a grid of checkboxes where each cell has a fixed width, and each checkbox is preceded with a small image. In cases where the label text is too long, I'm having a hard time getting the text to wrap underneath the checkbox.
Referring to the above screenshot, I'd like ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616977",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "4"
} |
Q: data loss when using ajax loader image I have problem with ajax loader image when I use the load() function, the following javascript code works fine:
$('#myscroll').load('data.php','total='+totalItems+'&id='+ID+'&worker=$worker&sets=$sets', function(newi){
updatestatus();
});
In the data.php, it receives the $... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616978",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: jboss jndi context is empty An ejb-jar deployed to jboss 7 has a jdni binding "java:global/foo!IFoo".
Jboss management console shows this binding.
The jndi port is 1099 as by default.
A client on jboss gets an object to that binding but a standalone client running on the same machine does not.
Properties properties... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616981",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: HTML 5 geolocation using phoneGap I have created a script that will show the user's location using the geolocation library and it all works fine. I have exported this HTML 5 script using PhoneGap and can see that in Settings->Location Services My App is set to On. So I assumed every time I run My App I would not get... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616982",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "6"
} |
Q: Send server message to connected clients with Signalr/PersistentConnection I´m using SignalR/PersistentConnection, not the Hub.
I want to send a message from the server to client. I have the client id to send it, but how can I send a message from server to the client?
Like, when some event happens on server, we want... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616983",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "4"
} |
Q: pil png activestate on windows 7 ZLIB (PNG/ZIP) support not available I'm trying to port a python program from OS X to Windows 7.
This program processes a png with tkinter
eg
self.logoImg = ImageTk.PhotoImage(Image.open('GrowthPathLogo.png'))
The code is failing with
IOError: decoder zip not available
I've tried i... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616987",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: Efficient way to find combinations of Strings in pair of two if String is an Array This is what I have so far.
package testproject;
public class Combinations{
public Combinations(){
String str_arr[]={"a","b","c"};
GenCombinations(str_arr);
}
public void GenCombinations(String... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616989",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "3"
} |
Q: Efficient way to check if a list of random numbers contains a range from 1 to n If I have an randomly shuffled array with the numbers 1 to n, what is a good way to find that the array contains the range 1 to n (no repeats)? For example,
n = 6; [1, 3, 6, 2, 4, 5] => true
n = 6; [1, 1, 2, 4, 5, 6] => false
A: Sounds... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616991",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: style for displaying tooltip box Not know why tooltip box(class .show_tooltip) there is left when mouse enter on li a, i want display each tooltip box top same link that mouse is enter on it and if the width and height was more or less it is same style.(i want links put in right) DEMO
I want example this (for how): ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616992",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "4"
} |
Q: Specific file type allowed? php upload Im creating a image uploader, and i dont know how to do so only the filetype can be .jpg so im asking you, do you know it?
heres what i got so far:
<?php
session_start();
if($_SESSION['username']) {
$target_path = "users/$username/";
$target_path = $target_path . b... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616994",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: Python regex string matching? I'm having a hell of a time trying to transfer my experience with javascript regex to Python.
I'm just trying to get this to work:
print(re.match('e','test'))
...but it prints None. If I do:
print(re.match('e','est'))
It matches... does it by default match the beginning of the string... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7616998",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "33"
} |
Q: Finding hidden sheets (and hidden cells) in excel with VBA Is there a way to determine if an Excel workbook has hidden sheets and/or hidden cells using VBA? Thanks!
A: You can loop through the worksheets, columns, and rows checking the worksheet.visible and range.hidden properties. Below is some quick and dirty co... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7617000",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "5"
} |
Q: Dealing with schema changes in Mongoose What's the best practice (or tool) for updating/migrating Mongoose schemas as the application evolves?
A: I just had this problem where I needed to update my database to reflect the changes to my schema. After some research I decided to try the updateMany() function in the mo... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7617002",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "79"
} |
Q: Hot Code Replaced Failed I keep getting the below warning message in eclipse when doing Android development. No matter how many times I click the option to not show the warning again, it just keeps popping up. Sometimes I hit disconnect, sometimes I hit continue, but either way the warning keeps showing up.
How the... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7617005",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "3"
} |
Q: Code completion Pydev Django Model Foreign Key Field Code completion in Eclipse/pydev works decent for me. However there is one thing that does not work like I want it to. Consider the following django model:
class ReletionTree(models.Model):
mother = models.ForeignKey('RelationTree', blank=True, null=True)
... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7617009",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: Android LinearLayout and Images Ok, I know this can't be hard, but I'm having a heck of a time with it.. I'm a seasoned Java programmer, but very new to Android (ok, so I'm working on my first test app still...)
I'd like to have 3 images on the screen, one "main" image that takes up, say, the top 75% of the screen,... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7617011",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: Does pthread_detach wait for the child process to terminate, as the pthread_join does? I wanted to know will pthread_detach halt the parent until the child thread terminates, or it goes on with the execution??... As, the pthread_join waits for the child thread to finish and then proceed...
A: I believe the purpose... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7617014",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Determine the visual size of an object at a given distance from origin (using perspective) Let's say we have a square, 50 pixels wide. And the -webkit-perspective is 1000px*.
What is the formula to determine how big the square will appear to be at a given distance from the viewer (the width it will actually appear t... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7617021",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Building web-based expert systems? A client has asked us to build a web-based tool to help new users entering into their domain. The system would ask users questions to help build a profile on them and their interests. The profile could then be used by real-life counselors in figuring out what the user needs to do n... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7617022",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: How does the UserTransaction and the EntityManager interact? This is an academic question; I have no broken code in relation to this. I just want to expand my understanding of what is happening under the hood.
The code pattern I have been using (copied from books and tutorials) in my JPA DAO for my typical JSF web... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7617026",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "16"
} |
Q: Rails 3 fragment caching not doing anything Trying to get fragment caching to work in Rails 3.0.9.
I have set this in development.rb:
config.action_controller.perform_caching = true
And restarted the server (webrick). Then set this in my view:
<% cache("tags_json") do %>
[Content to be cached]
<% end %>
And wh... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7617027",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "4"
} |
Q: Import and run things in one off Clojure script I'm new to Clojure and I've been following the tutorial here: http://devcenter.heroku.com/articles/clojure-web-application
So I've been running my apps with foreman start and then testing small Clojure scripts with lein repl.
However running sequences of interactions i... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7617028",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: inject class in to using statement with spring.net I am developing a .net c# application that uses dependency injection with spring.net and ran in to an issue. I have the following method:
public string Process()
{
using(var p = new MyClass())
{
// do some processing
return p.RunClass... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7617032",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "3"
} |
Q: javascript on href disabeld on apps? Suddenly all my apps does not work the javascript I include in href, sample:
<a href="javascript:dosomething()">click</a>
this worked ok a week a go but now it does not execute anyway. is there any way to fix this?
A: Try:
<a href="#" onClick="dosomething(); return false;">clic... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7617039",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: What does TypeError: not all arguments converted during string formatting mean in python here is my first program it basically says stuff out loud and in different voices :
import os
print "Hello, Welcome to the speaking program"
speak = raw_input("What would you like to say?\n")
type = raw_input("Would you like\n1.... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7617042",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "-1"
} |
Q: Text not aligning middle
As you can see the text is aligned towards the top instead of in the middle.
It occurs on chrome as well as firefox, various versions including latest.
Various Line-height / Font-size / Vertical-align doesnt fix anything, it always stays slightly upwards. I can't find a solution to what thi... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7617051",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "3"
} |
Q: eBay Trading API LeaveFeedbackCall I am attempting to set seller feedback through the eBay Trading API, LeaveFeedbackCall. I am using the .NET SDK and am having difficulty assigning the feedback details. In the API description this is an array SelerItemRatingDetailsArray that holds ItemRatingDetails with two items, ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7617056",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Java getSystemJavaCompiler from JDK I am using ToolProvider.getSystemJavaCompiler();, but it is returning null because my JDK isn't in my PATH (and I can't put it there). How would I make getSystemJavaCompiler() use my JDK?
| {
"language": "en",
"url": "https://stackoverflow.com/questions/7617059",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Obtain location coordinates from UIButton I'm trying to obtain the coordinates of a UIButton that is in a subview of the mainviewcontroller. I can return them relative to the subview with the code below but how do I return the UIButton location as it relates to the mainviewcontroller?
ScrollingAppDelegate *appDele... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7617060",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Recursive Query in MYSQL? I think my problem is solved with a 'recursive query', but since MySQL doesn't support recursive queries I was trying to use the adjacent list model. This should not be a problem since I know how deep I want to go.
Here's an example of what I need to do:
Table Classes:
dept classNum ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7617063",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "3"
} |
Q: PDB won't stop on breakpoint I'm quite new with debugging directly with pdb and I am having some issues debugging my Django application. Here is what I'm doing:
python -m pdb manage.py runserver
(pdb) b core/views.py:22
Breakpoint 2 at /Users/raphaelcruzeiro/Documents/Projects/pdb_test/core/views.py:22
(Pdb) c
Howe... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7617066",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "27"
} |
Q: Detect end of running process without Admin rights I was wondering if it was possible to detect when a certain process gets killed or closed the normal way. With other words if the process is removed from the process list.
I know it's possible by using WMI and the System.Management.ManagentEventWatcher, however this... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7617074",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Grouping items that were created within a certain time of each other I have a bunch of products (500k or so) in a database that were created over the last several years and I'd like to group them together (Rails 2.3.14)
Ideally, they would be considered the same group if:
*
*They were created by the same company_... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7617076",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Assigning NSMutableString To UILabel Text I am making a fraction calculator app from the Programming In Objective-C 2.0 book. I am using XCode 4.1 for Lion. I have completely and successfully without any error typed in the code. But when I press a number button while the app is running, the label doesn't input any t... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7617079",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: How to retrieve all email addresses in Facebook through API Facebook users can add multiple email addresses. I know, with the extended "email" permission, you can retrieve the primary email address through the graph API. How do you retrieve the rest of the email addresses? This is important for my app so that I c... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7617085",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "3"
} |
Q: css style fieldset i'm new to css and i'm trying to figure out a way to incorporate a legend tag as an
header for my page
currently my master page is styled by a field set :
fieldset.field_set_main
{
border-bottom-width:50px;
border-top-width:100px;
border-left-width:30px;
border-righ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7617090",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Create a range of strings from end values I use irb.
I write the code below.
"ax".."bc"
I expect
"ax""ay""az""ba"bb""bc"
But the result is just
"ax".."bc"
How should I correct?
Thanks.
A: > puts ("ax".."bc").to_a
ax
ay
az
ba
bb
bc
A: The range 'ax' .. 'bc' does represent the values that you expect but it doesn't ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7617092",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "5"
} |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.