Forum Replies Created

Viewing 15 posts - 196 through 210 (of 330 total)
  • Author
    Posts
  • in reply to: Validation broken? #2972
    Jason
    Keymaster

    And, to clarify, when I say “not work” I mean that the validation never fails.

    in reply to: Validation broken? #2971
    Jason
    Keymaster
    in reply to: Anchor button doesn't work for editor inside of group #2963
    Jason
    Keymaster
    This reply has been marked as private.
    in reply to: Anchor button doesn't work for editor inside of group #2943
    Jason
    Keymaster

    Hi Steve,

    Sorry for the mixture of notes. 🙂

    After some research, I realized that the wp_editor function relies on the ‘textarea_name’ to save to the settings. So while setting it to something simple fixes the editor issue, it breaks the editor actually saving to the database (a rather bittersweet victory).

    I believe the final issue is that I’ve made a habit of using hyphens in database names. Normally this isn’t an issue, but I believe that wp_editor is attempting to build javascript variables based on the id and textarea_name, which is why hyphens cause issues.

    As for a fix? I believe that’s really a wp_editor bug, so I’d just put a note in the docs to avoid using hyphens when dealing with the editor field.

    in reply to: Anchor button doesn't work for editor inside of group #2940
    Jason
    Keymaster

    Ok.. so I’ve found that Piklist uses the textarea_name in order to know where to save the field. I’ll let you guys take it from here since I’m not sure how you’re using the textarea_name to save properly.

    in reply to: Anchor button doesn't work for editor inside of group #2939
    Jason
    Keymaster

    I believe I figured out the issue, and it’s the default ‘textarea_name’ that Piklist derives from the $name and $_attributes variables. I believe it’s an illegal characters issue, as the name would then include hyphens, spaces, and equal signs.

    If I include a ‘textarea_name’ in the field options, it fixes the issue.

    in reply to: Anchor button doesn't work for editor inside of group #2938
    Jason
    Keymaster

    As far as the ‘textarea_rows’ issue goes, I was looking at the editor.php code and realized you’re using ‘editor_height’. I’m not exactly sure why. If I use that in the field properties instead of textarea_rows, then I’m able to adjust the height properly. I tried omitting ‘editor_height’ from the default options and using ‘textarea_rows’ instead, but for some reason that didn’t work.

    in reply to: Anchor button doesn't work for editor inside of group #2935
    Jason
    Keymaster

    So here’s what I did:

    wp_editor('', 'test_editor', array(
      'media_buttons' => false,
      'teeny'         => true,
      'wpautop'       => false,
      'quicktags'     => false
    ));
    
    piklist('field', array(
      'type'    => 'editor',
      'field'   => 'test_field',
      'label'   => 'Test Editor',
      'options' => array(
        'media_buttons' => false,
        'teeny'         => true,
        'wpautop'       => false,
        'quicktags'     => false
      )
    ));

    I also tested using an underscore instead of hyphen in the field name, as I assumed you’re getting the editor id from the field and I read that hyphens can cause problems (which I usually use in field names).

    On a side note, I can’t get ‘textarea_rows’ to work with Piklist, either, but it works just fine with the native function.

    The conclusion, though, is that there’s an issue with Piklist. I had no anchor issues with the native wp_editor function.

    in reply to: Anchor button doesn't work for editor inside of group #2933
    Jason
    Keymaster

    Greetings!

    I found that if ‘quicktags’ => false then the anchor button stops working again. If true, then no problem. The strong and other buttons continue working fine in either case.

    in reply to: Feature Request: Simplified Editor #2932
    Jason
    Keymaster

    Hmm.. I’ll have to look around to find what array parameters I can pass to ‘tinymce’.

    As a side note, setting ‘tinymce’ => false causes a javscript error: piklist.js:254 Uncaught ReferenceError: tinymce is not defined

    in reply to: Anchor button doesn't work for editor inside of group #2930
    Jason
    Keymaster

    It did! Perfect!

    in reply to: How to create select with posts choices #2922
    Jason
    Keymaster

    Hi igor!

    Rather than changing subject in a topic, I suggest making a new topic to help make your question easy for others to find in the future. 🙂

    But you can do this easily! I do it all the time! What you’re going to want to do is enqueue the Select2 script into the admin side only. Everything on how to do that can be found here: http://codex.wordpress.org/Plugin_API/Action_Reference/admin_enqueue_scripts

    And you can use a CDN url for Select2 instead of downloading the script and adding it to your theme/plugin.

    Hope this helps! 🙂

    in reply to: Nested Groups in Settings #2921
    Jason
    Keymaster

    Hmm.. I see. Clearly it’s more important that the columns add up to 12 per row than I realized. I assumed it would just cleanly float beyond that point. It usually does, but this isn’t the first time I’ve ran into issues.

    It’s not quite what I had in mind, however, but I’m not really sure that’s up to Piklist to solve. I was imagining that each group would indent as it nested. As it is, I could just apply my own styles to provide padding above the group label to help distinguish sections better.

    Thanks, Steve!

    in reply to: Nested Groups in Settings #2917
    Jason
    Keymaster

    There’s 3 fields: 10 + (5 + 5)

    That would normally just mean the first field is on it’s own row and the last two fields are on a row. If I settle everything down to a single group (remove the nesting) then the columns work just fine.

    Thoughts?

    in reply to: Custom Post Type archives and posts giving a 404. Piklist bug? #2731
    Jason
    Keymaster

    Hahah! I’m just sharing my heart. 😉

Viewing 15 posts - 196 through 210 (of 330 total)