I'm stuck trying to convert a string in a Javascript format into a format I can use in PHP for filtering.  An example of the date string that I'm given is  "Thu Jan 01 2015 00:00:00 GMT-0800 (Pacific Standard Time)"  Let's say I have that assigned to a variable $z.  When I run the following, I get an unexpected result:  $z = "Thu Jan 01 2015 00:00:00 GMT-0800 (Pacific Standard Time)"; $value = date('Y-m-d H:i:s', strtotime($z));   This gives me $value = "1970-01-01 00:00:00", obviously not what I wanted.  I've also tried the following with no luck:  $value = DateTime::createFromFormat('D M d Y H:i:s',$z); //Fails   Now I'm pretty sure that the timezone info is what is messing everything up, but I just can't seem to figure out what to do here.  I'm using Laravel 5, so I've also attempted similar operations with Carbon. Does anyone have any suggestions?
How do I get timestamp from e.g. 22-09-2008?
I would like to ask for some simple examples showing the uses of &lt;div&gt; and &lt;span&gt;.   I've seen them both used to mark a section of a page with an id or class, but I'm interested in knowing if there are times when one is preferred over the other. Nonconstant polynomials do not generate maximal ideals in $\mathbb Z[x]$ Let $f$ be a nonconstant element of ring $\mathbb Z[x]$. Prove that $\langle f \rangle$ is not maximal in $\mathbb Z[x]$.   Let us assume $\langle f \rangle$ is maximal. Then $\mathbb Z[x] / \langle f \rangle$ would be a field. Let $a \in \mathbb{Z}$. Then $a + \langle f \rangle$ is a nonzero element of this field, hence a unit. Let $g + \langle f \rangle$ be its inverse. Then $a g - 1 \in \langle f \rangle$, hence $ag(x)-1 = f(x)h(x)$ for some $h \in Z[x]$, hence $ag(0) + f(0)h(0) = 1$, thus $(a,f(0))=1$ for all $a \in \Bbb Z$, contradiction, hence the proof.  Is my argument correct? Is there any other method? What is the name of an anime from 80s-90s movie/series in which there is a scene, maybe the end, where a girl (who has an​ armor) exchanges age with a dying man in a beach, so the man transforms into a baby and the girl grows to a woman? Which merchants pay best? I noticed at some point that different merchants don't all pay the same for what you're selling. Depending on the category, or even the specific item, some merchants simply pay significantly more.  Are there some general rules on which merchants pay better for which items? I am aware of what hyperfocal distance is and the general principles behind it. However, most of the tutorials I have seen and read regarding it make use of lenses with focus distance indicators. Unfortunately, neither of my lenses (Nikkor 18-55mm &amp; 35mm f1.8) have indicators.  I have read that you can 'cheat' and simply focus a third of the way into the shot (which I have done previously simply by spot-focusing on the lowest focus point in my VF). I also assume you could pace out the distance and note an object to focus on when you get back to the camera (though that might be easier said than done).  Does anyone have any suggestions on how to achieve maximum sharpness from front to back without focus distance markers. A new lens is not an option; global economic crisis and all that! Trying to search for multiple file extensions in command line I am trying to find two extensions in command line but when i do it will only return one of the extensions. can you tell me what I am missing?   Here is my command;  [root]# find /etc -name "*.txt" -o -name "*.log" -type f -mtime +7 -exec echo {} \; Eliminating non-integer solutions to $ab / (2\sqrt{ab} + a + b)$ How was Jon Snow able to kill the White Walker in S05E08? Polynomial passing through two points with specific tangents How can I calculate a Polynomial that passes through the origin and a given point (P) having given tangents at the origin (Ot) and the given point (Op)?  The given point will always be to the right of the origin (Px &gt; 0). The polynomial should be a function of x (i.e. it moves from left to right).  I believe a 3rd degree polynomial will always fit these constraints, but I'm not certain.  I am looking for a function f( x, Px, Py, Ot, Pt ) = ? which plots a polynomial for x, satisfying the four given values.  When x = 0,   f()   = 0 When x = Px,  f()   = Py When x = 0,   f'()  = Ot When x = Px,  f'()  = Pt How to get the key for a given object from an NSMutableDictionary? I sadly haven't been able to answer this questions using Google. In beamer, I'd like to make the default font for the entire title page, as well as frame titles, to be the default font from the old  (example ). Suppose $f(x)$ and $g(x)$ are continuous function from $[0,1]\rightarrow [0,1]$, and $f$ is monotone increasing, then how to prove the following inequality: $$\int_{0}^{1}f(g(x))dx\le\int_{0}^{1}f(x)dx+\int_{0}^{1}g(x)dx$$ Is there any hint of of the first Wizarding War being an international event? Is there any hint that the MoM or anywhere else got support in combating voldemort the first time around? Or is everything completely UK-centric?  I can't remember anyone in the second war being specifically sent from europe to help, even though we see international wizards in book 4. But I don't think all the events of the first war are covered in the books.  So are other bodies like the MoM involved in the first war, or was it isolated in the UK? How to avoid spammy links affecting us before SERP rankings going down We have recently discovered a host of spammy links pointing to our website been put up in last 1 month through webmaster tool We have not engaged any seo agency/link building and have never created these links  Worst, these are spammy forum sites and almost some-one seems making an attack to our site as the link and keyword is same in all these sites Till not Have not received any warning, however as it has come to our notice - before any SERP getting down - we want to action this out  One thing we have observed is that - All these spammy links points to a single inner page of website  Pl suggest as have   a) Will Google disvow tool will work by stating to disvow these links  or  b) Is it a good way if we make this specific page 'nofollow' and even 'noindex' The reasoning behind this is like if the page is not followed and not indexed - the negative links pointing to the page of the site is already no follow and may be out from google serp  or what's the best alternate way to tackle this. Pl suggest in urgent help and advise required How to make a file executable? How can I make my file so that I can double click on it, and it runs. It is a .sh script, but I also have files that say:  executable (application/x-executable)  in the description of what they are.  I can't run any of these from terminal, or by double clicking.  If possible, I would like a way using either the GUI or a Terminal, but not a combination of the two.  Here is a screenshot of what I see when I right click then go on properties. The file first:    And the shell script here:    NB: I accept that this is a duplicate (I was looking for it, and couldn't find it, so asked + answered it, hoping that I would find it) however, I don't think the question about .desktop files is a duplicate. Are there any subtle differences between "somebody" and "someone", or can they be used completely interchangeably? Similarly, can you imagine a situation in which you would prefer "anybody" to "anyone" or vice versa? How to compute $m$ value from RSA if $phi(n)$ is not relative prime with the $e$? Here is some information we got : We know the value of $n$, with size $1043$. We know the value of $p$ (size $20$) and $q$ (size $1023$) as the factors. $e = 65537.$ $\varphi(n)$ = $(q-1)(p-1)$ When I calculated $\gcd$ and $\text{modinv}$, I got : $\gcd(e,\varphi(n)) = 65537$ $modinv(e,\varphi(n)) = 1 $ So we can tell that they are not relatively prime. So, how to compute the d, and get the value of m? I'm not that good with math, so I cant understanding well the theory. so can anyone please make an example implementation or write a clear formula? Given: $a = qb + r$. Then it holds that $\gcd(a,b)=\gcd(b,r)$. That doesn't sound logical to me. Why is this so?    Addendum by LePressentiment on 11/29/2013: (in the interest of  and averting a duplicate)  What's the intuition behind this result? I only recognise the proof and examples solely due to algebraic properties and formal definitions; I'd like to apprehend the result naturally. Unable to lock the administration directory (/var/lib/dpkg/) is another process using it? Word or expression for a constituent that perfectly exemplifies the whole Suppose that  (1990) is considered appalling, but you can't put your finger on exactly why, mainly because there are a plethora of reasons, most of which you lack the training/education/expertise to comment in-depth on (e.g. the writing, directing, editing etc.), so you use what you consider to be a disastrous moment/scene as an example, and think "this pretty much sums it up", for example , what would you call a scene like that? A single word or expression is satisfactory.  As an example:     "The Godfather 3 is so bad, for so many reasons, but here is a ______ that perfectly represents everything wrong with the movie."   An expression is also acceptable, and the example I gave is flexible (doesn't have to be structured as it is in the example).