Skip to content
Advertisement

Tag: php

PHP download a file through direct link and save it on my server

I’m trying to run PHP script (from a Linux server) that will download a file through direct download link and save it on my server. here is the script I’m using: for some reason it doesn’t work for me, any suggestions ? Answer You need to verify that the ports are open on your firewall and use the below command:

Installing PHP in my home directory

I need to install PHP in my home directory, without polluting any directory outside my home [very important requirement!]. In the system there is already an older version of PHP running. I found instructions here: http://blog.thecybershadow.net/2013/01/25/installing-php-and-apache-module-under-home/ I am running these commands in my home directory, as normal user dan The author of the article states that you need to use

standard function to translate iso-639 codes to language name?

I guess there should be some standard method for this, just to avoid everybody retyping dull constants for their applications. 😉 I am looking for a function (usable in a php web app on linux) that can take two ISO639 language codes and returns the name of the first language in the second language, i.e. foo(“fr”,”de”) should return “französisch” and

Start background processes from a background process

I have a PHP script say test.php in linux Ubuntu, in this PHP script I use shell_exec() to start several background processes. When I execute php test.php, the background processes are started as expected, but when I run php test.php &, those several background processes are not started. Is it not a supported way to start background processes from a

getting pid of spawned exec in phing

I am using phing and running selenium server via ExecTask. Sometimes I need to stop running server by killing its process. Is there a possibility in phing of getting PID of process spawned in ExecTask ? Answer No, ExecTask cannot give the pid of spawned processes directly. It can only return it’s exit status and output. Maybe you can modify

Tracking php process on framework

I have a php framework is running on linux machine basicly every requests redirect to index.php by .htaccess One of my php started to run %100 CPU i want to track which progress is that but when i check process with ps aux | grep 23791 As normal, request redirect to index.php.But i have to find which request is this.

PHP run linux “less” command via exec – binary file warning

I have to convert some PDF files to TXT. I end up with “less” command, because for example pdftotext has some problems with tables in PDF. The problem is that when I ran the command from exec function (or shell_exec/system), less just showing me information, that selected PDF is binary file and result file is just TXT with PDF data

Convert JPG to TIFF using ghost script

i am trying to convert images from .jpg to .tiff using ghost script.And i have executed following command to do that. But i am getting this errors. What is the problem with my command? Any suggestion and guidance will be appreciated.I have to convert my images using ghost script because if i am using the images which is converted by

Advertisement