You searched for php tutorials

  1. Essentials of LDAP with PHP

    =* # requesting: ALL # # homestead.localdomain dn: dc=homestead,dc=localdomain objectClass: top objectClass: dcObject objectClass: organization o: homestead dc: homestead Interacting with PHP With all these steps completed, we’re now ready to use PHP to query the server. To keep things
  2. PHP 5.6 End of Beta

    On June 5th 2014, the PHP group announced the fourth and final beta of the 5.6 version. This milestone ends the beta program and begins the RC program (currently planned for June 19th), which will from now on focus exclusively on making sure the version is stable enough for release. As is customary
  3. PHP News You May Have Missed - September, October 2014

    In an already familiar format, here’s more PHP news you may have missed over the past month or so. As usual, let me know if I’ve missed anything! Drupal 8 - beta 1 The long awaited version 8 of Drupal has finally been released - albeit in beta format. You can now take it for a spin
  4. 8 Must Have PHP Quality Assurance Tools

    Quality Assurance in PHP is a valuable but very rarely seen aspect. In a world focused on rapid deployment and a “ship now, worry later” mentality, a focus on quality is a rare sight, especially when dealing with the web. One of our authors recently directed my attention to Sebastian Bergmann’s
  5. Stress-test your PHP App with ApacheBench

    : For our demonstration, I created a subfolder Laravel under Code in the VM, added a subfolder called “public”, and put an index.php file inside with the following content: <?php echo "Hello Test"; In homestead.yaml, I called this site “homestead.app”, and in my hosts file on my
  6. 8 Heroku Add-ons for Production Ready PHP Apps

    using buildpacks - sets of open source code that describe how a slug is to be generated. Here’s an example of a PHP buildpack. Heroku uses “dynos” as units of computing power which spin up your slugs. Dynos are lightweight, isolated containers for your apps which can execute any process type
  7. HHVM vs Zend Engine in PHP 6

    The fabled PHP 6 is long overdue. This unicorn of the web dev world has been “coming” for decades now, and it’s still not clear whether or not it’s actually something that’s going to happen in this decade, or just an idea, a fantasy of the PHP userbase. Minor versions like 5.4 > 5.5 and 5.5
  8. PHPSummerCamp Review

    with good practice), which will only help in new user adoption. All in all, this talk was an excellent starter of the whole camp, and so much more than simple “basics” tutorials you can find online. Building a REST API with Symfony 2 This talk by Antonio Peric was rather underwhelming
  9. Understanding OpCache

    boosts in your PHP applications. Over the web you will easily find a lot of tutorials covering all the OpCache installation and configuration steps (it is enabled by default on 5.5, but can be installed as an extension on older versions). Read the article below to find the answers to some
  10. Social Network Authentication: Merging Accounts

    In this part, we will have a look at how we can make sure people don’t have multiple accounts after signing into our application through different means.

    Merging accounts

    If you allow users to sign up through different social networks and perhaps your own registration system, there is a good chance some users will have multiple accounts. How annoying can it be for a user who signed up through Facebook earlier, to come back later and log in through Twitter because he thought he used that one?We can prevent this by letting the user merge manually or try to use an automatic system to try and identify duplicated users.

    Setup

    I suggest a setup of two database tables. The first table is the general user table, which contains all information about the user.

    CREATE TABLE IF NOT EXISTS `user` (
      `id` int(11) NOT NULL AUTO_INCREMENT,
      `username` varchar(255) NOT NULL,
      `password` varchar(255) DEFAULT NULL,
      `firstname` varchar(50) NOT NULL,
      `lastname` varchar(50) NOT NULL,
      `emailaddress` varchar(50) NOT NULL,
      `city` varchar(50) NOT NULL,
      `birtdate` date NOT NULL,
      `gender` varchar(10) NOT NULL,
      PRIMARY KEY (`id`)
    ) ENGINE=InnoDB DEFAULT CHARSET=latin1 AUTO_INCREMENT=1 ;

    Note: As you can see, I used the fields that we also used in our SocialLoginInterface. You might need more or less fields depending on your application. You even could decide to split this table in a user and user_profile table if you wish.

    The second table contains all data regarding any third party logins the user used.

  11. Social Network Authentication: Google+

    application to work, our constructor will receive these 3 variables as parameters and set the properties. Until now, our code looks like this. <?php namespace SitePoint\SocialLogin\Google; use SitePoint\SocialLogin\Interfaces\SocialLoginInterface; class GoogleLogin implements
  12. How to be a Good Developer

    As a PHP developer, or any kind of developer as a matter of fact, you need to constantly improve yourself in this ever-changing industry; you need to learn and use new knowledge every day. What successful developers have in common, is that they care about programming a lot
  13. How to Create a Laravel CSS-Minify Command

    this option to keep comments. --concat: (optional) concatenate the minified files into one file called all.min.css. What is a Laravel Command Artisan is the name of the command line utility in Laravel. It comes with a set of predefined commands, which you can list with php artisan list. If you
  14. Building a Domain WHOIS and Social Data WordPress Widget

    view a demo of the widget and download the widget plugin. Coding the Widget First off, include the plugin header. <?php /* Plugin Name: Domain Whois and Social Data Plugin URI: http://sitepoint.com Description: Display whois and social data of a Domain. Version: 1.0 Author
  15. Integrating a CAPTCHA with the WordPress Login Form

    the plugin header. <?php /* Plugin Name: WP Login Form with reCAPTCHA Plugin URI: http://sitepoint.com Description: Add Google's reCAPTCHA to WordPress Login Version: 1.0 Author: Agbonghama Collins Author URI: http://w3guy.com License: GPL2 */ Create a PHP class with two properties
  16. Deep Dive into the WordPress HTTP API

    , externally with partners, and openly with the public. Credit: API Evangelist Within PHP, there are many possible ways for sending HTTP requests. Examples include file_get_contents, fsockopen, and cURL. Prior to WordPress 2.7, plugin developers all had their own implementation for sending HTTP
  17. Ubuntu Add-Ons with PHP

    - some quick tips (which is pretty much covered in above tutorials) then the code. You store you scripts under ~/.gnome2/nautilus-scripts Make sure you've got the php5-cli package installed ($ sudo apt-get install php5-cli) You need to add the PHP shebang line at the top of your script (I omitted
  18. Whip Up a Yahoo! Mashup Using PHP

    a decent knowledge of PHP 5 -- specifically, that you're comfortable with the basic syntax, classes and objects, and have some basic background on web services. Take a look at the Wikipedia article on web services and SitePoint's other PHP tutorials if you think you may have trouble
  19. Magento Basics, Request Flow, Standards and Best Practices

    primitive, but due to backwards compatibility could not be solved sooner - Magento 2 will use ZF2, modern PHP and namespaces. Request Flow Let’s see how a Magento application handles a request starting from the main index.php file. Application Initialization 1) If you use Nginx, you should
  20. Getting Started with the AWS PHP SDK

    Getting Started with AWS PHP SDK Amazon AWS S3 is a robust storage solution for the internet. It can be used to store and retrieve any amount of data, at any time, from anywhere on the web. With S3 you get access to highly scalable, reliable, secure, fast, inexpensive infrastructure for your web