<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Rami Gamal</title>
    <description>The latest articles on DEV Community by Rami Gamal (@ramigaml84).</description>
    <link>https://dev.to/ramigaml84</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F433329%2Fc2f5ec41-98d7-4374-8085-423f8bfabb56.jpg</url>
      <title>DEV Community: Rami Gamal</title>
      <link>https://dev.to/ramigaml84</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/ramigaml84"/>
    <language>en</language>
    <item>
      <title>Where to put the business logic ?</title>
      <dc:creator>Rami Gamal</dc:creator>
      <pubDate>Mon, 24 Aug 2020 23:26:20 +0000</pubDate>
      <link>https://dev.to/ramigaml84/where-to-put-the-business-logic-1e9o</link>
      <guid>https://dev.to/ramigaml84/where-to-put-the-business-logic-1e9o</guid>
      <description>&lt;p&gt;I am writing a web application using PHP without using any framework 'just for learning'.&lt;br&gt;
My app consists of a small routing system, MVC components, some entities that represents the database tables and  repository classes that deals with the database.&lt;br&gt;
The controller crate a repository object and that object load its entities from the database then return it as an array to the controller and the controller render the data.&lt;br&gt;
What is the right place to put the domain or business logic,&lt;br&gt;
in the models or repositories&lt;/p&gt;

&lt;p&gt;View &amp;gt; Controller &amp;gt; Model &amp;gt; Repository &amp;gt; Database&lt;br&gt;
View &amp;lt; Controller &amp;lt; Model &amp;lt; Repository &amp;lt; Database&lt;/p&gt;

</description>
      <category>php</category>
      <category>mvc</category>
      <category>businesslogic</category>
    </item>
  </channel>
</rss>
