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:
commit
6cd0429107
@ -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);
|
||||
|
@ -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();
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user