|
Just purchased some VPS hosting and am getting setup to get my startup app underway. For the moment I'm playing sysadmin and am running into errors galore whilst trying to work out the kinks.
So I was wondering what the best solution (if any?) there is...
Started by Patrick McLaren on
, 4 posts
by 4 people.
Answer Snippets (Read the full thread at serverfault):
You want some type of system....
Also set up something like Nagios to alert on internal services, also set up to alert via sms, using a provider such as Clickatell .
Set up a Pingdom monitoring service to send you emails and SMS messages when things go wrong .
|
|
Can you remove an item from a List<> whilst iterating through it? Will this work, or is there a better way to do it?
My code:
foreach (var bullet in bullets) { if (bullet.Offscreen()) { bullets.Remove(bullet); } }
-edit- Sorry guys, this is for ...
Started by Chris on
, 8 posts
by 8 people.
Answer Snippets (Read the full thread at stackoverflow):
For (int count = bullets.Count - 1; count >= 0; count--) { if (bullets[count].Offscreen()) { //bullets.Remove(bullets[count... .
You need to iterate through it backwards with a for loop .
Attempting to remove it within a foreach loop will throw an exception .
|
|
I'm trying to animate a block level element using jQuery. The page loads with the element styled with display: none . Id like it to slideDown whilst transparent and then fadeIn the content using the callback, however slideDown appears to set the visibility...
Started by Brendan on
, 4 posts
by 4 people.
Answer Snippets (Read the full thread at stackoverflow):
How about:
$('#hiddenElement').css("opacity", 0).slideDown().animate({opacity:1})
a few probable issues with your code: are you setting the content to hide as well in the beginning? are you calling fadeIn during the slideDown callback?
here's some example... .
|
Ask your Facebook Friends
|
Hi --
This may be a stupid question, but I'll feel stupider if I don't ask and find out in 12 months that it was possible (this happened when I realized I could do what I'm requesting below with .aspx files).
Is it possible to change my project files ...
Started by James S on
, 3 posts
by 3 people.
Answer Snippets (Read the full thread at stackoverflow):
You will only be able to do this if you... .
Under servers check Enable Edit and Continue.
Also, you must for each project go to Project -> [Project Name] Properties, click on the Web tab .. .
Set breakpoints around where you want to change the code .
|
|
Is there a built-in that removes duplicates from list in Python, whilst preserving order? I know that I can use a set to remove duplicates, but that destroys the original order. I also know that I can roll my own like this:
def uniq(input): output = [...
Started by jmglov on
, 4 posts
by 4 people.
Answer Snippets (Read the full thread at stackoverflow):
Here you have some alternatives: http://www.peterbe.com/plog/uniqifiers-benchmark
Fastest one:
def f7(seq): seen = set() seen_add = seen.add return [ x for x in seq if x not in seen and not seen_add(x)]
EDIT:
If you plan on using this function a lot, ... .
|
|
I'm setting up a small vpn service for 10 - 100 expats so they can access normally blocked sites. I would like them to be able to sign up via my website, which upon payment the site will generate their client.cert, client.key and client.conf and perhaps...
Started by adam on
, 3 posts
by 3 people.
Answer Snippets (Read the full thread at serverfault):
I have a sneaking suspicion that the big CAs that provide "instant" SSL certificates are probably either relying on a 24x7 low-paid support person, or (more likely) just putting the CA key on a machine with extremely limited connectivity and only allowing... .
|
|
Hi
I am inserting jpeg images into my UTF-8 encoded Postgres database into bytea column/s. I'm using a prepared sql statement to insert the images. In the statement I create a file object, within Java, of the jpeg image and then pass it as a FileInputStream...
Started by Graham on
, 4 posts
by 4 people.
Answer Snippets (Read the full thread at stackoverflow):
Well, 0x84 is not a valid utf8 character:
=> perl -e 'print "\x84"' | iconv -f utf8 -t utf8 iconv: illegal input sequence at position 0
Generally - bytea will work with any bytes, but INSERT statement is a text string, and as such has to conform to... .
|
|
In my app I've got a thread which displays for some time "please wait" dialog window, sometimes it is a very tiny amout of time and there is some glitch while drawing UI (I guess).
I get the exception "Thread was being aborted" and completly have no idea...
Started by MoreThanChaos on
, 5 posts
by 5 people.
Answer Snippets (Read the full thread at stackoverflow):
A better solution would be to run this in the debugger with Debug >> Exceptions >> Thrown checked for all exception types, and figure out what is happening... .
Use SafeThread and set ShouldReportThreadAbort to false to make the problem go away.. .
|
|
Fan cut on whilst parked Odd one, cars been parked up on drive for hours, just popped outside and the fans running - any idea why, it definately wasnt running earlier
Started by Paul172sport on
, 13 posts
by 6 people.
Answer Snippets (Read the full thread at cliosport):
Re: fan cut on whilst parked did it talk to you when you went out?? seems very weird though! Re: fan cut on whilst parked Better be quick and catch them! Re: fan cut on whilst parked its still the coolant temp sensor wiring and the....
|
|
Texting whilst driving Hi all,
How many others have been in a near miss situation when driving on our roads.
Today I had another close call on the Motorway when an idiot ( putting it mildly ) was attempting to drive whilst texting.
I thought there was...
Started by airman on
, 21 posts
by 15 people.
Answer Snippets (Read the full thread at britishspanking):
Munching a sandwich whilst driving - talk about double standards! Originally Posted by MsMotorbike That said, I've seen a police officer merrily munching a sandwich whilst driving - talk about double, and all radios, cd players should be....
|