2

I've followed the documentation outlined here:

http://docs.pixelandtonic.com/matrix/templating/field.html

Where my custom field is member_companyname and is assigned as a matrix fieldtype.

{member_companyname sort="desc" limit="1"}
<input type="text" name="member_companyname" id="member_companyname" class="form-text" value="{member_companyname}" />

<input type="hidden" name="member_companyname[row_order][]" value="row_new_{count}">
<input type="hidden" name="member_companyname[row_new_{count}][col_id_20][]" value="[{entry_id}] [{url_title}] {title}">
{/member_companyname}

but it's not rendering it and spits it out as this:

Company Name {member_companyname sort="desc" limit="1"} " />

6
  • What about adding the orderby parameter? Are there any variables between the tag pair that may be causing a conflict? Conditionals? Can you post what you have between the matrix tags? Commented Jul 18, 2013 at 19:39
  • {member_companyname orderby="session_time" sort="desc"} {member_companyname} {/member_companyname} it just renders it just like that... should i email you? I feel that would be better, this support system is confusing and wont' allow me to paste my code. Commented Jul 18, 2013 at 19:39
  • It might help to know that i'm using this inside {exp:zoo_visitor:update_form} Commented Jul 18, 2013 at 19:45
  • You could paste your code in a pastie pastie.org
    – CreateSean
    Commented Jul 18, 2013 at 20:45
  • Thank you for writing me back so fast! I've also emailed you. pastie.org/8153638 Commented Jul 18, 2013 at 20:59

1 Answer 1

1

This is not a Matrix issue, but a Zoo Visitor template tag issue. Here's the winning code per comments posted above. I'm posting here for all to see.

{exp:channel:entries entry_id="{zoo_visitor_id}" status="not closed" limit="1"}
  {exp:zoo_visitor:update_form}
    Company Name: <br />
    <input type="hidden" name="member_companyname[row_order][]" value="row_new_0">
    <input type="text" name="member_companyname[row_new_0][col_id_1]" value="{member_companyname sort="desc" limit="1"}{member_companyname}{/member_companyname}"/>
  {/exp:zoo_visitor:update_form}
{/exp:channel:entries}

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.