32
1
mirror of https://github.com/joomla-extensions/weblinks.git synced 2024-12-25 17:51:07 +00:00

Merge pull request #174 from alikon/patch-3

PHP 7 error when save a weblink
This commit is contained in:
George Wilson 2015-12-06 15:15:52 +00:00
commit 6cd0429107
2 changed files with 3 additions and 6 deletions

View File

@ -10,7 +10,6 @@
defined('_JEXEC') or die;
use Joomla\Registry\Registry;
use Joomla\String\String;
/**
* Weblinks model.
@ -325,10 +324,10 @@ class WeblinksModelWeblink extends JModelAdmin
{
if ($name == $table->title)
{
$name = String::increment($name);
$name = JString::increment($name);
}
$alias = String::increment($alias, 'dash');
$alias = JString::increment($alias, 'dash');
}
return array($name, $alias);

View File

@ -9,8 +9,6 @@
defined('_JEXEC') or die;
use Joomla\String\String;
/**
* Weblink Table class
*
@ -178,7 +176,7 @@ class WeblinksTableWeblink extends JTable
{
// Array of characters to remove
$bad_characters = array("\n", "\r", "\"", "<", ">");
$after_clean = String::str_ireplace($bad_characters, "", $this->metakey);
$after_clean = JString::str_ireplace($bad_characters, "", $this->metakey);
$keys = explode(',', $after_clean);
$clean_keys = array();