Untitled diff

Créé Le diff n'expire jamais
43 suppressions
237 lignes
3 ajouts
194 lignes
# INCLUDE forum_top #
# INCLUDE forum_top #
<script>
<script>
<!--
<!--
function check_form_post(){
function check_form_post(){
if(document.getElementById('contents').value == "") {
if(document.getElementById('contents').value == "") {
alert("{L_REQUIRE_TEXT}");
alert("{L_REQUIRE_TEXT}");
return false;
return false;
}
}
if(document.getElementById('title').value == "") {
if(document.getElementById('title').value == "") {
alert("{L_REQUIRE_TITLE}");
alert("{L_REQUIRE_TITLE}");
return false;
return false;
}
}
if(!poll_hidded && document.getElementById('question').value == "") {
if(!poll_hidded && document.getElementById('question').value == "") {
alert("{L_REQUIRE_TITLE_POLL}");
alert("{L_REQUIRE_TITLE_POLL}");
return false;
return false;
}
}
return true;
return true;
}
}
var poll_hidded = true;
var poll_hidded = true;
function hide_poll(divID)
function hide_poll(divID)
{
{
if( document.getElementById(divID) )
if( document.getElementById(divID) )
{
{
document.getElementById(divID).style.display = 'block';
document.getElementById(divID).style.display = 'block';
if( document.getElementById('hidepoll_link') )
if( document.getElementById('hidepoll_link') )
{
{
document.getElementById('hidepoll_link').style.display = 'none';
document.getElementById('hidepoll_link').style.display = 'none';
poll_hidded = false;
poll_hidded = false;
}
}
}
}
}
}
function add_poll_field(nbr_field)
function add_poll_field(nbr_field)
{
{
if ( typeof this.max_field_p == 'undefined' )
if ( typeof this.max_field_p == 'undefined' )
this.max_field_p = (nbr_field == 0) ? 5 : nbr_field;
this.max_field_p = (nbr_field == 0) ? 5 : nbr_field;
else
else
this.max_field_p++;
this.max_field_p++;
if( this.max_field_p < 20 )
if( this.max_field_p < 20 )
{
{
if( this.max_field_p == 19 )
if( this.max_field_p == 19 )
{
{
if( document.getElementById('add_poll_field_link') )
if( document.getElementById('add_poll_field_link') )
document.getElementById('add_poll_field_link').innerHTML = '';
document.getElementById('add_poll_field_link').innerHTML = '';
}
}
document.getElementById('add_poll_field' + this.max_field_p).innerHTML += '<label><input type="text" name="a' + this.max_field_p + '" value="" /></label><br><span id="add_poll_field' + (this.max_field_p + 1) + '"></span>';
document.getElementById('add_poll_field' + this.max_field_p).innerHTML += '<label><input type="text" name="a' + this.max_field_p + '" value="" /></label><br /><span id="add_poll_field' + (this.max_field_p + 1) + '"></span>';
}
}
}
}
function XMLHttpRequest_change_statut()
function XMLHttpRequest_change_statut()
{
{
var idtopic = {IDTOPIC};
var idtopic = {IDTOPIC};
if( document.getElementById('forum_change_img') )
if( document.getElementById('forum_change_img') )
document.getElementById('forum_change_img').innerHTML = '<i class="fa fa-spinner fa-spin"></i>';
document.getElementById('forum_change_img').innerHTML = '<i class="fa fa-spinner fa-spin"></i>';
var xhr_object = xmlhttprequest_init('{PATH_TO_ROOT}/forum/xmlhttprequest.php?token={TOKEN}&msg_d=' + idtopic);
var xhr_object = xmlhttprequest_init('{PATH_TO_ROOT}/forum/xmlhttprequest.php?token={TOKEN}&msg_d=' + idtopic);
xhr_object.onreadystatechange = function()
xhr_object.onreadystatechange = function()
{
{
if( xhr_object.readyState == 4 && xhr_object.status == 200 )
if( xhr_object.readyState == 4 && xhr_object.status == 200 )
{
{
if( document.getElementById('forum_change_img') )
if( document.getElementById('forum_change_img') )
document.getElementById('forum_change_img').innerHTML = xhr_object.responseText == '1' ? '<i class="fa fa-msg-not-display"></i>' : '<i class="fa fa-msg-display"></i>';
document.getElementById('forum_change_img').innerHTML = xhr_object.responseText == '1' ? '<i class="fa fa-msg-not-display"></i>' : '<i class="fa fa-msg-display"></i>';
if( document.getElementById('forum_change_msg') )
if( document.getElementById('forum_change_msg') )
document.getElementById('forum_change_msg').innerHTML = xhr_object.responseText == '1' ? "{L_EXPLAIN_DISPLAY_MSG_BIS}" : "{L_EXPLAIN_DISPLAY_MSG}";
document.getElementById('forum_change_msg').innerHTML = xhr_object.responseText == '1' ? "{L_EXPLAIN_DISPLAY_MSG_BIS}" : "{L_EXPLAIN_DISPLAY_MSG}";
}
}
}
}
xmlhttprequest_sender(xhr_object, null);
xmlhttprequest_sender(xhr_object, null);
}
}
-->
-->
</script>
</script>
<article itemscope="itemscope" itemtype="http://schema.org/Creativework" id="article-forum-post">
<article itemscope="itemscope" itemtype="http://schema.org/Creativework" id="article-forum-post">
<header>
<header>
<h2>
<h2>
&bull; {U_FORUM_CAT} &raquo; {U_TITLE_T} <span><em>{DESC}</em></span>
&bull; {U_FORUM_CAT} &raquo; {U_TITLE_T} <span><em>{DESC}</em></span>
</h2>
</h2>
</header>
</header>
<div class="content">
<div class="content">
<form action="{U_ACTION}" method="post" onsubmit="return check_form_post();">
<form action="{U_ACTION}" method="post" onsubmit="return check_form_post();">
# INCLUDE message_helper #
# INCLUDE message_helper #
# IF C_FORUM_PREVIEW_MSG #
<div class="module-position">
<div class="module-top-l"></div>
<div class="module-top-r"></div>
<div class="module-top">
<span class="float-left">{L_PREVIEW}</span>
<span class="float-right"></span>&nbsp;
</div>
</div>
<div class="msg-position">
<div class="msg-container">
<div class="msg-pseudo-mbr"></div>
<div class="msg-top-row">
<div class="float-left"><i class="fa fa-hand-o-right"></i> {DATE}</div>
<div class="float-right"><i class="fa fa-quote-right"></i></div>
</div>
<div class="msg-contents-container">
<div class="msg-info-mbr">
</div>
<div class="msg-contents">
<div class="msg-contents-overflow">
{CONTENTS_PREVIEW}
</div>
</div>
</div>
</div>
<div class="msg-sign">
<hr />
<span class="float-left">
<span class="basic-button smaller">MP</span>
</span>
<span class="float-left">
</span>&nbsp;
</div>
</div>
<div class="msg-position">
<div class="msg-bottom-l"></div>
<div class="msg-bottom-r"></div>
<div class="msg-bottom">&nbsp;</div>
</div>
<br /><br />
# ENDIF #
<div class="fieldset-content">
<div class="fieldset-content">
<p class="center">{L_REQUIRE}</p>
<p class="center">{L_REQUIRE}</p>
<fieldset>
<fieldset>
<legend>{L_ACTION}</legend>
<legend>{L_ACTION}</legend>
# IF C_FORUM_CUT_CAT #
# IF C_FORUM_CUT_CAT #
<div class="form-element">
<div class="form-element">
<label for="to">* {L_CAT}</label>
<label for="to">* {L_CAT}</label>
<div class="form-field"><label>
<div class="form-field"><label>
<select id="to" name="to">
<select id="to" name="to">
{CATEGORIES}
{CATEGORIES}
</select>
</select>
</label></div>
</label></div>
</div>
</div>
# ENDIF #
# ENDIF #
<div class="form-element">
<div class="form-element">
<label for="title">* {L_TITLE}</label>
<label for="title">* {L_TITLE}</label>
<div class="form-field"><label><input type="text" class="field-large" maxlength="100" id="title" name="title" value="{TITLE}"></label></div>
<div class="form-field"><label><input type="text" class="field-large" maxlength="100" id="title" name="title" value="{TITLE}"></label></div>
</div>
</div>