Questions

How to send POST request?

I found this script online: ``` import httplib, urllib params = urllib.urlencode({'number': 12524, 'type': 'issue', 'action': 'show'}) headers = {"Content-type": "application/x-www-form-urlencoded", ...

8 Jul at 08:3

Create code first, many to many, with additional fields in association table

I have this scenario: ``` public class Member { public int MemberID { get; set; } public string FirstName { get; set; } public string LastName { get; set; } public virtual ICollecti...

Looking to understand the iOS UIViewController lifecycle

Could you explain me the correct manner to manage the `UIViewController` lifecycle? In particular, I would like to know how to use `Initialize`, `ViewDidLoad`, `ViewWillAppear`, `ViewDidAppear`, `Vie...

Difference between getAttribute() and getParameter()

What is the difference between `getAttribute()` and `getParameter()` methods within `HttpServletRequest` class?

11 Jan at 20:5

How do I update a Python package?

I'm running Ubuntu 9:10 and a package called M2Crypto is installed (version is 0.19.1). I need to download, build and install the latest version of the M2Crypto package (0.20.2). The 0.19.1 package ...

Not class selector in jQuery

Is there a simple selector expression to not select elements with a specific class? ``` <div class="first-foo" /> <div class="first-moo" /> <div class="first-koo" /> <div class="first-bar second-foo"...

6 Jan at 10:51

Explode PHP string by new line

Simple, right? Well, this isn't working :-\ ``` $skuList = explode('\n\r', $_POST['skuList']); ```

22 Oct at 13:46

Add leading zeroes/0's to existing Excel values to certain length

There are many, many questions and quality answers on SO regarding how to prevent leading zeroes from getting stripped when importing to or exporting from Excel. However, I already have a spreadsheet...

25 May at 18:10

Is there any boolean type in Oracle databases?

Is there any Boolean type in Oracle databases, similar to the `BIT` datatype in Ms SQL Server?

Retrieve version from maven pom.xml in code

What is the simplest way to retrieve version number from maven's pom.xml in code, i.e., programatically?

10 Jul at 04:22

How to get the previous URL in JavaScript?

Is there any way to get the previous URL in JavaScript? Something like this: ``` alert("previous url is: " + window.history.previous.href); ``` Is there something like that? Or should I just stor...

13 Nov at 12:25

Difference between Java SE/EE/ME?

Which one should I install when I want to start learning Java? I'm going to start with some basics, so I will write simple programs that create files, directories, edit XML files and so on, nothing to...

17 Oct at 11:8

The provided URI scheme 'https' is invalid; expected 'http'. Parameter name: via

I am trying to make a WCF service over basicHttpBinding to be used over https. Here's my web.config: ``` <!-- language: xml --> <service behaviorConfiguration="MyServices.PingResultServiceBehavior" ...

6 Apr at 08:24

Retrieving the output of subprocess.call()

How can I get the output of a process run using `subprocess.call()`? Passing a `StringIO.StringIO` object to `stdout` gives this error: ``` Traceback (most recent call last): File "<stdin>", line ...

16 Jan at 19:31

Increase heap size in Java

I am working on a Windows 2003 server (64-bit) with 8 GB RAM. How can I increase the heap memory maximum? I am using the `-Xmx1500m` flag to increase the heap size to 1500 Mb. Can I increase the heap ...

22 Mar at 15:10

What is a unix command for deleting the first N characters of a line?

For example, I might want to: ``` tail -f logfile | grep org.springframework | <command to remove first N characters> ``` I was thinking that `tr` might have the ability to do this but I'm not sure...

18 Aug at 07:21

How to hide 'Back' button on navigation bar on iPhone?

I added a navigation control to switch between views in my app. But some of the views shouldn't have 'Back' (the previous title) button. Any ideas about how to hide the back button?

Is there a way to access an iteration-counter in Java's for-each loop?

Is there a way in Java's for-each loop ``` for(String s : stringArray) { doSomethingWith(s); } ``` to find out how often the loop has already been processed? Aside from using the old and well-kn...

27 Jan at 12:28

Should I use SVN or Git?

I am starting a new distributed project. Should I use SVN or Git, and why?

10 Apr at 23:34

Does C++ support 'finally' blocks? (And what's this 'RAII' I keep hearing about?)

Does C++ support '[finally](http://java.sun.com/docs/books/tutorial/essential/exceptions/finally.html)' blocks? What is the [RAII idiom](http://en.wikipedia.org/wiki/Resource_Acquisition_Is_Initializ...

14 Sep at 13:33

Xcode error: Failed to prepare device for development

I have updated to Xcode 12.3 beta. device version is 14.2, but Xcode complaining: > Errors were encountered while preparing your device for development. Please check the Devices and Simulators Window....

2 Oct at 19:46

Unable to merge dex

I have Android Studio Beta. I created a new project with compile my old modules but when I tried launching the app it did not launch with the message: ``` Error:Execution failed for task ':app:transf...

13 Nov at 22:36

Difference between using gradlew and gradle

What is the difference between using `gradlew` and `gradle` or are they the same?

31 Jan at 04:9

ReactNative: how to center text?

How to center Text in ReactNative both in horizontal and vertical? I have an example application in rnplay.org where and is not working: [https://rnplay.org/apps/AoxNKQ](https://rnplay.org/apps/Ao...

7 May at 11:55

Changing EditText bottom line color with appcompat v7

I am using appcompat v7 to get the look consistent on Android 5 and less. It works rather well. However I cannot figure out how to change the bottom line color and the accent color for EditTexts. Is i...