Forum Replies Created
-
AuthorPosts
-
cosmocanuckMemberHmm… I should probably retract this question.
Further exploration has shown that custom fields don’t show up even in regular posts… and even if I create them using alternate means than Piklist (like a custom-field plugin). And another Divi site I built has Piklist-created custom fields that are working just fine.
I suspect another plugin is conflicting, or another issue unrelated to Piklist. Sorry! Don’t spend any time on this one for now, anyone! 8^)
cosmocanuckMemberI realized I should mention, that I’m building this in Divi – which might be an issue (though I realize it shouldn’t be, and in fact I created custom fields in Divi before with Piklist, no problem…)
July 11, 2018 at 7:16 pm in reply to: how to convert post field post_content as normal content area instead of editor #9121
cosmocanuckMemberIt’s all sorted. Sorry to add further clutter to this discussion – I’d delete my posts but that’s seemingly not doable…
Realized that specifying what fields are shown – or not – is part of defining the custom post type. Removed “editor” and it’s all sorted!
Thanks for providing me a place to work out the answers to my own questions… 8^)
Adam
July 11, 2018 at 6:33 pm in reply to: how to convert post field post_content as normal content area instead of editor #9120
cosmocanuckMemberSorry Steve, I erred – changing the type to “textarea” just made MY custom field not display at all. Sorry to inadvertently hijack this thread as my problem is probably unrelated!
Alas I can’t reference your original link (https://piklist.com/user-guide/tutorials/replacing-wordpress-post-editor/) as it’s no longer at that URL… but as I say, when I use the provided code, it just adds a field but doesn’t remove the default one.
This is a custom post type, does that affect things?
Anyway, thanks for whatever help you can offer!
Adam
July 11, 2018 at 6:24 pm in reply to: how to convert post field post_content as normal content area instead of editor #9119
cosmocanuckMemberHi Steve! There’s info in your reply here that I think needs to be included on this page:
https://piklist.github.io/docs/fields/types/editor/
I wanted to replace the default editor field with my own (mainly just so I could reposition it amongst my other custom fields), but when I used the code in the above reference page, which it says will achieve this (the code block just under “Piklist can replace the default editor in WordPress by using code the following code.”), it still only added an additional editor field – the default one was still there.
Only after I changed
'type' => 'editor',to'type' => 'textarea',did the unwanted default editor field finally vanish. Is this just a code typo? Anyway, wanted to let you know!All the best,
Adam
cosmocanuckMemberAha! Of course. My bad. Thanks!
cosmocanuckMemberThanks Steve – I’ll upgrade to 0.9.9.17!
cosmocanuckMemberThanks Jason! I guess I’m usually installing WP via cPanel and plugins via the Dashboard, so rarely directly FTP anything to my WP directory – but I’ll make note of those permissions guidelines.
And I was looking at Wordfence as well – I’ll check both your suggestion out for sure.
Have a great day!
cosmocanuckMemberThanks Jason!
I suspected as much in terms of what likely happened, i.e. a non-specific attack that lucked out and found a vulnerable way in. I’ll certainly follow up on your suggestions. I have just a couple of questions:File permissions: I don’t normally touch them, how do I know if there’s anything I should change?
Also, I see there are lots of security-oriented WP plugins out there that seem to do a lot of good things to maintain security – do you have any particular recommendations or have one you use regularly?
Again, thanks for your reply and the helpful suggestions!
Adam
cosmocanuckMemberGlad to help the site be even better and more accurate!
All the best!
cosmocanuckMemberAha. It works! Thanks!
But y’know what….
THAT COMMA IS IN THE DEMO CODE.
argh
Someone ought to fix that… ;^)
Thank you!
adam
cosmocanuckMemberContinuing to troubleshoot, I tried simply pasting in the untouched sample code above. But now I get the following error when trying to activate it:
Plugin could not be activated because it triggered a fatal error.
Parse error: syntax error, unexpected ‘,’, expecting ‘)’ in /nfs/c01/h08/mnt/7211/domains/hons.ca/html/wordpress/wp-content/plugins/piklist-hons/piklist-hons.php on line 39Hmmmm? Here is my current contents of the php file (with line 39 indicated by a comment):
<?php /* Plugin Name: HON'S Piklist Description: Adds custom post types and other features using the Piklist plugin. Version: 1.0 Author: Adam Abrams Author URI: http://www.adamabramsdesign.com Plugin Type: Piklist */ add_filter('piklist_post_types', 'piklist_demo_post_types'); function piklist_demo_post_types($post_types) { $post_types['piklist_demo'] = array( 'labels' => piklist('post_type_labels', 'Piklist Demo') ,'title' => __('Enter a new Demo Title') ,'menu_icon' => piklist('url', 'piklist') . '/parts/img/piklist-menu-icon.svg' ,'page_icon' => piklist('url', 'piklist') . '/parts/img/piklist-page-icon-32.png' ,'supports' => array( 'title' ,'post-formats' ) ,'public' => true ,'admin_body_class' => array( 'custom-body-class' ) ,'has_archive' => true ,'rewrite' => array( 'slug' => 'piklist-demo' ) ,'capability_type' => 'post' ,'edit_columns' => array( 'title' => __('Demo') ,'author' => __('Assigned to') ) ,'hide_meta_box' => array( ,'author' /* THIS IS LINE 39 */ ) ,'status' => array( 'new' => array( 'label' => 'New' ,'public' => false ) ,'pending' => array( 'label' => 'Pending Review' ,'public' => false ) ,'demo' => array( 'label' => 'Demo' ,'public' => true ,'exclude_from_search' => true ,'show_in_admin_all_list' => true ,'show_in_admin_status_list' => true ) ,'lock' => array( 'label' => 'Lock' ,'public' => true ) ) ); return $post_types; }September 15, 2015 at 4:51 pm in reply to: Reactivated: Checking for value of a repeating field seems not to work #4345
cosmocanuckMemberFantastic – thanks. Works great!
Going to hit the books a bit more on arrays. They still make my head hurt a bit. 8^)
September 15, 2015 at 12:27 pm in reply to: Checking for value of a repeating field seems not to work #4335
cosmocanuckMemberThanks Steve, that looks like exactly what I need – now to work through it… slowly! 8^)
September 15, 2015 at 12:01 pm in reply to: Checking for value of a repeating field seems not to work #4330
cosmocanuckMember0.9.4.28.
-
AuthorPosts