ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

Matrix js not working in SafeCracker forms.

October 24, 2012 3:17pm

Subscribe [3]
  • #1 / Oct 24, 2012 3:17pm

    aircrash

    293 posts

    I have a SafeCracker form that includes a Matrix field. I’m using the {field:my_custom_field} method of calling the field in my template. It displays correctly, but the + (add row) button isn’t working.

    I’ve tried moving my jquery link to the top of my template and adding include_jquery=“no” to my SafeCracker tag, but it makes no difference. Setting safecracker_head=“no”  makes the Matrix + button disappear entirely.

    I’m running EE 2.5.3 build 20120911, and Matrix 2.4.3.

    I’m getting this error in FireBug:

    $(”#write_mode_textarea”).markItUp is not a function
    ...(function(){b=$(this).attr(“id”).match(/^id_\d+$/)?“field_”+$(this).attr(“id”):$...

    ?ACT=1…e_url=y (line 586)

  • #2 / Oct 25, 2012 12:39pm

    Shane Eckert

    7174 posts

    Hey aircrash,

    Are you including the Matrix Javascript file from the themes folder?

    I think that will be what you need!

    Cheers,

  • #3 / Oct 25, 2012 1:09pm

    aircrash

    293 posts

    I wasn’t including it in my template code, but matrix.js and matrix_head.js are included automatically when safecracker_head is set to “yes”.

    I tried linking to them directly in my template, but it didn’t make any difference. It still isn’t working.

  • #4 / Oct 29, 2012 1:54pm

    Shane Eckert

    7174 posts

    Hey aircrash,

    I would like to get in a take a quick look, if that’s okay.

    Please be on the lookout for an email from EllisLab.

    Cheers,

  • #5 / Oct 29, 2012 2:15pm

    aircrash

    293 posts

    sent

  • #6 / Oct 29, 2012 5:50pm

    Shane Eckert

    7174 posts

    Hey aircrash,

    Awesome! Thank you.

    We will get back to you asap.

    Cheers,

  • #7 / Nov 07, 2012 12:22am

    itseriko

    1 posts

    Any update on this? I’m getting the same error.

  • #8 / Nov 07, 2012 8:35am

    aircrash

    293 posts

    itseriko, I had to move all of my javascripts to the top of my page to get it working.

  • #9 / Nov 07, 2012 3:52pm

    Shane Eckert

    7174 posts

    Hey aircrash,

    I am glad we could get this resolved!

    If you need anything else, please just let me know by opening a new thread.

    Cheers,

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases