Apr
12
asked Can Inotify handle a large amount of directories?
Apr
10
revised Corect code in php
corrected code
Apr
7
comment PHP filter_input returns false
Why not just check if the length is within the range using an if(...) ?
Apr
6
comment if and foreach in a templating engine
It's not worth it. I've been there myself and ended up using PHP, which is probably the best templating engine you can have. Take a look at WordPress. Its templating system is one of the reasons it reached such popularity. Themes are easy to build because developers don't have to learn a new templating language
Apr
4
comment Are photoshop-like blend modes possible in HTML5?
Works in Chrome beta if you enable experimental Web Platform features . jsfiddle.net/X4GyF
Apr
2
comment PHP Cookie value not echoing anything
From the dox: If output exists prior to calling this function, setcookie() will fail and return FALSE. So are you printing anything before setting the cookie?
Apr
1
comment GeSHi code editor for the web
You can't do this with GeSHi because it doesn't offer editing capabilities, it only syntax-highlights your markup. Take a look at CodeMirror instead
Apr
1
comment Floating divs background color does not reach till page end
I'm not changing any heights. To draw the columns I'm just applying a gradient background on the body element, which by default extends all the way to the bottom. See the linked Q, it's called "faux columns" because they are not real columns. It's also possible to achieve this with flexboxes
Mar
31
comment Floating divs background color does not reach till page end
It doesn't really work. Try to expand the "text" content and you'll see that the side column is not extending all the way down. Also there's extra spacing on the bottom, that makes the scrollbar appear even when it shouldn't because there's not enough content
Mar
31
comment Floating divs background color does not reach till page end
Use a linear-gradient on the body: jsfiddle.net/GNLFh
Mar
31
comment Vertically center inline-table element in a div
Here is a good alternative, without tables: stackoverflow.com/a/13075912/1058140 . It fails in certain situations on IOS, but it's the best solution I've encountered
Mar
31
comment Css3 : Having a background for 300ms?
Why don't you try it? jsfiddle.net/kq3XC caniuse mentions buggy behavior in Android 2.3, so the best is to try it and see
Mar
31
comment Css3 : Having a background for 300ms?
yes, but with animations
Mar
31
comment JavaScript cant get max or min value or an array
your functions are returning the array, not the number
Mar
30
revised PHP - How to add more than 2 parameters to a variable?
deleted 12 characters in body
Mar
30
comment In php is there a difference in overhead between a function and a method of class?
I voted it down because it's not constructive- you're not asking if the performance impact of function/method calls is worth the attention (you could time that yourself btw), but if there's a performance difference between calling a function and calling a method that does the same thing. Of course the answer would be yes, but that's irrelevant in practice, because the "overhead" of both is measured in microseconds
Mar
29
accepted How to avoid locks during DELETE in sqlite?
Mar
29
comment How to avoid locks during DELETE in sqlite?
ok the issue was a missing index for the hero column, which also has a constraint :) Adding an index to the meta.gallery column didn't make much difference because it only does a single scan per deleted page record, that's like +2 seconds for my db, I can live with that. But you were right, thanks for the help! I wish EXPLAIN QUERY PLAIN would give more info, like search/scan operations on cascading deletes...
Mar
29
comment How to avoid locks during DELETE in sqlite?
I thought it would use the metaFileId index. Anyway, I did an "explain query plan" before I added an index for the gallery column and it was indeed doing a SCAN on meta. Now EXPLAIN QUERY PLAN tells me that is using the new index, but the query is just as slow as before :(
Mar
29
comment How to avoid locks during DELETE in sqlite?
@CL: the schema, but I had to comment out an index and the fts table because it doesn't seem to work on sqlfiddle. By soft deletes, do you mean updating the records with a value that suggests the record should not be taken into account in SELECT queries ? This is what I'm doing, but I still want to remove dead records in a background process. The problem is that the process locks some tables and is taking too long for what it does
1 2 3 4 5