Skip to content
Advertisement

Tag: php

I need to debug PHP. What is my best choice?

I’m working on a web site under a Linux environment (Debian). I’m not an expert at Linux but I can handle it, and the website is made using PHP, MySQL, HTML, etc. The thing is, I’m using PHP for the server side. Right now, for testing, I installed Apache on my PC so I can test everything. But, it would

PHP passing $_GET in the Linux command prompt

Say we usually it access via How do we execute the same on a Linux command prompt? But what about passing the $_GET variables? Maybe something like php -e index.php –a 1 –b 2 –c 3? I doubt that’ll work. Answer Typically, for passing arguments to a command line script, you will use either the argv global variable or getopt:

How to convert large SVG file to tiled PNGs?

I have a large SVG file (approx. 60 MB, 10000×10000 pixels but with the potential to get much larger), and I’m wanting to create, say, many tiled 256×256 PNG images from it (in that example there would be 1600 images; round(10000/256)^2). Does anyone have any idea of how to do this on a web server (running PHP amongst other things)?

Change the target of a symlink with PHP

How can I change the target of a symlink with PHP? Thanks. Answer You can delete the existing link using unlink function and recreate the link to the new target using the symlink function. You need to do error checking for each of these.

yum install php-pear* on centos

I’m trying to install pear on my centos. I’ve used “*yum install php-pear**” to install pear and it seemed to install with success. No errors. I restart my server. However when I check out phpinfo(). I see that my php is still built using “–without-pear”. Isn’t yum supposed to rebuild my php with pear? What would be possibly going wrong?

UTF-8 all the way through

I’m setting up a new server and want to support UTF-8 fully in my web application. I have tried this in the past on existing servers and always seem to end up having to fall back to ISO-8859-1. Where exactly do I need to set the encoding/charsets? I’m aware that I need to configure Apache, MySQL, and PHP to do

Advertisement