WordPress.org

Ready to get started?Download WordPress

Forums

why insert full posts as captions inside Nav-menu page? (2 posts)

  1. Viktor Nagornyy
    Member
    Posted 3 years ago #

    I've been having issues with plugins breaking drag-and-drop of Nav-menu feature, so I was going through source code of the page to see exactly what plugin might break it and noticed something interesting.

    Full posts, I thought they were excerpts but they include shortcodes from posts, are inserted as values in hidden input fields. I'm quiet puzzled at what good this might do on a page where menu is controlled? I'm including one li tag to show what I mean:

    <li><label class="menu-item-title"><input type="checkbox" class="menu-item-checkbox" name="menu-item[-5][menu-item-object-id]" value="28" /> New post to test few things</label><input type="hidden" class="menu-item-db-id" name="menu-item[-5][menu-item-db-id]" value="0" /><input type="hidden" class="menu-item-object" name="menu-item[-5][menu-item-object]" value="post" /><input type="hidden" class="menu-item-parent-id" name="menu-item[-5][menu-item-parent-id]" value="0" /><input type="hidden" class="menu-item-type" name="menu-item[-5][menu-item-type]" value="post_type" /><input type="hidden" class="menu-item-title" name="menu-item[-5][menu-item-title]" value="New post to test few things" /><input type="hidden" class="menu-item-url" name="menu-item[-5][menu-item-url]" value="http://www.dev.viktorix.com/blog/new-post-to-test-few-things" /><input type="hidden" class="menu-item-target" name="menu-item[-5][menu-item-target]" value="" /><input type="hidden" class="menu-item-attr_title" name="menu-item[-5][menu-item-attr_title]" value="Vestibulum porttitor nibh sit amet ipsum eleifend dictum. Donec porttitor condimentum libero, quis malesuada libero consectetur a. Sed eros erat, mollis vitae lobortis id, fermentum sit amet turpis. Cras laoreet scelerisque purus quis ullamcorper." /><input type="hidden" class="menu-item-description" name="menu-item[-5][menu-item-description]" value="[caption id=&quot;attachment_7&quot; align=&quot;alignright&quot; width=&quot;150&quot; caption=&quot;contract-negotiations-300x300&quot;][/caption]
    
    Lorem ipsum dolor sit amet, consectetur adipiscing elit. Aliquam id  lorem purus. Morbi sagittis aliquet neque vel viverra. In hac habitasse  platea dictumst. Praesent viverra fringilla feugiat. Donec bibendum eros  et sem faucibus vehicula. Mauris a sagittis orci. Cras viverra erat in  leo interdum at sollicitudin mauris commodo. Morbi scelerisque sapien  fringilla est convallis et aliquam metus vestibulum. Donec hendrerit  libero ut dolor ullamcorper sit amet scelerisque nisi pellentesque. Nam  adipiscing vestibulum sapien, ac semper orci varius rutrum. Vestibulum  lacus velit, adipiscing eget rutrum ut, vehicula sit amet odio. Lorem  ipsum dolor sit amet, consectetur adipiscing elit. Pellentesque eros  velit, suscipit sed malesuada in, tincidunt ut est. Nulla venenatis arcu  sit amet nisl dictum fermentum. In pulvinar adipiscing ligula vitae  blandit. Pellentesque viverra tortor vestibulum mauris adipiscing  tincidunt.
    Nunc sollicitudin laoreet lacus non mollis. Curabitur  fringilla semper dui ut congue. Morbi tristique orci quis lacus feugiat  nec tristique eros pretium. Mauris eros eros, vulputate suscipit pretium  vitae, ultricies nec mauris.
    Quisque placerat ligula ut diam vulputate feugiat. Integer mi justo,  dignissim sed elementum non, auctor quis tellus. Pellentesque ac purus  eu sapien congue laoreet ut sit amet nisi. Duis sed ante sit amet leo  blandit scelerisque. Maecenas eget eros in arcu vulputate vehicula quis  in odio.
    Proin eleifend, justo eget scelerisque pellentesque, nisi arcu  congue elit, nec dignissim lectus mauris quis felis. Etiam iaculis sem  eget velit pretium elementum. In posuere dictum felis, at posuere odio  lobortis et. Donec justo urna, suscipit quis gravida quis, aliquet eget  diam.
    In hac habitasse platea dictumst. Sed et tellus et diam consequat  auctor. Vestibulum porttitor nibh sit amet ipsum eleifend dictum. Donec  porttitor condimentum libero, quis malesuada libero consectetur a. Sed  eros erat, mollis vitae lobortis id, fermentum sit amet turpis. Cras  laoreet scelerisque purus quis ullamcorper.
    Duis lacus mauris, euismod non mollis ut, mollis vel mi. Phasellus  dignissim molestie laoreet. Pellentesque tincidunt vehicula lectus in  hendrerit. Maecenas tempor ornare congue. Nam malesuada justo vel nisi  lacinia ac dapibus urna feugiat. Etiam viverra ipsum congue magna  dignissim gravida. Vivamus porttitor dignissim consequat. Duis ultrices,  urna eu pellentesque porta, erat massa faucibus magna, ut faucibus  lectus lectus imperdiet tellus. Donec nec nunc ante, vel pellentesque  justo. Ut ultricies vestibulum dictum. Sed nisl leo, tristique in  faucibus ut, adipiscing nec purus. Curabitur id ipsum vitae orci  ullamcorper bibendum non sit amet risus. Etiam ut nisi ut nisl facilisis  pulvinar et at tortor. Aenean diam neque, rutrum vel elementum non,  adipiscing vitae mauris. Quisque et felis nulla. Duis placerat mauris at  arcu ultrices laoreet. Nulla facilisi. Maecenas nec neque orci, in  dictum lacus. Phasellus elementum sagittis viverra. Morbi consequat  velit et ipsum facilisis porta.
    [youtube]stdJd598Dtg[/youtube]" /><input type="hidden" class="menu-item-classes" name="menu-item[-5][menu-item-classes]" value="" /><input type="hidden" class="menu-item-xfn" name="menu-item[-5][menu-item-xfn]" value="" /></li>

    What was the idea behind it? I don't get it.

  2. Viktor Nagornyy
    Member
    Posted 3 years ago #

    Sorry for the title, I meant "value" not caption =(

Topic Closed

This topic has been closed to new replies.

About this Topic