Questions

psql: FATAL: database "<user>" does not exist

I'm using the PostgreSql app for mac ([http://postgresapp.com/](http://postgresapp.com/)). I've used it in the past on other machines but it's giving me some trouble when installing on my macbook. I'v...

23 May at 12:34

jQuery disable/enable submit button

I have this HTML: ``` <input type="text" name="textField" /> <input type="submit" value="send" /> ``` How can I do something like this: - - - I tried something like this: ``` $(document).ready(...

9 Jun at 21:23

How to fix docker: Got permission denied issue

I installed Docker in my machine where I have Ubuntu OS. When I run: ``` sudo docker run hello-world ``` All is ok, but I want to hide the `sudo` command to make the command shorter. If I write the c...

25 Oct at 20:1

How does Trello access the user's clipboard?

When you hover over a card in [Trello](http://en.wikipedia.org/wiki/Trello) and press +, the URL of this card is copied to the clipboard. How do they do this? As far as I can tell, there is no Flash ...

What file uses .md extension and how should I edit them?

On GitHub, several projects have `README.md` files. It seems like a simple format file to express text and pictures. I guess there is an editor or syntax explanation somewhere. Where can I find an ...

24 Jan at 07:33

Can HTML checkboxes be set to readonly?

I thought they could be, but as I'm not putting my money where my mouth was (so to speak) setting the readonly attribute doesn't actually seem to do anything. I'd rather not use Disabled, since I wan...

30 Sep at 21:58

Error:java: javacTask: source release 8 requires target release 1.8

Using IntelliJ IDE can't compile any projects. Screenshots of settings below: Used JDK: [](https://i.stack.imgur.com/cpggk.png) Project SDK and Language level: [](https://i.stack.imgur.com/0gEQl.p...

24 Apr at 08:16

Given two directory trees, how can I find out which files differ by content?

If I want find the differences between two directory trees, I usually just execute: ``` diff -r dir1/ dir2/ ``` This outputs exactly what the differences are between corresponding files. I'm inter...

6 Apr at 12:37

How do I remove version tracking from a project cloned from git?

I want to remove all version tracking from a project's directory. What is the correct method to do this? Can I do a shell command such as: ``` rm -rf .git ``` from my projects directory or is the...

4 Jun at 00:10

Prevent users from submitting a form by hitting Enter

I have a survey on a website, and there seems to be some issues with the users hitting enter (I don't know why) and accidentally submitting the survey (form) without clicking the submit button. Is the...

17 Dec at 10:23

Is there any way to kill a Thread?

Is it possible to terminate a running thread without setting/checking any flags/semaphores/etc.?

How to open a Bootstrap modal window using jQuery?

I'm using Twitter Bootstrap modal window functionality. When someone clicks submit on my form, I want to show the modal window upon clicking the "submit button" in the form. ``` <form id="myform" cla...

31 Oct at 21:37

In a Git repository, how to properly rename a directory?

I think it should work to copy the directory to be renamed to a new directory with desired name, and [delete the old directory](https://stackoverflow.com/questions/1947430/git-remove-directory), and `...

17 Jan at 12:44

See :hover state in Chrome Developer Tools

I want to see the `:hover` style for an anchor I'm hovering on in . In , there's a style dropdown that allows me to select different states for an element. > I can't seem to find anything similar in...

Running unittest with typical test directory structure

The very common directory structure for even a simple Python module seems to be to separate the unit tests into their own `test` directory: ``` new_project/ antigravity/ antigravity.py ...

8 Jun at 01:27

Regular Expressions: Is there an AND operator?

Obviously, you can use the `|` (pipe?) to represent `OR`, but is there a way to represent `AND` as well? Specifically, I'd like to match paragraphs of text that contain ALL of a certain phrase, but i...

3 Aug at 19:43

What is the strict aliasing rule?

When asking about [common undefined behavior in C](https://stackoverflow.com/questions/98340/what-are-the-common-undefinedunspecified-behavior-for-c-that-you-run-into), people sometimes refer to the s...

How do I conditionally add attributes to React components?

Is there a way to only add attributes to a React component if a certain condition is met? I'm supposed to add required and readOnly attributes to form elements based on an Ajax call after render, but ...

4 Dec at 03:20

String representation of an Enum

I have the following enumeration: ``` public enum AuthenticationMethod { FORMS = 1, WINDOWSAUTHENTICATION = 2, SINGLESIGNON = 3 } ``` The problem however is that I need the word "FORMS"...

6 Feb at 11:20

Sending email in .NET through Gmail

Instead of relying on my host to send an email, I was thinking of sending the email messages using my account. The emails are personalized emails to the bands I play on my show. Is it possible to d...

19 Apr at 17:29

Deleting DataFrame row in Pandas based on column value

I have the following DataFrame: ``` daysago line_race rating rw wrating line_date 2007-03-31 62 11 56 1.000000 56.000...

How to list npm user-installed packages

How do I list the user-installed / environment package in npm? When I do `npm -g list`, it outputs every package and their dependencies. Instead I'd like to see the packages installed in the working...

Is there a list of Pytz Timezones?

I would like to know what are all the possible values for the timezone argument in the Python library pytz. How to do it?

26 Feb at 11:37

How to play audio?

I am making a game with HTML5 and JavaScript. How could I play game audio via JavaScript?

30 Jul at 20:27

How do I remove files saying "old mode 100755 new mode 100644" from unstaged changes in Git?

For some reason, when I initially did a pull from the repository for a git project of mine, I got a ton of files in my working copy that have no discernible changes made to them, but keep showing up i...

1 Nov at 22:49