mirror of
https://github.com/codeigniter4/CodeIgniter4.git
synced 2025-02-20 11:44:28 +08:00
Update User Guide
This commit is contained in:
parent
8790df701c
commit
3f90327a08
@ -307,6 +307,9 @@ representation of some of the bigger changes you should know about.</p>
|
||||
<li><p>Lots of tweaks and corrections in the user guide.</p></li>
|
||||
<li><p>Fixed locating files in custom namespaces that were occassionally not found. Primarily affected console commands.</p></li>
|
||||
</ul>
|
||||
<p>See the repo’s
|
||||
<a class="reference external" href="https://github.com/codeigniter4/CodeIgniter4/blob/develop/changelogs/CHANGELOG_4.0.md">CHANGELOG_4.0.md</a>
|
||||
for a complete list of bugs fixed.</p>
|
||||
</section>
|
||||
</section>
|
||||
|
||||
|
@ -344,6 +344,9 @@
|
||||
<li><p>Fix <code class="docutils literal notranslate"><span class="pre">is_unique</span></code>/<code class="docutils literal notranslate"><span class="pre">is_not_unique</span></code> validation called on POST/PUT via API in PostgreSQL.</p></li>
|
||||
<li><p>Fixed a bug where filter arguments were not passed to <code class="docutils literal notranslate"><span class="pre">after()</span></code>.</p></li>
|
||||
</ul>
|
||||
<p>See the repo’s
|
||||
<a class="reference external" href="https://github.com/codeigniter4/CodeIgniter4/blob/develop/changelogs/CHANGELOG_4.0.md">CHANGELOG_4.0.md</a>
|
||||
for a complete list of bugs fixed.</p>
|
||||
</section>
|
||||
</section>
|
||||
|
||||
|
@ -282,8 +282,8 @@
|
||||
<ul class="simple">
|
||||
<li><p><a class="reference internal" href="#enhancements" id="id1">Enhancements</a></p></li>
|
||||
<li><p><a class="reference internal" href="#changes" id="id2">Changes</a></p></li>
|
||||
<li><p><a class="reference internal" href="#bugs-fixed" id="id3">Bugs Fixed</a></p></li>
|
||||
<li><p><a class="reference internal" href="#deprecations" id="id4">Deprecations</a></p></li>
|
||||
<li><p><a class="reference internal" href="#deprecations" id="id3">Deprecations</a></p></li>
|
||||
<li><p><a class="reference internal" href="#bugs-fixed" id="id4">Bugs Fixed</a></p></li>
|
||||
</ul>
|
||||
</div>
|
||||
<section id="enhancements">
|
||||
@ -305,16 +305,8 @@
|
||||
<li><p>System messages defined in <strong>system/Language/en/</strong> are now strictly for internal framework use and are not covered by backwards compatibility (BC) promise. Users may use these messages in their applications but at their own risks.</p></li>
|
||||
</ul>
|
||||
</section>
|
||||
<section id="bugs-fixed">
|
||||
<h2><a class="toc-backref" href="#id3">Bugs Fixed</a><a class="headerlink" href="#bugs-fixed" title="Permalink to this headline"></a></h2>
|
||||
<ul class="simple">
|
||||
<li><p>Fixed a bug in <code class="docutils literal notranslate"><span class="pre">Entity</span></code> class where declaring class parameters was preventing data propagation to the <code class="docutils literal notranslate"><span class="pre">attributes</span></code> array.</p></li>
|
||||
<li><p>Handling for the environment variable <code class="docutils literal notranslate"><span class="pre">encryption.key</span></code> has changed. Previously, explicit function calls, like <code class="docutils literal notranslate"><span class="pre">getenv('encryption.key')</span></code> or <code class="docutils literal notranslate"><span class="pre">env('encryption.key')</span></code> where the value has the special prefix <code class="docutils literal notranslate"><span class="pre">hex2bin:</span></code> returns an automatically converted binary string. This is now changed to just return the character string with the prefix. This change was due to incompatibility with handling binary strings in environment variables on Windows platforms. However, accessing <code class="docutils literal notranslate"><span class="pre">$key</span></code> using <code class="docutils literal notranslate"><span class="pre">Encryption</span></code> class config remains unchanged and still returns a binary string.</p></li>
|
||||
<li><p><code class="docutils literal notranslate"><span class="pre">Config\Services</span></code> (in <strong>app/Config/Services.php</strong>) now extends <code class="docutils literal notranslate"><span class="pre">CodeIgniter\Config\BaseService</span></code> to allow proper discovery of third-party services.</p></li>
|
||||
</ul>
|
||||
</section>
|
||||
<section id="deprecations">
|
||||
<h2><a class="toc-backref" href="#id4">Deprecations</a><a class="headerlink" href="#deprecations" title="Permalink to this headline"></a></h2>
|
||||
<h2><a class="toc-backref" href="#id3">Deprecations</a><a class="headerlink" href="#deprecations" title="Permalink to this headline"></a></h2>
|
||||
<ul class="simple">
|
||||
<li><p>Deprecated <code class="docutils literal notranslate"><span class="pre">BaseCommand::getPad()</span></code> in favor of <code class="docutils literal notranslate"><span class="pre">BaseCommand::setPad()</span></code>.</p></li>
|
||||
<li><p>Deprecated <code class="docutils literal notranslate"><span class="pre">CodeIgniter\Controller::loadHelpers()</span></code> in favor of <code class="docutils literal notranslate"><span class="pre">helper()</span></code> function.</p></li>
|
||||
@ -337,6 +329,17 @@
|
||||
<li><p>Deprecated <code class="docutils literal notranslate"><span class="pre">Config\Cache::$storePath</span></code> in favor of <code class="docutils literal notranslate"><span class="pre">Config\Cache::$file['storePath']</span></code></p></li>
|
||||
</ul>
|
||||
</section>
|
||||
<section id="bugs-fixed">
|
||||
<h2><a class="toc-backref" href="#id4">Bugs Fixed</a><a class="headerlink" href="#bugs-fixed" title="Permalink to this headline"></a></h2>
|
||||
<ul class="simple">
|
||||
<li><p>Fixed a bug in <code class="docutils literal notranslate"><span class="pre">Entity</span></code> class where declaring class parameters was preventing data propagation to the <code class="docutils literal notranslate"><span class="pre">attributes</span></code> array.</p></li>
|
||||
<li><p>Handling for the environment variable <code class="docutils literal notranslate"><span class="pre">encryption.key</span></code> has changed. Previously, explicit function calls, like <code class="docutils literal notranslate"><span class="pre">getenv('encryption.key')</span></code> or <code class="docutils literal notranslate"><span class="pre">env('encryption.key')</span></code> where the value has the special prefix <code class="docutils literal notranslate"><span class="pre">hex2bin:</span></code> returns an automatically converted binary string. This is now changed to just return the character string with the prefix. This change was due to incompatibility with handling binary strings in environment variables on Windows platforms. However, accessing <code class="docutils literal notranslate"><span class="pre">$key</span></code> using <code class="docutils literal notranslate"><span class="pre">Encryption</span></code> class config remains unchanged and still returns a binary string.</p></li>
|
||||
<li><p><code class="docutils literal notranslate"><span class="pre">Config\Services</span></code> (in <strong>app/Config/Services.php</strong>) now extends <code class="docutils literal notranslate"><span class="pre">CodeIgniter\Config\BaseService</span></code> to allow proper discovery of third-party services.</p></li>
|
||||
</ul>
|
||||
<p>See the repo’s
|
||||
<a class="reference external" href="https://github.com/codeigniter4/CodeIgniter4/blob/develop/changelogs/CHANGELOG_4.0.md">CHANGELOG_4.0.md</a>
|
||||
for a complete list of bugs fixed.</p>
|
||||
</section>
|
||||
</section>
|
||||
|
||||
|
||||
|
@ -283,6 +283,7 @@
|
||||
<li><p><a class="reference internal" href="#breaking" id="id1">BREAKING</a></p></li>
|
||||
<li><p><a class="reference internal" href="#changes" id="id2">Changes</a></p></li>
|
||||
<li><p><a class="reference internal" href="#deprecations" id="id3">Deprecations</a></p></li>
|
||||
<li><p><a class="reference internal" href="#bugs-fixed" id="id4">Bugs Fixed</a></p></li>
|
||||
</ul>
|
||||
</div>
|
||||
<section id="breaking">
|
||||
@ -303,6 +304,12 @@
|
||||
<li><p>Deprecated <code class="docutils literal notranslate"><span class="pre">Model::fillPlaceholders()</span></code> method, use <code class="docutils literal notranslate"><span class="pre">Validation::fillPlaceholders()</span></code> instead.</p></li>
|
||||
</ul>
|
||||
</section>
|
||||
<section id="bugs-fixed">
|
||||
<h2><a class="toc-backref" href="#id4">Bugs Fixed</a><a class="headerlink" href="#bugs-fixed" title="Permalink to this headline"></a></h2>
|
||||
<p>See the repo’s
|
||||
<a class="reference external" href="https://github.com/codeigniter4/CodeIgniter4/blob/develop/changelogs/CHANGELOG_4.1.md">CHANGELOG_4.1.md</a>
|
||||
for a complete list of bugs fixed.</p>
|
||||
</section>
|
||||
</section>
|
||||
|
||||
|
||||
|
@ -289,6 +289,9 @@
|
||||
<li><p>Fixed an issue where <code class="docutils literal notranslate"><span class="pre">.gitattributes</span></code> was preventing framework downloads.</p></li>
|
||||
</ul>
|
||||
<p>Note that this fix was also applied retroactively to <code class="docutils literal notranslate"><span class="pre">4.0.5</span></code> on the <strong>framework</strong> repo.</p>
|
||||
<p>See the repo’s
|
||||
<a class="reference external" href="https://github.com/codeigniter4/CodeIgniter4/blob/develop/changelogs/CHANGELOG_4.1.md">CHANGELOG_4.1.md</a>
|
||||
for a complete list of bugs fixed.</p>
|
||||
</section>
|
||||
</section>
|
||||
|
||||
|
@ -343,10 +343,12 @@ using <code class="docutils literal notranslate"><span class="pre">App::$indexPa
|
||||
</section>
|
||||
<section id="bugs-fixed">
|
||||
<h2><a class="toc-backref" href="#id5">Bugs Fixed</a><a class="headerlink" href="#bugs-fixed" title="Permalink to this headline"></a></h2>
|
||||
<p>See the repo’s <a class="reference external" href="https://github.com/codeigniter4/CodeIgniter4/blob/develop/CHANGELOG.md">CHANGELOG.md</a> for a complete list of bugs fixed.</p>
|
||||
<ul class="simple">
|
||||
<li><p><code class="docutils literal notranslate"><span class="pre">BaseConnection::query()</span></code> now returns <code class="docutils literal notranslate"><span class="pre">false</span></code> for failed queries (unless <code class="docutils literal notranslate"><span class="pre">DBDebug==true</span></code>, in which case an exception will be thrown) and returns boolean values for write-type queries as specified in the docs.</p></li>
|
||||
</ul>
|
||||
<p>See the repo’s
|
||||
<a class="reference external" href="https://github.com/codeigniter4/CodeIgniter4/blob/develop/changelogs/CHANGELOG_4.1.md">CHANGELOG_4.1.md</a>
|
||||
for a complete list of bugs fixed.</p>
|
||||
</section>
|
||||
</section>
|
||||
|
||||
|
@ -309,6 +309,9 @@
|
||||
<li><p>Fixed a logic bug in Cookie construction</p></li>
|
||||
<li><p>Fixed numerous issues in SQLite3’s <code class="docutils literal notranslate"><span class="pre">Forge</span></code> class related to an incorrect attribute name</p></li>
|
||||
</ul>
|
||||
<p>See the repo’s
|
||||
<a class="reference external" href="https://github.com/codeigniter4/CodeIgniter4/blob/develop/changelogs/CHANGELOG_4.1.md">CHANGELOG_4.1.md</a>
|
||||
for a complete list of bugs fixed.</p>
|
||||
</section>
|
||||
</section>
|
||||
|
||||
|
@ -280,13 +280,13 @@
|
||||
<p><strong>4.1.4 release of CodeIgniter4</strong></p>
|
||||
<div class="contents local topic" id="contents">
|
||||
<ul class="simple">
|
||||
<li><p><a class="reference internal" href="#breaking-changes" id="id1">Breaking Changes</a></p></li>
|
||||
<li><p><a class="reference internal" href="#breaking" id="id1">BREAKING</a></p></li>
|
||||
</ul>
|
||||
</div>
|
||||
<p>This release focuses on code style. All changes (except those noted below) are cosmetic to bring the code in line with the new
|
||||
<a class="reference external" href="https://github.com/CodeIgniter/coding-standard">CodeIgniter Coding Standard</a> (based on PSR-12).</p>
|
||||
<section id="breaking-changes">
|
||||
<h2><a class="toc-backref" href="#id1">Breaking Changes</a><a class="headerlink" href="#breaking-changes" title="Permalink to this headline"></a></h2>
|
||||
<section id="breaking">
|
||||
<h2><a class="toc-backref" href="#id1">BREAKING</a><a class="headerlink" href="#breaking" title="Permalink to this headline"></a></h2>
|
||||
<ul>
|
||||
<li><p>The following methods were changed from “public” to “protected” to match their parent class methods and better align with their uses:</p>
|
||||
<blockquote>
|
||||
@ -341,6 +341,9 @@
|
||||
</div></blockquote>
|
||||
</li>
|
||||
</ul>
|
||||
<p>See the repo’s
|
||||
<a class="reference external" href="https://github.com/codeigniter4/CodeIgniter4/blob/develop/changelogs/CHANGELOG_4.1.md">CHANGELOG_4.1.md</a>
|
||||
for a complete list of changes.</p>
|
||||
</section>
|
||||
</section>
|
||||
|
||||
|
@ -331,7 +331,9 @@
|
||||
</section>
|
||||
<section id="bugs-fixed">
|
||||
<h2><a class="toc-backref" href="#id5">Bugs Fixed</a><a class="headerlink" href="#bugs-fixed" title="Permalink to this headline"></a></h2>
|
||||
<p>See the repo’s <a class="reference external" href="https://github.com/codeigniter4/CodeIgniter4/blob/develop/CHANGELOG.md">CHANGELOG.md</a> for a complete list of bugs fixed.</p>
|
||||
<p>See the repo’s
|
||||
<a class="reference external" href="https://github.com/codeigniter4/CodeIgniter4/blob/develop/changelogs/CHANGELOG_4.1.md">CHANGELOG_4.1.md</a>
|
||||
for a complete list of bugs fixed.</p>
|
||||
</section>
|
||||
</section>
|
||||
|
||||
|
@ -358,7 +358,9 @@ And the following methods are deprecated:</p>
|
||||
</section>
|
||||
<section id="bugs-fixed">
|
||||
<h2><a class="toc-backref" href="#id8">Bugs Fixed</a><a class="headerlink" href="#bugs-fixed" title="Permalink to this headline"></a></h2>
|
||||
<p>See the repo’s <a class="reference external" href="https://github.com/codeigniter4/CodeIgniter4/blob/develop/CHANGELOG.md">CHANGELOG.md</a> for a complete list of bugs fixed.</p>
|
||||
<p>See the repo’s
|
||||
<a class="reference external" href="https://github.com/codeigniter4/CodeIgniter4/blob/develop/changelogs/CHANGELOG_4.1.md">CHANGELOG_4.1.md</a>
|
||||
for a complete list of bugs fixed.</p>
|
||||
</section>
|
||||
</section>
|
||||
|
||||
|
@ -307,7 +307,9 @@
|
||||
</section>
|
||||
<section id="bugs-fixed">
|
||||
<h2><a class="toc-backref" href="#id5">Bugs Fixed</a><a class="headerlink" href="#bugs-fixed" title="Permalink to this headline"></a></h2>
|
||||
<p>See the repo’s <a class="reference external" href="https://github.com/codeigniter4/CodeIgniter4/blob/develop/CHANGELOG.md">CHANGELOG.md</a> for a complete list of bugs fixed.</p>
|
||||
<p>See the repo’s
|
||||
<a class="reference external" href="https://github.com/codeigniter4/CodeIgniter4/blob/develop/changelogs/CHANGELOG_4.1.md">CHANGELOG_4.1.md</a>
|
||||
for a complete list of bugs fixed.</p>
|
||||
</section>
|
||||
</section>
|
||||
|
||||
|
@ -498,7 +498,7 @@ that wish to use them. The tools primarily provide access to the same methods th
|
||||
<li><p><code class="docutils literal notranslate"><span class="pre">--all</span></code> - to migrate all namespaces to the latest migration</p></li>
|
||||
</ul>
|
||||
<p>This example will migrate <code class="docutils literal notranslate"><span class="pre">Acme\Blog</span></code> namespace with any new migrations on the test database group:</p>
|
||||
<div class="highlight-html+php notranslate"><div class="highlight"><pre><span></span><span class="o">></span> <span class="nx">php</span> <span class="nx">spark</span> <span class="nx">migrate</span> <span class="o">-</span><span class="nx">g</span> <span class="nx">test</span> <span class="o">-</span><span class="nx">n</span> <span class="s1">'Acme\Blog'</span>
|
||||
<div class="highlight-html+php notranslate"><div class="highlight"><pre><span></span><span class="o">></span> <span class="nx">php</span> <span class="nx">spark</span> <span class="nx">migrate</span> <span class="o">-</span><span class="nx">g</span> <span class="nx">test</span> <span class="o">-</span><span class="nx">n</span> <span class="nx">Acme\\Blog</span>
|
||||
</pre></div>
|
||||
</div>
|
||||
<p>When using the <code class="docutils literal notranslate"><span class="pre">--all</span></code> option, it will scan through all namespaces attempting to find any migrations that have
|
||||
|
@ -372,7 +372,7 @@ a dedicated controller:</p>
|
||||
</pre></div>
|
||||
</div>
|
||||
<p>You can supply the <strong>root</strong> namespace where the seed file will be stored by supplying the <code class="docutils literal notranslate"><span class="pre">--namespace</span></code> option:</p>
|
||||
<div class="highlight-html+php notranslate"><div class="highlight"><pre><span></span><span class="o">></span> <span class="nx">php</span> <span class="nx">spark</span> <span class="nx">make</span><span class="o">:</span><span class="nx">seeder</span> <span class="nx">MySeeder</span> <span class="o">--</span><span class="k">namespace</span> <span class="nx">Acme\Blog</span>
|
||||
<div class="highlight-html+php notranslate"><div class="highlight"><pre><span></span><span class="o">></span> <span class="nx">php</span> <span class="nx">spark</span> <span class="nx">make</span><span class="o">:</span><span class="nx">seeder</span> <span class="nx">MySeeder</span> <span class="o">--</span><span class="k">namespace</span> <span class="nx">Acme\\Blog</span>
|
||||
</pre></div>
|
||||
</div>
|
||||
<p>If <code class="docutils literal notranslate"><span class="pre">Acme\Blog</span></code> is mapped to <code class="docutils literal notranslate"><span class="pre">app/Blog</span></code> directory, then this command will generate <code class="docutils literal notranslate"><span class="pre">MySeeder.php</span></code> at <code class="docutils literal notranslate"><span class="pre">app/Blog/Database/Seeds</span></code> directory.</p>
|
||||
|
File diff suppressed because one or more lines are too long
Loading…
x
Reference in New Issue
Block a user