Answer the question
In order to leave comments, you need to log in
How to disable the ability in DLE to write the title of news to users?
How to disable the ability in DLE to write the title of news to users? When you remove the line in the code where to write the title of the news, or you do not fill it out, the error "The title is required when writing an article" appears.
How can I turn it off?
The code
<div class="block">
<div class="block-head">
<tr>
<div class="baseform">
<table class="tableform">
<tr>
<td class="label">
<b>Название:</b>
</td>
<td><input type="" id="title" name="title" value="{title}Грех #" maxlength="150" class="f_input" /> </td>
</tr>
<tr>
<td colspan="2">
<b>Грех:</b>
[not-wysywyg]
<div class="bb-editor">
{bbcode}
<textarea name="short_story" id="short_story" style="margin: 0px; resize: none; width: 638px; height: 225px;" onfocus="setFieldName(this.name)" rows="15" cols="83" class="f_textarea" >{short-story}</textarea>
</div>
[/not-wysywyg]
{shortarea}
</td>
</tr>
</table>
<div class="fieldsubmit">
<button name="add" class="comments-but" type="submit"><span>Поделиться</span></button>
</div>
</div>
</div>
</div>
Answer the question
In order to leave comments, you need to log in
Just write a hidden field instead of the usual one and add a default value for it:
<input type="hidden" name="title" value="Грех #" />
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question