WELCOME Abdennour : Software engineer

May 8, 2013

Jquery Template Clear Cache


Problem
I have the following code :

    var data = "<li><b>${a}</b> (${b})</li>";
    $.template( "compiledItem",data );

The instruction above is called "compilation of template" or "Caching a template " via jquerty template  using String value as a identifier. (String =>'compiledItem')

When i modify markup value, i want to clear the cache

  How Can i delete the template cache?

Solution


Add before compilation instruction the following instruction :

     delete $.template["compiledItem"];

8 comments:

  1. Wow. This really made my day. Thanks a lot!

    Wow. This really made my day. Thanks a lot!
    JQuery Training JQuery Training Javascript JQuery Online Training

    JQuery Online Training JQuery Online Training Javascript Online Training JQuery Training

    ReplyDelete
  2. Wow. This really made my day. Thanks a lot!
    JQuery Training JQuery Training Javascript JQuery Online Training

    JQuery Online Training JQuery Online Training Javascript Online Training JQuery Training

    JavaScript Training Courses

    ReplyDelete
  3. I really appreciate information shared above. It’s of great help. If someone want to learn Online (Virtual) instructor lead live training in JQUERY
    , kindly contact us http://www.maxmunus.com/contact
    MaxMunus Offer World Class Virtual Instructor led training on JQUERY. We have industry expert trainer. We provide Training Material and Software Support. MaxMunus has successfully conducted 100000+ trainings in India, USA, UK, Australlia, Switzerland, Qatar, Saudi Arabia, Bangladesh, Bahrain and UAE etc.
    For Demo Contact us:
    Name : Arunkumar U
    Email : arun@maxmunus.com
    Skype id: training_maxmunus
    Contact No.-+91-9738507310
    Company Website –http://www.maxmunus.com



    ReplyDelete

  4. Very Interesting information shared than other blogs
    Thanks for Sharing and Keep updating us

    ReplyDelete
  5. Thanks for sharing the info, keep up the good work going.... I really enjoyed exploring your site. good resource...
    Premium Whmcs templates

    ReplyDelete
  6. Australia Best Tutor is one of the best Online Assignment Help providers at an affordable price. Here All Learners or Students are getting best quality assignment help with reference and styles formatting.

    Visit us for more Information

    Australia Best Tutor
    Sydney, NSW, Australia
    Call @ +61-730-407-305
    Live Chat @ https://www.australiabesttutor.com




    Our Services

    Online assignment help
    my assignment help Student
    Assignment help Student
    help with assignment Student
    Students instant assignment help

    ReplyDelete
  7. Each department of CAD have specific programmes which, while completed could provide you with a recognisable qualification that could assist you get a job in anything design enterprise which you would really like.

    AutoCAD training in Noida

    AutoCAD training institute in Noida


    Best AutoCAD training institute in Noida

    ReplyDelete