Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion db_replace.php
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,10 @@
echo html_writer::div(get_string(
'replace_warning',
'tool_advancedreplace',
'$CFG->forced_plugin_settings[\'tool_advancedreplace\'][\'allowuireplace\'] = 1;'
(object)[
'file' => '$CFG->forced_plugin_settings[\'tool_advancedreplace\'][\'allowuireplace\'] = 1;',
'command' => 'php admin/cli/cfg.php --component=tool_advancedreplace --name=allowuireplace --set=1'
]
), 'alert alert-warning');
echo $OUTPUT->footer();
} else if ($data = $form->get_data()) {
Expand Down
5 changes: 4 additions & 1 deletion file_replace.php
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,10 @@
echo html_writer::div(get_string(
'replace_warning',
'tool_advancedreplace',
'$CFG->forced_plugin_settings[\'tool_advancedreplace\'][\'allowuireplace\'] = 1;'
(object)[
'file' => '$CFG->forced_plugin_settings[\'tool_advancedreplace\'][\'allowuireplace\'] = 1;',
'command' => 'php admin/cli/cfg.php --component=tool_advancedreplace --name=allowuireplace --set=1'
]
), 'alert alert-warning');
echo $OUTPUT->footer();
} else if ($data = $form->get_data()) {
Expand Down
2 changes: 1 addition & 1 deletion lang/en/tool_advancedreplace.php
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@
$string['privacy:metadata:tool_advancedreplace_search:userid'] = 'User who created the db search';
$string['privacy:metadata:tool_advancedreplace_search:usermodified'] = 'User who modified the db search';
$string['replace'] = 'Replace';
$string['replace_warning'] = 'Replace via UI not enabled, to enable please set <code>{$a}</code> in config.php';
$string['replace_warning'] = 'Replace via UI not enabled. To enable, please set in config.php:<br><code>{$a->file}</code><br> or via CLI command: <br><code>{$a->command}</code>';
$string['replacecheckdb'] = 'Are you sure you want to replace strings in the Database using the uploaded csv file?';
$string['replacecheckfiles'] = 'Are you sure you want to replace strings in Files using the uploaded csv file?';
$string['replacefilespageheader'] = 'Replace text stored in files';
Expand Down
Loading