Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 6 years ago.
Improve this question
I have PHP file on my virtual Linux CentOS machine and intermittently when I open it I am getting right away
Vim: Caught deadly signal SEGV
Vim: Finished. Segmentation fault.
I tested that file many times there are no any kind of hidden special characters. More over if I open another PHP file or for that matter any file and open my troubled file from it (:e file_name) I can view it, edit and save without any problems.
Any suggestions what is wrong with that file and how to fix it?
Try following command:
vim -u NONE <your_file>
it will launch vim without processing /etc/vimrc and ~/.vimrc
If you'll be able to edit your file then it means that the problem is one of your vim plugins. Try disabling them one by one and see what happens.
Related
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 6 years ago.
Improve this question
Is there a known way to hide PHP code within a file?
I got an error message referencing a malware variable in a php file on a wordpress website.
When I grep for the variable it shows me the malware in the file
When I open the file in nano it doesn't show
When I download via sftp the malware doesn't show in notepad++
I'm wondering if:
grep could somehow be seeing 'cached files'?
is there is a way to hide php code?
has anyone using php or wordpress ever seen something like this?
I did everything to double check, yes these are the same files and all the other tips that were pointed out. opcache is off. I have no idea.
Removing face palming situations from the equation (e.g. downloading the wrong file, downloading from the different server - which have happened to me before ;)), maybe you could try to use
grep -n [variable name]
to figure out the line (-n) where the variable is in the file. That might help you.
Another suggestion is downloading the file and using diff tools against a known good version of the infected file.
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 7 years ago.
Improve this question
I own a site installed on my linux server but when I put PHP tags at the beginning of page, the source code appears..
How to avoid all the source code displayed ?
thank you in advance
This means that you are being served the file by Apache without it first being seen (processed) by PHP. Here are some troubleshooting tips as to why it isn't being processed by PHP:
Make sure that your file with the PHP tags ends in .php.
Make sure PHP is installed on your server. To install PHP on a debian server run sudo apt-get install php5
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 8 years ago.
Improve this question
I have multiple versions of gcc 4.1.2 and 4.9.1 installed as g++4.9.
The old version had really old libstdc++ and was always failing with requiring libgcc errors. I fixed that by adding
export LD_LIBARY_PATH=/home/naveen/gcc4.9/lib: /home/naveen/gcc4.9/lib64 to all users. I even set this in /etc/bashrc and did . /etc/bashrc as root.
Now I am running a c++ code using php but the code always fails with the same libgcc errors i was seeing from console. I can see that the apache is being controlled by user daemon.
How can I fix this so that apache and php use the modified ld_library_paths?
Edit the scripts that actually start httpd and export the variables there.
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 8 years ago.
Improve this question
I was wondering why my system says it is running the php from the /etc/php5/apache2/php.ini
directory when in fact it was running it from the /etc/php5/cli/php.ini .
When I did a phpinfo() on a file in the directory of the folder, I received this however the changes to the configuration file wasn't impacting the server until I searched the whole system for a php.ini file and found the php.ini file under the cli/ directory:
Hopefully you can see it. I wasn't sure exactly how to put in onto SO.
it's intentional so you can easily have different configuration depending on your runtime environment.
In your environment when php runs in command line mode it uses /etc/php5/cli/php.ini.
When you access it from browser php is running from apache. So then /etc/php5/apache2/php.ini is used.
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 9 years ago.
Improve this question
I've been using PHP-5.4.3 for about a month now, and today, I decided to make a switch to PHP-5.5.5, I downloaded the source code, and placed it in C:/php (also renaming the folder php-5.5.5 to php) and I added server variables, as usual C:/php/ <-- but here I got stuck. Because, usually I appended the php.exe at the end, which was found inside the PHP folder so, I could be able to access PHP from the command line, or start the built-in server, but now,I can't find this file, and I can't find a way to start the server from the command line either.
You can compile php yourself. It's simply 2-4 commands and its also explained. I can run configure then make install. You can run configure --help to see all the options. It can be useful if you compile for fast-cgi or need more space or a faster php.
The source code you downloaded needs to be built...
You can download a binary version from here (assuming you're using Windows, of course).
Or read this if you want to build it yourself. There are many other tutorials online.