<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Ojo Joseph Oluwaseun on Medium]]></title>
        <description><![CDATA[Stories by Ojo Joseph Oluwaseun on Medium]]></description>
        <link>https://medium.com/@iamjoestack?source=rss-528b40f6b30b------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*HOTpbrgiNEGMn4VR</url>
            <title>Stories by Ojo Joseph Oluwaseun on Medium</title>
            <link>https://medium.com/@iamjoestack?source=rss-528b40f6b30b------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sun, 22 Nov 2026 03:33:15 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@iamjoestack/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[How to build a custom PHP MVC Framework]]></title>
            <link>https://medium.com/@iamjoestack/how-to-build-a-custom-php-mvc-framework-e5a23da8f73d?source=rss-528b40f6b30b------2</link>
            <guid isPermaLink="false">https://medium.com/p/e5a23da8f73d</guid>
            <category><![CDATA[composerphp]]></category>
            <category><![CDATA[composer]]></category>
            <category><![CDATA[mysql]]></category>
            <category><![CDATA[mvc]]></category>
            <category><![CDATA[php]]></category>
            <dc:creator><![CDATA[Ojo Joseph Oluwaseun]]></dc:creator>
            <pubDate>Wed, 11 Jan 2023 09:26:36 GMT</pubDate>
            <atom:updated>2023-01-11T09:27:57.816Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/331/1*ltRLZKxGNaCE8pfs2p66UQ.png" /><figcaption>Model-View-Controller (MVC)</figcaption></figure><p>Have you ever considered playing around with a programming language in its core without using any framework or libraries? I had some free time during the holiday and I decided to spend a few hours playing around with just pure PHP, during this time I developed my own custom MVC framework and it is as easy as it can be.</p><p>Creating a custom Model-View-Controller (MVC) framework in PHP can be a challenging but rewarding task. MVC is a design pattern that separates an application into three main components: the model, the view, and the controller. This separation allows for better code organization and the ability to make changes to the application without affecting other parts of the code. In this post, we’ll walk through the steps of building a simple MVC framework in PHP that will help you understand the basics of MVC and how to build your own.</p><p>Step 1: Setting up the project</p><p>The first step is to create a new project directory and set up the basic file structure. We’ll need a few different directories to organize our code, such as one for controllers, one for views, and one for models. This will help keep our code organized and easy to understand. Below is an example of what the file structure might look like:</p><blockquote>my_mvc_project/<br> controllers/<br> views/<br> models/<br> index.php</blockquote><p>Step 2: Handling Requests</p><p>The next step is to handle incoming requests and route them to the appropriate controller. To do this, we’ll create an index.php file in the project root. This file will be the entry point for all incoming requests.</p><p>We’ll use the $_SERVER[&#39;REQUEST_URI&#39;] variable to determine which controller should handle the request. For example, a request to /users/index should be handled by the Users controller&#39;s index action. We&#39;ll use regular expressions to extract the controller and action from the request URI. Below is an example of how we might extract the controller and action:</p><pre>$url = $_SERVER[&#39;REQUEST_URI&#39;];<br>$controller_name = &#39;Home&#39;;<br>$action_name = &#39;index&#39;;<br><br>if (preg_match(&#39;/\/([a-z]+)/i&#39;, $url, $matches)) {<br>    $controller_name = ucfirst($matches[1]);<br>}<br><br>if (preg_match(&#39;/\/([a-z]+)/i&#39;, $url, $matches)) {<br>    $action_name = $matches[1];<br>}</pre><p>Step 3: Creating Controllers</p><p>Now that we can determine which controller should handle a request, we can create our controllers. Controllers are responsible for handling requests and updating the model. To keep our code organized, we’ll create a separate file for each controller in the controllers directory.</p><p>For example, if the request is handled by the Users controller, we&#39;ll include the controllers/Users.php file.</p><pre>$controller_file = &#39;controllers/&#39; . $controller_name . &#39;.php&#39;;<br>if (file_exists($controller_file)) {<br>    include($controller_file);<br>} else {<br>    // handle 404 error<br>}</pre><p>Step 4: Creating Views</p><p>The next step is to create the views for our application. Views are responsible for displaying the data to the user. We’ll create a separate file for each view in the views directory.</p><p>To keep our code organized, we’ll use the controller and action names to determine which view should be displayed. For example, a request to /users/index should be handled by the views/users/index.php view.</p><p>Step 5: Creating Models</p><p>Models are responsible for interacting with the database and representing the data for our application. They handle all the logic related to the data and provide an interface for the controllers to interact with the data. In this step, we will create a separate file for each model in the models directory.</p><p>To create a model, we can simply create a new PHP class and define any necessary properties and methods. For example, a User model might have properties such as id, username, and email, and methods such as get_by_id() and save().</p><p>It is important to note that models in MVC frameworks generally do not handle any logic that has to do with the presentation of data, that is the responsibility of the views. They focus mainly on data manipulation.</p><p>Once we have created the models, we can use them in our controllers to interact with the data. For example, in the Users controller&#39;s index action, we might use the User model to retrieve a list of users from the database and pass it to the view for display.</p><p>One of the core responsibilities of our model is to interact with the database and its connector.</p><p>To build a MySQL database connector in our custom MVC framework, we can create a new class that will handle all the interactions with the database. This class can be included in our models and used to interact with the database.</p><p>Here’s an example of what the Database class might look like:</p><pre>class Database {<br>    private $host = &#39;localhost&#39;;<br>    private $username = &#39;root&#39;;<br>    private $password = &#39;&#39;;<br>    private $db_name = &#39;my_mvc_project&#39;;<br>    private $conn;<br><br>    public function __construct() {<br>        $this-&gt;conn = new mysqli($this-&gt;host, $this-&gt;username, $this-&gt;password, $this-&gt;db_name);<br>        if ($this-&gt;conn-&gt;connect_error) {<br>            die(&quot;Connection failed: &quot; . $this-&gt;conn-&gt;connect_error);<br>        }<br>    }<br><br>    public function query($sql) {<br>        return $this-&gt;conn-&gt;query($sql);<br>    }<br><br>    public function close() {<br>        $this-&gt;conn-&gt;close();<br>    }<br>}</pre><p>In this example, the Database class has a private variable $conn which is an instance of the mysqli class. This is the PHP class used to interact with MySQL databases. The class constructor will establish the connection to the database using the mysqli class. It takes 4 parameters: host, username, password, and database name. In this case, we have hardcoded them in the class but they can be passed in the constructor as well if you want to make the code more flexible.</p><p>The query method is used to execute a SQL query on the database. It takes one parameter, the SQL query, and returns the result of the query. And the close method is used to close the database connection.</p><p>Now, in our models, we can include this Database class and use it to interact with the database. For example, a User model might have a method such as get_by_id() which retrieves a user from the database by their ID.</p><pre>class User {<br>    private $db;<br><br>    public function __construct() {<br>        $this-&gt;db = new Database();<br>    }<br><br>    public function get_by_id($id) {<br>        $sql = &quot;SELECT * FROM users WHERE id = $id&quot;;<br>        $result = $this-&gt;db-&gt;query($sql);<br>        return $result-&gt;fetch_assoc();<br>    }<br><br>    public function save($user) {<br>        // Prepare and execute SQL query to insert or update user data<br>    }<br><br>    public function __destruct() {<br>        $this-&gt;db-&gt;close();<br>    }<br>}</pre><p>It is important to close the database connection when it is no longer needed to prevent resource leaks. In this example, the __destruct method is used to close the connection when the object is destroyed.</p><p>As you can see, this class provides a simple way to interact with the MySQL database and can be easily incorporated into the custom MVC framework. Keep in mind that this is just an example of one way to build a database connector in a custom MVC framework, it is important that you consider security when interacting with the database, such as using prepared statements to avoid SQL injection.</p><p>Step 6: Using Composer</p><p>Using Composer is a great way to manage dependencies in a PHP project, and it’s especially useful when building a custom MVC framework. Composer is a dependency manager for PHP that allows you to easily include and manage third-party libraries and packages in your project.</p><p>Here are the steps to use Composer in our custom MVC framework:</p><p>Step A: Install Composer</p><p>To use Composer, you’ll first need to have it installed on your machine. You can download the installer from the Composer website and run it to install Composer.</p><p>Step B: Create a composer.json file</p><p>The next step is to create a composer.json file in the root of your project. This file will define the dependencies for your project.</p><p>For example, if you want to use a database library such as Doctrine ORM to interact with the database, you would add it to the require section of the composer.json file:</p><pre>{<br>    &quot;require&quot;: {<br>        &quot;doctrine/orm&quot;: &quot;^2.7&quot;<br>    }<br>}</pre><p>Step C: Install Dependencies</p><p>Once the composer.json file is created, you can run the composer install command to install the dependencies.</p><p>When you run this command, Composer will automatically download the required libraries and packages and place them in a vendor directory.</p><p>Step D: Autoload Dependencies</p><p>The final step is to autoload the dependencies so that they can be easily used throughout your project. Composer provides an autoloader, which you can include in your project.</p><pre>require &#39;vendor/autoload.php&#39;;</pre><p>Now you can use the Doctrine\ORM\EntityManager class to interact with your database.</p><p>By using Composer, you can easily manage dependencies in your project, including updating and removing them as needed. It also allows you to easily share your project with others, as they can simply run the composer install command to install all the dependencies.</p><p>It is important to note that there are other ways to use composer in a PHP project and this is just an example of one way to use it. Also, this is just an example of how to use a library in composer, it will depend on what you want to achieve, so you may have to research and decide what is the best library for your specific needs.</p><p>I hope this post helps and have a lovely day 🙂.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=e5a23da8f73d" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[What are Traits in PHP and how to use them]]></title>
            <link>https://medium.com/@iamjoestack/what-are-traits-in-php-and-how-to-use-them-9798a1a8667a?source=rss-528b40f6b30b------2</link>
            <guid isPermaLink="false">https://medium.com/p/9798a1a8667a</guid>
            <category><![CDATA[oop]]></category>
            <category><![CDATA[php-oop]]></category>
            <category><![CDATA[php]]></category>
            <category><![CDATA[traits]]></category>
            <dc:creator><![CDATA[Ojo Joseph Oluwaseun]]></dc:creator>
            <pubDate>Wed, 22 May 2019 02:05:46 GMT</pubDate>
            <atom:updated>2019-05-22T02:05:46.850Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*X_IHwtcX3cqzQRTebEeQ9Q.jpeg" /></figure><p>Before we talk about what Traits are in PHP, first let&#39;s take a look at the PHP inheritance. If you’re familiar with PHP most especially the OOP architecture then no doubt you’re fully cognizant that PHP is one of the languages out there that implement single inheritance. So in a nutshell, PHP doesn’t support multiple inheritances and that’s why a PHP programmer can only inherit a class at a time using the PHP <strong>extends</strong> keyword.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/564/1*35kQxN4tcK3VeXrFV7t5_g.png" /></figure><p>The image above simply depicts how Class B and Class C are inherited from Class A, and Class D wants to inherit from Class B and Class C. But which version of function A() is going to call when we want to run function A()? Is it from the B or is it from C? This is actually the <strong>Multiple inheritance problem</strong> and we see why PHP does not support it but there are many cases where you will want to extend to more than one classes for code reusability and to follow the DRY(Don’t repeat yourself) concept.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/687/1*fNq5ZqHZA2F7i6-icWhzMw.png" /></figure><p>In PHP one class can only inherit from one other class. The above image shows how Class D inherits from Class C, so function A() will be called from function A of Class C. What if we want to inherit from one or more class? That’s the <strong>Single inheritance problem. </strong>So how do we solve this, here comes our Hero -&gt; <strong>Traits. </strong>Traits was introduced in PHP 5.4 and it&#39;s so cool and easy to use. Traits is much more similar to a class but it is only for grouping methods in a fine-grained and consistent way. You can’t instantiate a trait like you would do a class, in fact, It is not possible to instantiate a Trait on its own. Lets quickly take a look at how we can implement traits in PHP.</p><pre>&lt;?php</pre><pre>//<strong>Mobile.php</strong></pre><pre>//First lets create a class and name it Mobile</pre><pre>class Mobile{</pre><pre>    public function battery(){</pre><pre>        echo &#39;I am battery&#39;;</pre><pre>    }</pre><pre>}</pre><p>Next, let’s create another file and call it index.php, inside this file we’ll write a class and call it Galaxy, then we’ll extend it to Mobile.</p><pre>&lt;?php</pre><pre>//index.php</pre><pre>require_once &#39;Mobile.php&#39;; //Require the Mobile.php file</pre><pre>//Galaxy class</pre><pre>class Galaxy extends Mobile{</pre><pre>}</pre><pre>$obj = new Galaxy; //Instantiate object<br>$obj-&gt;battery();</pre><p>Run index.php on the browser or through cmd/terminal using the command <em>php -a</em> then <em>php index.php</em> and you should get <strong>I am battery</strong> as an output, Cool now let&#39;s move forward.</p><p>Suppose Galaxy Mobile comes with a new feature of having a laser light. So let’s create a new file and call it <strong>Laser.php </strong>and in this file create a class and call it Laser and method called power.</p><pre>&lt;?php</pre><pre>class Laser{</pre><pre>   public function power(){</pre><pre>     echo &#39;10 mW&#39;;</pre><pre>   }</pre><pre>}</pre><p>Now, how do I use this new class of laser in my Galaxy class, normally I will extends but then I can’t extend to more than one class. Now all I have to do is convert the above class to trait using the trait keyword instead of class as in below.</p><pre>&lt;?php</pre><pre>trait Laser{</pre><pre>    public function power(){</pre><pre>      echo &#39;10 mW&#39;;</pre><pre>    }</pre><pre>}</pre><p>Now to make the methods in Laser available in our Galaxy class, we need to ensure it is available in our <em>index.php. </em>Below code shows how to implement the trait we just created</p><pre>&lt;?php</pre><pre>//index.php</pre><pre>require_once &#39;Mobile.php&#39;; //Require the Mobile.php file<br>require_once &#39;Laser.php&#39;; //Require the Laser.php file</pre><pre>//Galaxy class</pre><pre>class Galaxy extends Mobile{</pre><pre>   use Laser; //Use the trait Laser to make methods available</pre><pre>}</pre><pre>//So now I can use the power method in Trait Laser<br>$obj = new Galaxy;<br>$obj-&gt;power();</pre><pre>//As well as the methods in Mobile class<br>$obj-&gt;battery();</pre><p>So we’ve seen how easy it is to use trait, but let’s dive into more features of trait. First, we’ll create a file and call it Projector.php and give it trait Projector.</p><pre>&lt;?php</pre><pre>trait Projector{</pre><pre>  public function range(){<br>      <br>      echo &#39;2 m&#39;;<br>  }</pre><pre>}</pre><p>Now, to have more than one trait in our Galaxy class, all we have to do is separate them with a comma (,).</p><pre>require_once &#39;Mobile.php&#39;; //Require the Mobile.php file<br>require_once &#39;Laser.php&#39;; //Require the Laser.php file<br>require_once &#39;Projector.php&#39;; //Require the Laser.php file</pre><pre>//Galaxy class</pre><pre>class Galaxy extends Mobile{</pre><pre>use Laser, Projector;</pre><pre>}</pre><pre>//So now I can use the power method in Trait Laser<br>$obj = new Galaxy;<br>$obj-&gt;power();</pre><pre>//So now I can use the range method in Trait Projector<br>$obj-&gt;range();</pre><pre>//As well as the methods in Mobile class<br>$obj-&gt;battery();</pre><p>This is cool but what if we have a method in Projector trait called power and remember that we already have a method named power in our trait Laser, this will apparently confuse PHP and your program will get the fatal error <strong>‘Trait method power cannot be applied because there is a collision…’</strong></p><pre>trait Projector{</pre><pre>    public function range(){<br>      echo &#39;2 m&#39;;<br>    }</pre><pre>    public function power(){<br>      echo &#39;I am the power of Projector&#39;;<br>    }</pre><pre>}</pre><p>All we have to do to eradicate this problem is to specify which to use using the <strong><em>insteadof</em></strong> keyword.</p><pre>&lt;?php</pre><pre>require_once &#39;Mobile.php&#39;; //Require the Mobile.php file<br>require_once &#39;Laser.php&#39;; //Require the Laser.php file<br>require_once &#39;Projector.php&#39;; //Require the Laser.php file</pre><pre>//Galaxy class</pre><pre>class Galaxy extends Mobile{</pre><pre>use Laser, Projector{<br> <br>   Laser::power insteadof Projector;</pre><pre>}</pre><pre>}</pre><pre>//So now I can use the power method in Trait Laser<br>$obj = new Galaxy;<br>$obj-&gt;power();</pre><pre>//So now I can use the range method in Trait Projector<br>$obj-&gt;range();</pre><pre>//As well as the methods in Mobile class<br>$obj-&gt;battery();</pre><p>The above code solves the multiple trait methods collision but then what if we still need to use the <strong>power </strong>method inside <strong>Projector </strong>what do we do? this is quite simple as well, all we need to do is call the method but assign it to another name as seen below:</p><pre>&lt;?php</pre><pre>class Galaxy extends Mobile{</pre><pre>use Laser, Projector{<br> <br>   Laser::power insteadof Projector;<br>   Projector::power as Ppower; //this does the trick</pre><pre>}</pre><pre>}</pre><pre>//So now I can use the two power method in Trait Laser and Projector respectively but I will use the other as Ppower</pre><pre>$obj = new Galaxy;<br>$obj-&gt;power();</pre><pre>$obj-&gt;Ppower(); //Power method in Projector</pre><p>I’m sure you can now see how flexible and easy it is to use trait, there are other cool features of trait but this is what you need to get started. Let me know your thoughts in the comment section below, Have a lovely day.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=9798a1a8667a" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Understanding Polymorphism in PHP]]></title>
            <link>https://medium.com/@iamjoestack/understanding-polymorphism-in-php-3d2670deb6e1?source=rss-528b40f6b30b------2</link>
            <guid isPermaLink="false">https://medium.com/p/3d2670deb6e1</guid>
            <category><![CDATA[oop]]></category>
            <category><![CDATA[polymorphism]]></category>
            <category><![CDATA[php]]></category>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[php-developers]]></category>
            <dc:creator><![CDATA[Ojo Joseph Oluwaseun]]></dc:creator>
            <pubDate>Thu, 04 Apr 2019 21:20:28 GMT</pubDate>
            <atom:updated>2019-04-04T21:27:47.546Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/450/1*TwwXgBndT4fGFwnxRf_Qfg.jpeg" /></figure><p>When it comes to Object Oriented Programming, Polymorphism is indeed a wonderful and powerful tool you need to get fully acquainted with but if you’re relatively new to OOP, the word Polymorphism alone might scare you a little bit but the truth is Polymorphism is just a long word for a very simple concept and I strongly believe you will grab how it works after the end of this minimal tutorial as this tutorial will describe the general concept of polymorphism, and how you can easily apply it in PHP. Enough of the talk, <strong><em>what is Polymorphism?</em></strong></p><p><strong>First, it is derived from the Greek words Poly (meaning many) and morph (meaning forms)</strong></p><p><strong>Polymorphism is simply an OOP design pattern that allows multiple class with various functionalities to implement or share a common Interface.</strong></p><p>The aesthetic of polymorphism is that the code working with the different classes does not need to know which class it is using since they’re all used the same way.</p><p>Polymorphism in PHP is implemented using the <strong>interface </strong>pattern<strong><em>. </em></strong>Think about interface as the skeleton or blueprint for your class which implements it.</p><pre>interface shapesInterface{<br> <br>}</pre><p>The above code has an interface named shapesInterface.</p><p>An interface is similar to a class except that it cannot contain code but only method declaration and this declaration can only work with the <strong>public </strong>scope as seen below:</p><pre>interface shapesInterface{<br>    public function getArea();<br>}</pre><p>An interface can define method names and arguments, but not the contents of the methods. Any class implementing an interface <strong>must implement</strong> all methods defined by the interface. Below are the main points of Interface:</p><ol><li>An interface is defined to provide a common function name to the implementer classes.</li><li>Different implementing classes can implement those interfaces according to their requirements.</li><li>You can say, interfaces are skeletons which are implemented by developers.</li></ol><pre>// Below is an example of what point 1 denotes:</pre><pre>class Rectangle implements shapesInterface{</pre><pre>  public function getArea(){</pre><pre>    return &quot;Rectangle Area&quot;;</pre><pre>  }</pre><pre>}</pre><p>As we can see from the example above class Rectangle is implementing the shapesInterface we created earlier and it has the same common method name as the shapesInterface (getArea) except that the interface method has no code in it.</p><pre>//First things first, define the interface</pre><pre>interface shapesInterface{</pre><pre>    //First method</pre><pre>    public function getArea();</pre><pre>   //Second method<br>    <br>    public function totalWidthSize();</pre><pre>}</pre><pre>/*<br>|Now that we&#39;ve created our interface, Take a good look at the differences between the two classes below<br>*/</pre><pre>//Invalid and will output a fatal error<br>class Rectangle implements shapesInterface{</pre><pre>   public function getArea(){</pre><pre>   }</pre><pre>}</pre><pre>//Valid and will work just fine<br>class Rectangle implements shapesInterface{</pre><pre>public function getArea(){</pre><pre>}</pre><pre>public function totalWidthSize(){</pre><pre>}</pre><pre>}</pre><p>When implementing an interface, a class must call all methods in the interface it&#39;s implementing as seen above, when the first class implementation is rendered, a fatal error will occur because it&#39;s not implementing all the methods in shapesInterface.</p><p><strong>2. Different implementing classes can implement those interfaces according to their requirements.</strong></p><pre>class Polygon implements shapesInterface{</pre><pre>public function getArea(){</pre><pre>return &quot;Polygon Area&quot;;</pre><pre>}</pre><pre>public function totalWidthSize(){</pre><pre>return &quot;Total width Size&quot;;</pre><pre>}</pre><pre>}</pre><p>As seen above, while Rectangle is implementing shapesInterface, other classes can as well do the same as the Polygon class above but they all have to follow the interface architecture.</p><p>Another instance where Polymorphism can prove really helpful in PHP is when you protect a function by passing in a class name while passing an object. Let us take a look at the example below:</p><pre>/*<br>|Create a function that lets you calculate the area of a rectangle Using the Rectangle class above</pre><pre>|Using the class name Rectangle will only allow class Rectangle object to be passed which is really a security measure so nobody passes any unwanted class object into the function<br>*/</pre><pre>function calculateRectangle(Rectangle $object){</pre><pre>   // return $object-&gt;getArea();</pre><pre>}</pre><p>The example above is just a regular thing in OOP, but what if we want other classes aside from Rectangle to be passed as a parameter to our function calculateRectangle above, all we have to do is wrap them all in an interface and just call the interface name as seen below:</p><pre>//PHP will clearly understand that this is an interface and we want only the class in this interface to be passed into this method below</pre><pre>function calculateRectangle(shapesInterface$object){</pre><pre>// return $object-&gt;getArea();</pre><pre>}</pre><p>In conclusion, Polymorphism describes a pattern in Object Oriented Programming in which a class has varying functionality while sharing a common interfaces.</p><p>I hope you now understand what Polymorphism is and how you can apply it in PHP. Have a nice day!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=3d2670deb6e1" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Understanding DevOps the simple way]]></title>
            <link>https://medium.com/@iamjoestack/understanding-devops-the-simple-way-ee615842d769?source=rss-528b40f6b30b------2</link>
            <guid isPermaLink="false">https://medium.com/p/ee615842d769</guid>
            <category><![CDATA[software-testing]]></category>
            <category><![CDATA[agile-development]]></category>
            <category><![CDATA[software-development]]></category>
            <category><![CDATA[software-engineering]]></category>
            <category><![CDATA[devops]]></category>
            <dc:creator><![CDATA[Ojo Joseph Oluwaseun]]></dc:creator>
            <pubDate>Sat, 30 Mar 2019 12:35:29 GMT</pubDate>
            <atom:updated>2019-03-30T12:35:29.524Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/512/1*Ky-y8HyrkkjMqGlnsxDguw.png" /><figcaption>The DevOps Tool Chain</figcaption></figure><p>This present quick moving world makes DevOps fundamental for any business trying to be deft and lean, so as to react quickly to changing client and commercial center requests. Truth be told, understanding DevOps might a bit difficult as it requires much effort to in understanding it full concept. But with this piece, I believe you should understand DevOps.</p><p>First, <strong>What is DevOps</strong>?</p><p>DevOps is simply a software development practice (the term software development practices simply mean the set of rules the software development community has learned over time which can help improve the quality of software and its customer experience). The term DevOps is a portmanteau of two words which is <strong>Development </strong>and <strong>Operations, </strong>now take a look at DevOps as the life cycle of software ranging from its Development and its Operations.</p><p>“Dev” is utilized as shorthand for engineers specifically, however truly by and by it is even more extensive and signifies “every one of the general population engaged with building up the product,” which can incorporate the Product planning, QA, etc.</p><p>“Ops” on the other hand is a term for systems engineers, system administrators, operations staff, release engineers, DBAs, network engineers, security professionals, and various other subdisciplines and job titles.</p><p>Simply view the “Dev” side as the “makers” and the “Ops” side being the “people that deal with the creation after its birth”. DevOps is simply extending the quick and easy principles of software development beyond the boundaries of “the code” to the entire delivered service.</p><p>The ultimate goal of DevOps is to streamline development. DevOps doesn’t necessarily require tools and is not defined by its tools, but for most organizations, they play an integral role in automating tasks and ensuring processes run as efficiently as possible. When used together, a combination of DevOps tools forms a DevOps toolchain, which enables teams to flow smoothly through the DevOps life cycle.</p><p>While the integration of DevOps is by no means ubiquitous, we’re witnessing its growing presence in the mainstream IT world.</p><p><strong>DevOps Toolchain</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/797/1*glTeJAj8emo5gsAZ2qI3PQ.png" /></figure><p>From the image above, we can see the seven(7) steps of DevOps ranging from <strong>Planning to Monitoring.</strong></p><p><strong>Plan</strong>: Planning in DevOps basically compose two things, Defining your project and planning it in depth. This aspect alludes to business esteem and application necessities.</p><p><strong>Create/Code: </strong>Create is composed of the building and coding of the software development process.</p><p><strong>Verify: </strong>Verify is directly associated with ensuring the quality of the software development. This includes detailed performance test to ensure the software is fully ready.</p><p><strong>Package/Preprod.: </strong>Packaging refers to the activities involved once the release is ready for deployment, often also referred to as staging or Preproduction / “preprod”.</p><p><strong>Release: </strong>Release includes the software’s schedule, provisioning and deploying it into production and preferred environment.</p><p><strong>Configure: </strong>Configure fall under the (Ops)operation side of DevOps. Once the software is deployed, there may be a need for additional IT infrastructure provisioning and configuration which are required.</p><p><strong>Monitor: </strong>Monitoring is an important link in a DevOps toolchain according to <strong><em>Wikipedia,</em></strong> It allows IT organization to identify specific issues of specific releases and to understand the impact on end-users.</p><p><strong>Conclusion:</strong></p><p>Since the DevOps toolchain portrays a life cycle, there is a chance that after the software has been released, configured, while monitoring needed changes might occur either through feedbacks from end users, security threats, etc. How do you make these changes? Information from the monitoring aspect of DevOps often impacts Plan activities required for changes and for the new release cycle, so the team needs to follow the DevOps cycle again from its Planning to Monitoring.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=ee615842d769" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>