{% extends "ndf/base.html" %} {% load i18n %} {% load ndf_tags %} {% load cache %} {% block title %}Creating Thread to Forum: {{forum.name}} {% endblock %} {% cache 3600 create_thread request.LANGUAGE_CODE %} {% block head %} {% endblock %} {% block meta_content %}

{% trans "Thread" %}


{% endblock %} {% block concern_information %}
{% endblock %} {% block help_content %}

{% trans "Threads are new ideas on the topic" %}

{% endblock %} {% endcache %} {% block body_content %}

{% trans "Add a new Thread to forum" %}



{{ forum_created_by }}
{{forum.created_at|date:"D d M Y" }}
Forum: {{forum.name}}

{% with forum.content|safe as forum_content %} {{forum_content}} {% endwith %}

{% csrf_token %} {% cache 3600 create_thread_form request.LANGUAGE_CODE %}
{% trans "Thread:" %}


{% trans "Thread Content: " %}
{% include "ndf/html_editor.html" with var_name="content_org" node_id=forum.pk %}

{% endcache %}
{% endblock %} {% block document_ready %} // orgitdown $('#orgitdown').orgitdown(mySettings); {% endblock %} {% block script %} $("#node_search_form").parent().hide(); var nodes = {{forum_threads|safe}} var flag = false; html = '"); $("#forum").click(function(event) { var name = $("#thread_name").val().trim().toLowerCase(); if (name != "") { if (nodes.indexOf(name) != -1) { $("#message").css("display", "block"); $("#message").text("{{title}} '" + name +"' already exist. Please choose another name"); event.preventDefault(); } } else if (name == ""){ $("#message").css("display", "block"); $("#message").text("Name cannot be empty."); event.preventDefault(); } else { $("#message").css("display", "none"); } }); {% endblock %}