Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
mahara
mahara
Commits
4e38850f
Commit
4e38850f
authored
Oct 17, 2014
by
Son Nguyen
Committed by
Gerrit Code Review
Oct 17, 2014
Browse files
Merge "Adjusting places where form error message's container appears escaped"
parents
700340fe
7ea93380
Changes
2
Hide whitespace changes
Inline
Side-by-side
htdocs/blocktype/externalfeed/lib.php
View file @
4e38850f
...
...
@@ -211,7 +211,7 @@ class PluginBlocktypeExternalfeed extends SystemBlocktype {
else
{
$proto
=
substr
(
$values
[
'url'
],
0
,
strpos
(
$values
[
'url'
],
'://'
));
if
(
!
in_array
(
$proto
,
array
(
'http'
,
'https'
)))
{
$form
->
set_error
(
'url'
,
get_string
(
'invalidurl'
,
'blocktype.externalfeed'
));
$form
->
set_error
(
'url'
,
get_string
(
'invalidurl'
,
'blocktype.externalfeed'
)
,
false
);
}
}
...
...
@@ -223,7 +223,7 @@ class PluginBlocktypeExternalfeed extends SystemBlocktype {
$olddata
=
$instance
->
get_data
(
'feed'
,
$configdata
[
'feedid'
]);
if
(
$olddata
)
{
if
(
$values
[
'url'
]
<>
$olddata
->
url
&&
$olddata
->
authpassword
!=
''
&&
$values
[
'authpassword'
][
'submittedvalue'
]
===
null
)
{
$form
->
set_error
(
'authpassword'
,
get_string
(
'reenterpassword'
,
'blocktype.externalfeed'
));
$form
->
set_error
(
'authpassword'
,
get_string
(
'reenterpassword'
,
'blocktype.externalfeed'
)
,
false
);
return
;
}
}
...
...
@@ -237,7 +237,7 @@ class PluginBlocktypeExternalfeed extends SystemBlocktype {
return
;
}
catch
(
XML_Feed_Parser_Exception
$e
)
{
$form
->
set_error
(
'url'
,
get_string
(
'invalidfeed'
,
'blocktype.externalfeed'
,
$e
->
getMessage
()));
$form
->
set_error
(
'url'
,
get_string
(
'invalidfeed'
,
'blocktype.externalfeed'
,
hsc
(
$e
->
getMessage
()))
,
false
)
;
}
}
}
...
...
htdocs/blocktype/externalvideo/lib.php
View file @
4e38850f
...
...
@@ -230,7 +230,7 @@ class PluginBlocktypeExternalvideo extends SystemBlocktype {
}
// Nothing recognised this url.
$form
->
set_error
(
'videoid'
,
get_string
(
'invalidurl'
,
'blocktype.externalvideo'
));
$form
->
set_error
(
'videoid'
,
get_string
(
'invalidurl'
,
'blocktype.externalvideo'
)
,
false
);
}
public
static
function
instance_config_save
(
$values
)
{
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment