Today's Question:  What's your opinion about Alibaba mooncake incident?        GIVE A SHOUT

SEARCH KEYWORD -- php



  Using htpasswd to protect your website in Nginx


We need to build a password protected website frequently such as an internal website within the team, demo website. Here what we are talking about is password protection in Nginx server level instead of application level registration and login. We are going to use Nginx server configuration and htpasswd file to achieve password authentication. The final result looks like below(Different browsers may have different interfaces): If the authentication fails, it will report a HTTP error: 401 Author...

   Nginx,Password protected,htpasswd     2013-06-07 21:35:27


  The 10 most expensive domains on the Internet


Domain name is the name which we usually type on the web browser address bar. For example, we may type http://www.apple.com on the address bar, here www.apple.com is the domain name. Can you imagine that this domain is worth millions of dollars? We believe that most domains are initially for starting related business and easy for users to remember. But with the popularity of the business, some of the domains become valuable and they are more expensive than some small companies. Below are some mo...

   Domain name,Price     2013-01-01 10:32:06


  The war with spam comment


Spam comments are annoying and notorious. They are either malicious data from hackers to exploit the loopholes of the site or advertisements posted by robots. These kinds of comments have their own features and patterns, if we are careful enough, we can find ways to block most of them although it's not so easy. To block the comment with malicious executable codes such as JavaScript, we should remember one rule : never trust user input. So wherever there are user inputs, we need to check the vali...

   Spam comment,Block,Filter     2013-11-29 20:29:43


  PHP to Objective C, where the f**k are parameters?


Javascript, PHP, Ruby functionsI assume you are very familiar with declaring functions in any of the languages above, if not, you should not be reading this. Let’s begin with a simple function to send email in these languages:// PHP or Javascript do_send_email (recipient, cc, subject, body); // Ruby do_send_email (recipient, cc, subject, body)So it’s clear by looking at the function’s signature that it takes 4 parameters and they could be optional, depends on your implementation. Eve...

   Objective-C,PHP,JavaScript,Parameter,Function name     2012-01-16 09:46:09


  Why every programmer should learn Python or Ruby


If you are a student, you probably know C, C++ and Java. A few know VB, or C# / .NET. At some point you’ve probably built some web pages, so you know HTML, CSS and maybe JavaScript. By and large, it is difficult to find students who have any exposure to languages beyond this. And this is a shame because there are a number of programming languages out there which will make you a better programmer. In this article, we give some reasons why you must learn Python or Ruby2. Compared to C/C++/...

   Python,Ruby,Advantage,JavamCmDusadvantag     2011-07-25 08:41:42


  One reason why mcrypt responds slowly


This morning one colleague came over and talked about one script which used mcrypt responded very slowly, the server configurations are fine. Don't know the reason. Here is one script which reproduces the issue: <?php $dmcryptText = "dummy"; $key = "foobar"; $size = mcrypt_get_iv_size(MCRYPT_BLOWFISH,MCRYPT_MODE_ECB);   $iv = mcrypt_create_iv($size); //Take care   $m = mcrypt_ecb(MCRYPT_BLOWFISH, $key, $dmcryptText, MCRYPT_DECRYPT, $iv); var_dump($m); When 20 requests of this...

   mcrypt,response,slow,solution     2012-09-27 12:03:16


  What kind of automated testing does Facebook do?


We do several kinds of testing. Some specifics:For our PHP code, we have a suite of a few thousand test classes using the PHPUnit framework. They range in complexity from simple true unit tests to large-scale integration tests that hit our production backend services. The PHPUnit tests are run both by developers as part of their workflow and continuously by an automated test runner on dedicated hardware. Our developer tools automatically use code coverage data to run tests that cover the ...

   Facebook,Testing,PHP,Automated testing     2012-02-28 08:10:10


  Understanding PHP's internal function definitions


Welcome to the second part of the “PHP’s Source Code For PHP Developers” series. In the previous part ircmaxell explained where you can find the PHP source code and how it is basically structured and also gave a small introduction to C (as that’s the language PHP is written in). If you missed that post, you probably should read it before starting with this one. What we’ll cover in this article is locating the definitions of internal functions in the PHP codebase, as wel...

   PHP,internal function,definition,rationale     2012-03-16 10:46:26


  Install LAMP in two easy steps


You might have seen my earlier post related to installing PHP, Apache and MySQL on UBUNTU 11.10. That process contains number of steps and some lengthy commands which we can not remember easily. After good comments from Gaurav and Coward I have managed to get that lengthy process in just 2 steps. So I thought its great to share with all readers to they can get benefit as...

   LAMP,PHP,Steps,Tutorial     2012-04-30 09:15:28


  10 Best Programming Languages of 2016 You Should Know


The technology is increasing rapidly and with the new technical scenario, the trend of commercial business has taken a new route. Today, more and more business are coming with their own websites. Therefore, creating websites is a must to display the commodities in a more reformative way which will attract the user to buy online. This article uncovers references of various programming language which will help you to build the website of the desired framework i.e. in WordPress, Joomla, Drupal, et...

   PHP,PROGRAMMING,C#,C++,RUBY,PYTHON,PERL,10 BEST PROGRAMMING LANGUAGES OF 2016,R,BEST PROGRAMMING LAN     2016-07-15 05:12:15