Skip to content

Commit

Permalink
Merge branch 'develop' of github.com:/EllisLab/CodeIgniter into hmvc
Browse files Browse the repository at this point in the history
  • Loading branch information
dchill42 committed Sep 7, 2011
2 parents c45070b + 32020e6 commit 36ce7e4
Show file tree
Hide file tree
Showing 6 changed files with 9 additions and 11 deletions.
2 changes: 1 addition & 1 deletion system/database/DB_active_rec.php
Expand Up @@ -826,7 +826,7 @@ public function limit($value, $offset = '')
*/
public function offset($offset)
{
$this->ar_offset = $offset;
$this->ar_offset = (int) $offset;
return $this;
}

Expand Down
9 changes: 3 additions & 6 deletions system/helpers/string_helper.php
Expand Up @@ -215,12 +215,9 @@ function random_string($type = 'alnum', $len = 8)
case 'nozero' : $pool = '123456789';
break;
}

$str = '';
for ($i=0; $i < $len; $i++)
{
$str .= substr($pool, mt_rand(0, strlen($pool) -1), 1);
}

$str = substr(str_shuffle(str_repeat($pool, ceil($len/strlen($pool)))),0,$len);

return $str;
break;
case 'unique' :
Expand Down
2 changes: 1 addition & 1 deletion system/language/english/migration_lang.php
Expand Up @@ -5,7 +5,7 @@
$lang['migration_multiple_version'] = "This are multiple migrations with the same version number: %d.";
$lang['migration_class_doesnt_exist'] = "The migration class \"%s\" could not be found.";
$lang['migration_missing_up_method'] = "The migration class \"%s\" is missing an 'up' method.";
$lang['migration_missing_down_method'] = "The migration class \"%s\" is missing an 'up' method.";
$lang['migration_missing_down_method'] = "The migration class \"%s\" is missing a 'down' method.";
$lang['migration_invalid_filename'] = "Migration \"%s\" has an invalid filename.";


Expand Down
1 change: 1 addition & 0 deletions user_guide/changelog.html
Expand Up @@ -77,6 +77,7 @@ <h2>Version 2.1.0 (planned)</h2>
<li>Added <samp>increment_string()</samp> to <a href="helpers/string_helper.html">String Helper</a> to turn "foo" into "foo-1" or "foo-1" into "foo-2".</li>
<li>Altered form helper - made action on form_open_multipart helper function call optional. Fixes (#65)</li>
<li><samp>url_title()</samp> will now trim extra dashes from beginning and end.</li>
<li>Improved speed of <a href="helpers/string_helper.html">String Helper</a>'s <b>random_string()</b> method</li>
</ul>
</li>
<li>Database
Expand Down
4 changes: 2 additions & 2 deletions user_guide/database/results.html
Expand Up @@ -105,8 +105,8 @@ <h2>result()</h2>
<br />
foreach ($query->result('User') as $user)<br />
{<br />
&nbsp;&nbsp;&nbsp;echo $row->name; // call attributes<br />
&nbsp;&nbsp;&nbsp;echo $row->reverse_name(); // or methods defined on the 'User' class<br />
&nbsp;&nbsp;&nbsp;echo $user->name; // call attributes<br />
&nbsp;&nbsp;&nbsp;echo $user->reverse_name(); // or methods defined on the 'User' class<br />
}
</code>

Expand Down
2 changes: 1 addition & 1 deletion user_guide/general/cli.html
Expand Up @@ -83,7 +83,7 @@ <h2>Why run via the command-line?</h2>

<ul>
<li>Run your cron-jobs without needing to use wget or curl</li>
<li>Make your cron-jobs inaccessible from being loaded in the URL by checking for <kbd>IS_CLI</kbd></li>
<li>Make your cron-jobs inaccessible from being loaded in the URL by checking for <kbd>$this->input->is_cli_request()</kbd></li>
<li>Make interactive "tasks" that can do things like set permissions, prune cache folders, run backups, etc.</li>
<li>Integrate with other applications in other languages. For example, a random C++ script could call one command and run code in your models!</li>
</ul>
Expand Down

0 comments on commit 36ce7e4

Please sign in to comment.