fireproofsocks
Forum Replies Created
-
Great: if you can see your post on the front-end it means your post-type’s visibility settings are correct.
The WordPress template hierarchy is confusing, so there’s no guaranteed answer to “where is ____?”. That’s a great question. To help answer it, you can follow this lovely map: http://codex.ww.wp.xz.cn/Template_Hierarchy and hope it doesn’t drive you nuts. Usually the loop is in the index.php file, but there are lots of possible caveats as to alternate locations and then there’s always the possibility that a plugin (or a theme) has hooked into the events and altered the output, and there’s no guarantee whoever wrote your template followed the standard guidelines.
I can’t speak for other plugins (e.g. Query Wrangler), so I have no idea how it is querying for posts or whether the query was done correctly. I always caution against the “plugin mentality” — like pills, plugins often have bad side-effects, so my recommendation is to use them only when the results outweigh the potential side-effects. Altering the loop shouldn’t require a plugin, only some template modifications. Sorry, this is really a tough one to troubleshoot, due mostly to the WordPress architecture.
Anything in your PHP logs? Sounds like maybe there was a PHP error and the page crashed?
I would update to the latest (dev version) of the plugin : the functionality for rewrite rules has been changed in the latest version and it will be released in the next version.
Forum: Plugins
In reply to: [Custom Content Type Manager] How to get all options of a custom field?Forum: Plugins
In reply to: [Custom Content Type Manager] Custom Fields returning strange dataCan you share your field definition (including any output filters)? And can you paste the code you are using in your template?
What does the following produce?
<?php print_custom_field('retail_product_price:raw'); ?>Forum: Plugins
In reply to: [Custom Content Type Manager] dropdown field dosent memorized my 1st choiceThis sounds like a bug. How is your dropdown defined? Does it include non-English characters? In the past I’ve had trouble with those because the json-encoding and decoding would sometimes fail to work 100% symmetrically so the selection failed to see which value was selected. Can you export your post type definition and file this as a bug @ https://code.google.com/p/wordpress-custom-content-type-manager/issues/list
Thanks.
Forum: Plugins
In reply to: [Custom Content Type Manager] registering foreign custom fields with CCTMThis could be tricky, and it’s a custom job, so I can’t really comment on “best practices”. Since this relates to the plugin’s architecture and how data is stored, I’ll point you to this heady discussion: https://code.google.com/p/wordpress-custom-content-type-manager/wiki/CustomFieldsDataStructure
Re assigning fields, there are 2 things there — one is how the data is stored. If WordPress wrote the data, then the association between field and post exists inherently in the wp_postmeta table. If you’re talking about the CCTM however, it maintains its own associations for assigning a field to a post type (thus the standardized set of fields).
I generally would not recommend trying to mix and match that way — I feel WP in particular is poorly suited to customizations like that. You may want to have a look at the code in the dev branch: it features a “detect custom fields” wizard that will read the database for existing values and let you create custom field definitions to match those values.
This is an option under the CCTM global options. Go to Custom Content Types –> Global Settings and uncheck the box for “Flush Permalink Rules”.
It seems that WP may have changed its behavior here in the latest version (3.8)
This can be subtly tricky. First, you should verify that your custom content type is in fact public and queryable — these are settings on the “Advanced” tab when you define/edit your custom content type definition. If you are able to view *any* custom posts on the front-end of your site, then it’s a good indication that your definition is correct.
Beyond that, however, you fall into the sometimes dark and turbulent world of WordPress themes: I have seen many many themes that do not query the database correctly and thus return only posts and not posts that use a custom post-type. If that’s the case, you would need to adjust the query used by the loop.
Forum: Plugins
In reply to: [Custom Content Type Manager] cctm_post_form and post_statusHmm…. I don’t know if WP would let you add comments to draft posts to be honest … architecturally it’s possible since the comments are just keyed off the original post id.
Re the slug: maybe I need to calculate the slug since I’m manually inserting the row and none of the WP events are triggered.
The security risks are pretty straight-forward: when you authenticate users via the WP manager, you presumably know who they are and you trust them. By letting the public visitors create content, you are potentially inviting very nasty types into your home. When your site gets hacked, for example, you have unauthenticated users adding content to your site. If your post allowed uploads, for example, a nefarious user could upload a hacking script and use your site to attack another server and be used in a DDOS attack and you’d be held responsible for it.
Forum: Plugins
In reply to: [Custom Content Type Manager] All posts of a single post type in widgetSee https://code.google.com/p/wordpress-custom-content-type-manager/wiki/Widget
You can set the search criteria to retrieve only posts of the specific post-type.
Forum: Plugins
In reply to: [Custom Content Type Manager] post_type cannot be "portfolio"I have seen some cases where WP has silently reserved words as incompatible for being used as post-type names, so it wouldn’t surprise me — these little landmines are not documented anywhere that I’m aware of.
In the CCTM.php file I have a variable to track these:
// Names that are off-limits for custom post types b/c they're already used by WP // Re "preview" see http://code.google.com/p/wordpress-custom-content-type-manager/issues/detail?id=321 public static $reserved_post_types = array('post', 'page', 'attachment', 'revision' , 'nav_menu', 'nav_menu_item', 'preview');I wonder if the “portfolio” thing is a new WP addition with 3.8…
Forum: Plugins
In reply to: [Custom Content Type Manager] Accessing custom field from another pluginHave you verified that the other plugin is storing the value as expected in the wp_postmeta table? The get_post_meta() function would be a more transparent window into that table.
Your syntax for get_custom_field() is incorrect: that function is meant to be called within the context of an existing post (i.e. the post-id is implied). See https://code.google.com/p/wordpress-custom-content-type-manager/wiki/get_custom_field
It expects a field name, NOT a post id. You will not have a custom field named 1 or 2 or whatever the post id is.
Forum: Plugins
In reply to: [Custom Content Type Manager] Can't Edit or Add Posts to CCTMIt would be helpful if you could share your php error logs: a white screen is usually indicative a PHP Fatal error.
This file controls some of the behavior relevant to multi-site and menus: https://code.google.com/p/wordpress-custom-content-type-manager/wiki/Config_admin_menu
It might be relevant to your issue, but the logs would help shed light on this.
Forum: Plugins
In reply to: [Custom Content Type Manager] User Access to Specific Media/Images OnlyYou can define your search parameters when you define the custom image (or relation or media) field by clicking on the “Set Search Parameters”. The search form that pops up can also be customized if it does not show you the criteria you need: https://code.google.com/p/wordpress-custom-content-type-manager/wiki/Config_search_parameters_image
Forum: Plugins
In reply to: [Custom Content Type Manager] CCTM and add_filter, mutually exclusive?Yeah, the GetPostsQuery specifically avoids the actions: the event-model that WP uses is a blessing and a curse, and when WP offers no logging ability, it’s mostly a curse because you never have any way of knowing when 2 or more plugins conflict with each other.
Glad you figured out a way to work with it.