What is db.TextProperty!? Is it Django?
Where the "result" variable comes from?

please read:
https://docs.djangoproject.com/en/1.7/ref/models/


On 03/27/2015 10:20 AM, Akash Patni wrote:
Hi This is my html

{% block content %}

<!-- Begin Body Columns -->

  <div class="container-top">
<div class="container-top-icon"><img src="/site_media/images/digital-assets-note-icon.png" alt="Notes" /></div>
        <h2>View Notes</h2>
        <div class="container-top-detail">See your notes details.</div>
  </div>
  <div class="clear"></div>

    {% for i in result %}
<div class="da_row">
 <div class="da_label">Note Title</div>
 <div class="da_description">{{i.note_title}}</div>
</div>
<div class="clear"></div>
<div class="da_row">
 <div class="da_label">Note</div>
*<div class="da_description">{{i.note}</div>*
</div>
<div class="clear"></div>

<div class="da_row">
 <div class="da_label">Beneficiaries</div>
 <div class="da_description">
   {% if all_nominees %}
   {% for nominee in all_nominees %}
   {% if nominee.1 %}
{{nominee.0.first_name}} {% if nominee.last_name %}{{nominee.last_name}}{% endif %} {% if nominee.0.is_charity %}(charity){% else %}(individual){% endif %}
 <br />
   {% endif %}
   {% endfor %}
{% else %}
<div>No beneficiaries at the moment.</div>
{% endif %}
 </div>
</div>
<div class="clear"></div>

<div class="da_row">
 <div class="da_label">Action</div>
 <div class="da_description">
<div class="dashboard-options edit-btn"><a title="Edit" href="/user/notes/edit?id={{i.key}}">Edit</a></div> <div class="dashboard-options edit-btn"><a title="Delete" href="/user/notes/delete?id={{i.key}}" onclick="return deleteConfirmation();">Delete</a></div>
 </div>
</div>
<div class="clear"></div>
  {% endfor %}

{% endblock %}

This is my model

class AssetNotes(db.Model):
    user_id = db.ReferenceProperty(User)
    written_on = db.DateProperty(verbose_name="Note Date")
    note_title = db.StringProperty(verbose_name = "Note Title *")
    note = db.TextProperty(verbose_name = "Note")
    add_date = db.DateTimeProperty(verbose_name=None, auto_now_add=True)
    update_date = db.DateTimeProperty(verbose_name=None, auto_now=True)
    client_id = db.StringProperty(verbose_name = "Client ID", default="")
    def __unicode__(self):
        return self.note_title
I want to show only code but instead of that it is showing image in descrption field.

and the code contains image url.

On Fri, Mar 27, 2015 at 2:41 PM, aRkadeFR <cont...@arkade.info <mailto:cont...@arkade.info>> wrote:

    Hello,

    You could provide us more information when asking for
    help please. Your template and view code at least.

    I guess your problem is in your HTML but to be sure, please
    dump your information at the POST request to see what
    is send. Then review your template. Maybe there's a "name"
    attribute on the img tag?

    Have a good one

    On 03/27/2015 08:36 AM, akash.pa...@ranosys.com
    <mailto:akash.pa...@ranosys.com> wrote:
    Hie to all,
    In one of my template i am using text area. The issue is that
    when i write html tags with some image link using img tag, when i
    am saving this i am getting image on the desription field.

    Actual-Image is comming

    Expected-I want HTML code to be displayed in the discription.

    Please suggest

-- You received this message because you are subscribed to the
    Google Groups "Django users" group.
    To unsubscribe from this group and stop receiving emails from it,
    send an email to django-users+unsubscr...@googlegroups.com
    <mailto:django-users+unsubscr...@googlegroups.com>.
    To post to this group, send email to
    django-users@googlegroups.com <mailto:django-users@googlegroups.com>.
    Visit this group at http://groups.google.com/group/django-users.
    To view this discussion on the web visit
    
https://groups.google.com/d/msgid/django-users/597ca45f-a1d9-43a4-a77b-a4ffc29d1b69%40googlegroups.com
    
<https://groups.google.com/d/msgid/django-users/597ca45f-a1d9-43a4-a77b-a4ffc29d1b69%40googlegroups.com?utm_medium=email&utm_source=footer>.
    For more options, visit https://groups.google.com/d/optout.

-- You received this message because you are subscribed to a topic in
    the Google Groups "Django users" group.
    To unsubscribe from this topic, visit
    https://groups.google.com/d/topic/django-users/6bheSzmXFGc/unsubscribe.
    To unsubscribe from this group and all its topics, send an email
    to django-users+unsubscr...@googlegroups.com
    <mailto:django-users+unsubscr...@googlegroups.com>.
    To post to this group, send email to django-users@googlegroups.com
    <mailto:django-users@googlegroups.com>.
    Visit this group at http://groups.google.com/group/django-users.
    To view this discussion on the web visit
    
https://groups.google.com/d/msgid/django-users/55151EC7.3090403%40arkade.info
    
<https://groups.google.com/d/msgid/django-users/55151EC7.3090403%40arkade.info?utm_medium=email&utm_source=footer>.


    For more options, visit https://groups.google.com/d/optout.




--
*Best Regards,*
Akash Patni
Software Engineer
*
*
*
**
ranosys <http://ranosys.com/>
facebook <https://www.facebook.com/ranosys> twitter <https://twitter.com/ranosys> linkedin <https://www.linkedin.com/company/741079?trk=prof-exp-company-name> googleplus <https://plus.google.com/+Ranosys>

*Head Office: *
Oxley Bizhub, #06-48 | 73 Ubi Road 1 | Singapore - 408733
*Tel:* +65 66331556 | *HP: *+65 98573420

**

*
**

*Global Offices:*
San Francisco, USA | Jaipur, India | Bikaner, India

**
*

**
*
**
--
You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscr...@googlegroups.com <mailto:django-users+unsubscr...@googlegroups.com>. To post to this group, send email to django-users@googlegroups.com <mailto:django-users@googlegroups.com>.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/CANSMZiRzDaCqCJG-QF-t6Bk6ckKsk4fgZFcTq%3DbgVYNPVrHiMg%40mail.gmail.com <https://groups.google.com/d/msgid/django-users/CANSMZiRzDaCqCJG-QF-t6Bk6ckKsk4fgZFcTq%3DbgVYNPVrHiMg%40mail.gmail.com?utm_medium=email&utm_source=footer>.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Django 
users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/55154CF8.6030305%40arkade.info.
For more options, visit https://groups.google.com/d/optout.

Reply via email to