I've recently had difficulties with Apache not processing PHP files on my Mac after upgrading to macOS Sierra. Original post about it .  The way in which I "fixed" this problem was to add the following to /etc/apache2/httpd.conf  AddType application/x-httpd-php .php   I then restarted Apache sudo apachectl restart and my PHP scripts were processed.  However, when I run a phpinfo() script it's saying PHP Version 5.6.24  When I run PHP from a command line, it's reporting PHP 7.0.10 (which is what I expect and want).  It gets stranger because I don't know where PHP 5.6.24 even exists on my system. If I run   which php   It gives:  /usr/local/php5/bin/php   But examining this further, that appears to be a symbolic link to PHP 7:  $ cd /usr/local $ ls -l lrwxr-xr-x 1 root  wheel 38 14 Sep 11:18 php5 -&gt; /usr/local/php5-7.0.10-20160831-102733   Executing PHP directly from /usr/local/php5-7.0.10-20160831-102733 also reports PHP 7:  $ pwd /usr/local/php5-7.0.10-20160831-102733/bin $ ./php -v PHP 7.0.10    How do I get Apache to use PHP 7.x, and more importantly, where is PHP 5.x on my system that it's running?
I wanted to know which php version I am using so I wrote the standard script:   phpinfo();   Which gives me  PHP version 5.6.10   The correct PHP version needed for my application. When I tried in terminal:  php -i   or  php -v   It shows me:  PHP version 5.3.2   Which I don’t need. Then I tried with:  which php   It shows me:  /usr/bin/php   Now I am confused which version of PHP I am using. The files are uploaded to the hosting website and I cannot make any changes to the config files like httpd.conf or php.ini.
How can I play sound in Java? I want to be able to play sound files in my program. Where should I look? Which is correct: "one or more is" or "one or more are"? I currently only have remote access to this CentOS box, I need to move /var form the primary RAID to a new set of disks that was installed with more space, My current thoughts on how to accomplish this is to temporarily mount the new RAID to /tmp/var. rsync everything from /var to /temp/var then modify the fstab to point /var at the new disks.  Here is my question. how do I delete the existing /var on the primary disks once I have the new disks mounted to that location (assuming this is even possible remotely)? Force URL link to open with a specific browser I've created a URL link in my dock, however, the link only opens with the default browser. I have safari, Firefox, and chrome (latest being the default) installed in my machine. I'm wondering if someone knows how to default the link to open with Firefox instead of Chrome but still keeping chrome as the default browser.  Note: I'm running Mavericks in my MacBook Pro. Can the JVM recover from an OutOfMemoryError without a restart The "Very Low Quality" (VLQ) flag reason is really annoying me.   It is the analog to the mommy mommy flag (which my 1.5-year-old child raises quite frequently). It provides no real clue as to what the flagger really wants us to do with the post.   Does she want us to close the question?  Does she want us to edit it into shape?  Does she want us to delete the question?  Does she want us to ban the user?  Does she want us to jump around and have a party?    Should we get rid of this flag reason?   Is it just me? Should and can we replace it with something better?     EDIT I accepted Jeff's answer. The tougher wording has heavily decreased the amount of very low quality flags. We now see only about 25% of the amount we used to and they are usually valid. Additionally, we now only allow very low quality on posts with a score of 0 or lower. Packed images used as background don't show up when reopening the file I have seen a single (1) mention of View port background images disappearing when the .blend file is saved and reopened.  However...the answers are not relative to what I am experiencing.  I go through the trouble of setting up four images (top, side, front, back) and then pack these images using External Data &gt; Pack all into .blend and then I save the .blend.  I save the file, open it back up, and the background images are all gone. Open up properties panel, look to see background images check box is unchecked, click add image, and choosing the open drop-down arrow...the data paths still show the list of images (packed into a specific folder textures).  They are still there, the data set is intact.  Why is It that I have to set this up each and every time I open the file.  It seems like earlier versions &lt;2.76B saved the images and saved the file with the background images check box checked without the need to set this up each time the file is reopened.  This is getting very frustrating due to the fact that a few of the background images mus be set up using Blender's rotate, scale and move tools to align the background image up with the model I have already fabricated.  Thanks! Best way to track onchange as-you-type in input type="text"? In my experience, input type="text" onchange event usually occurs only after you leave (blur) the control.  Is there a way to force browser to trigger onchange every time textfield content changes? If not, what is the most elegant way to track this “manually”?  Using onkey* events is not reliable, since you can right-click the field and choose Paste, and this will change the field without any keyboard input.  Is setTimeout the only way?.. Ugly :-) How do I tackle this combinatorics problem about married couples around a table? How to divide LaTeX table cells vertically? I want my table to have separated cells. Basically double lines but I can't figure how to have horizontal lines disconnected. I tried \hline and \cline but those connect too.  This is best I can do:    This is how I want my table to look:   \begin{tabular}{|c||c||c||c|}   \hline   \multicolumn{2}{|c||}{First Cell}&amp;   Second Cell&amp;   Third Cell\\   \hline   \hline   \begin{tabular}{@{}l@{}} Data\\ Data\\ Data\\   \end{tabular}&amp;   \begin{tabular}{@{}l@{}}     Data\\     Data\\     Data\\   \end{tabular}&amp;   \begin{tabular}{@{}l@{}}     Data\\     Data\\     Data\\   \end{tabular}&amp;   \begin{tabular}{@{}l@{}}     Data\\     Data\\     Data\\   \end{tabular}\\    \hline  \end{tabular} When is it best to write "can't" versus writing "cannot"? Are they interchangeable in every situation? ASP.NET Call Code Behind Function From Javascript Relevance of cycle detection in Pollard's rho integer factorization algorithm I've recently learned about Pollard's rho factorization algorithm, and the way I understand it, it works by using a pseudorandom sequence of integers $x_{k}$ ranging from $0$ to $n-1$, where $n$ is the number to be factored, to find repetitions in an unknown sequence $y_{k} = x_{k} \bmod p$, where $p$ is an unknown, non-trivial factor of $n$. Such a repetition $y_{i}=y_{j}$ occurs when $x_{i}\equiv x_{j} \bmod p$, which can be detected by checking whether $\gcd(x_{i}-x_{j}, n)\gt 1$.  From what I could find on the Internet, Floyd's cycle detection algorithm or a variant thereof is used to find such repetitions. And the reason for this is what I don't understand.   First, Floyd's algorithm requires that each element in the sequence depends solely on the element before it, which, even if it is the case for $x_{k}$, is not necessarily the case for $y_{k}=x_{k}\bmod p$. For example, assuming we want to factorize $6$, let's take the sequence $5, 3, 2, 4, 1, 0, 5, 3, 2, 4, 1, 0,\ldots$. The cycle period is $5, 3, 2, 4, 1, 0$, where every element is contained only once. However, if we take this sequence $\bmod 2$, we get $1, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 0,\ldots$. Floyd's algorithm cannot be applied here to find the cycle period $1, 1, 0, 0, 1, 0$. Besides, we are not even interested in a cycle, only in repetitions. Whether we find the congruence $\bmod 2$ between $5$ and $3$, $5$ and $1$, or $4$ and $2$ in the first sequence is irrelevant.   Please correct me if my understanding of Pollard's rho algorithm as described above is wrong. But if it is not, it seems to me that one could just as well try out some random numbers between $2$ and $n-1$ and see if they share a divisor with $n$ other than $1$. So what is the benefit of using a cycle detection method like Floyd's algorithm?  I also found , but it is not answered, and the comment on the question does not really answer the question either. Convert bytes to a string .NET obfuscation tools/strategy My application got crashed because of not initializing the view Rounding to nearest 100 First number needs to be rounded to nearest second number. There are many ways of doing this, but whats the best and shortest algorithm? Anyone up for a challenge :-)   1244->1200  1254->1300 123->100 178->200 1576->1600 1449->1400 123456->123500 654321->654300 23->00 83->100 Struct padding in C++ How to fix "The system is running in low-graphics mode" error? Hearing a sound backwards because of Doppler effect