Results 1 to 3 of 3

Thread: Object has no method markup, DomHelper

  1. #1
    Sencha User
    Join Date
    Dec 2013
    Posts
    14
    Vote Rating
    0
      0  

    Default Object has no method markup, DomHelper

    I am trying to use the following code as explained in the example for DomHelper
    Code:
     var html = '<tr id="{0}" class="{1}" height="{2}" ><td colSpan="{3}" class="{4}">{5}</td></tr>';
           var tpl = new Ext.DomHelper.createTemplate(html);
    whenever i call Ext.DomHelper.createTemplate, i get the error
    Uncaught TypeError: Object [object Object] has no method 'markup'
    even though i am following the example.

    Any idea what could be going on ?

  2. #2
    Sencha Premium Member skirtle's Avatar
    Join Date
    Oct 2010
    Location
    UK
    Posts
    3,791
    Answers
    585
    Vote Rating
    394
      1  

    Default

    The example is wrong. The keyword new shouldn't be there.

  3. #3
    Sencha User palakurthivishal's Avatar
    Join Date
    Jul 2013
    Location
    India
    Posts
    74
    Answers
    8
    Vote Rating
    5
      0  

    Default

    Hello rahul.sood,
    As said by Mr.S
    kirtle, there shouldn't be "new" keyword since the class is singleton. It restricts you from creating instances of that class.

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •