If you open your site and get error: Can’t connect to local MySQL server through socket ‘/var/run/mysqld/mysqld.sock’ (111), You can read this tutorial to find a solution.
X-Robots-Tag is a kind of http response header, it can tell search engine how to process your html page. In this tutorial, we will discuss X-Robots-Tag: noindex for beginners.
We usually use select statement to select rows from mysql database, however, these rows are ordered by primay key, not are orderded randomly. In this tutorial, we will introduce how to select random rows from mysql.
In many php applications, we should use php curl model to access the remote url. However, if php disable curl, you will fail to access. In this tutorial, we will discuss how to detect php curl is enabled or not.
When you are using base64 to encode a string, there are +, / and = characters in encoding result. In this tutorial, we will introduce how to replace +, / and = characters by encoding string with php base64.
WebP image is one of best image format used on sites, it is smaller than other image formats, such as jpg and png. In this tutorial, we will introduce how to convert png, jpg to webp image, you can change your website images to webp by our this tutorial.
To make browser show pdf file, we can use html embed or open a pdf url by browser. However, these two methods of displaying pdf file is hard to make some control, for example, if we only want to valid user to read pdf, how to control? To do this, we need output pdf file by php script. In this tutorial, we will show you how to do.
When we open a url by our browser, the browser will use http get method to send a request. However, if you only want to allow http post method, how to do? In this tutorial, we will introduce you how to set a php page only receive http post method request.
WebP image is a popular image format using in web development. In this tutorial, we will discuss what its mime type is and how to output is to our browser using php directly.
When you are using your browser to open a html or txt file, they will be opened by our broweser and not downloaded into your computer. In this tutorial, we will introduce you how to download them, not open them by using php.