mirror of
https://github.com/silverstripe/silverstripe-userforms.git
synced 2024-10-22 17:05:42 +02:00
Merge branch '4'
This commit is contained in:
commit
c6ad8648fd
@ -110,9 +110,11 @@ class UserDefinedFormController extends PageController
|
||||
if ($this->Content && $form = $this->Form()) {
|
||||
$hasLocation = stristr($this->Content, '$UserDefinedForm');
|
||||
if ($hasLocation) {
|
||||
/** @see Requirements_Backend::escapeReplacement */
|
||||
$formEscapedForRegex = addcslashes($form->forTemplate(), '\\$');
|
||||
$content = preg_replace(
|
||||
'/(<p[^>]*>)?\\$UserDefinedForm(<\\/p>)?/i',
|
||||
$form->forTemplate(),
|
||||
$formEscapedForRegex,
|
||||
$this->Content
|
||||
);
|
||||
return [
|
||||
|
@ -3,7 +3,7 @@
|
||||
<div class="$Class">
|
||||
<input id="$ID" class="checkbox" name="$Name" type="checkbox" value="$Value.ATT"<% if $isChecked %>
|
||||
checked="checked"<% end_if %><% if $isDisabled %> disabled="disabled"<% end_if %> />
|
||||
<label for="$ID">$Title</label>
|
||||
<label for="$ID">$Title.XML</label>
|
||||
</div>
|
||||
<% end_loop %>
|
||||
<% else %>
|
||||
|
Loading…
Reference in New Issue
Block a user