rpielanen
Forum Replies Created
-
Emailed you.
Hi, thanks for your reply. I’m using version 3.0.7 and the problem still persists i’m afraid.
Robert
Hi, thanks for your reply. The image option was on yes. I’ve now tried to put it on auto, but whenever I safe the widget it reverts back to either yes or no. I’ve tried several times with saving in different order. The images still do not appear.
Thanks
Hi Daniel,
Is your last post a work-around to get dropbox working?
Where do i put this, in which functions file? The plugin or the theme?Thanks!
Forum: Plugins
In reply to: [Better WordPress Minify] Suggestion: How to find your script's handleDude, this is awesome. Exactly what I was looking for. Thanks!
Ok, so I hired a guy to look at the code and solve the problem. And he did! By adding one line of code to your cfs.php
I want to share this information with you, hoping you’ll appreciate it and that you will add the solution to your next update.
You scratch my back and I’ll scratch yours ??
He sent me an email with the explanation, but it was in Dutch so i’ll try to translate.
Starting from here:I’m pretty sure the problem was caused by this modification:
/**
* Make sure that $cfs is defined for template parts
* get_template_part() -> locate_template() -> load_template()
* load_template() extracts the $wp_query->query_vars array into variables,
* so we want to force it to create $cfs too.
*
* @param object $wp_query
* @since 1.8.8
*/
function parse_query( $wp_query ) {
$wp_query->query_vars[‘cfs’] = $this;
}
}Apparently is writes itself to an element of the query_vars array. This seems odd to me because this is not what an array is ment for, but ok. (his words)
Also: A post_type ‘cfs’ is defined in cfs.php, which among other things causes to execute this piece of code:
// If we’ve got a post_type AND it’s not “any” post_type.
if ( !empty($q[‘post_type’]) && ‘any’ != $q[‘post_type’] ) {
foreach ( (array)$q[‘post_type’] as $_post_type ) {
$ptype_obj = get_post_type_object($_post_type);
if ( !$ptype_obj || !$ptype_obj->query_var || empty($q[ $ptype_obj->query_var ]) )
continue;if ( ! $ptype_obj->hierarchical || strpos($q[ $ptype_obj->query_var ], ‘/’) === false ) {
// Non-hierarchical post_types & parent-level-hierarchical post_types can directly use ‘name’
$q[‘name’] = $q[ $ptype_obj->query_var ];
} else {
// Hierarchical post_types will operate through the
$q[‘pagename’] = $q[ $ptype_obj->query_var ];
$q[‘name’] = ”;
}And thus, after this $q[‘name’] becomes a cfs object. This object is put trough sanitize_title_for_query() which leads to the error.
The easiest way to fix this is to add this line of code to cfs.php
‘query_var’ => false,diff –git a/cfs.php b/cfs.php
index 188fcc9..355e695 100644
— a/cfs.php
+++ b/cfs.php
@@ -84,6 +84,7 @@ class Custom_Field_Suite
‘capability_type’ => ‘page’,
‘hierarchical’ => false,
‘supports’ => array( ‘title’ ),
+ ‘query_var’ => false,
‘labels’ => array(
‘name’ => __( ‘Field Groups’, ‘cfs’ ),
‘singular_name’ => __( ‘Field Group’, ‘cfs’ ),Cheers, Robert
Hi Matt,
I don’t want to seem impatient, but have you been able to find anything?
If not, or if you don’t want to spend more time on this. Please tell me so.Thanks for your help so far.
Robert
Also having the same problem on just one of my websites using BackWPup
Dropbox API: (35) Unsupported SSL protocol version
Hoping for a fix ??
Hi! Any thoughts on where to look next?
thanks so much!
That’s it ??
<table class="reviewreau"> <tr> <td class="reviewcatname"><?php echo 'Recordlabel:';?></td> <td class="reviewcatvalue"><?php echo $cfs->get('recordlabel');?></td> </tr> <tr> <td class="reviewcatname"><?php echo 'Catalogue:';?></td> <td class="reviewcatvalue"><?php echo $cfs->get('catalogue');?></td> </tr> <tr> <td class="reviewcatname"><?php echo 'Territory:';?></td> <td class="reviewcatvalue"><?php echo $cfs->get('territory');?></td> </tr> <tr> <td class="reviewcatname"><?php echo 'Format:';?></td> <td class="reviewcatvalue"><?php echo $cfs->get('format');?></td> </tr> <tr> <td class="reviewcatname"><?php echo 'Dealer Price:';?></td> <td class="reviewcatvalue"><?php echo $cfs->get('dealerprice');?></td> </tr> <tr> <td class="reviewcatname"><?php echo 'Release date:';?></td> <td class="reviewcatvalue"><?php echo $cfs->get('release_date');?></td> </tr> </table>
I’ve sent you a admin login, I will look for the strip_tags but I’m not that good at programming so your help is greatly appreciated!
Still having the same problem, all themes and plugins are up to date. How can it be this problem only arises when I update the custom field suite plugin to a version after 1.8.7.
I’ve asked the theme developer as well but not much happening there. Anyone who can help me with this?
Thanks in advance.
That would be this code, i think
<?php // Related Post function get_related_posts($post_id, $tags = array()) { $query = new WP_Query(); $post_types = get_post_types(); unset($post_types['page'], $post_types['attachment'], $post_types['revision'], $post_types['nav_menu_item']); if($tags) { foreach($tags as $tag) { $tagsA[] = $tag->term_id; } } $query = new WP_Query( array('showposts' => 4,'post_type' => $post_types,'post__not_in' => array($post_id),'tag__in' => $tagsA,'ignore_sticky_posts' => 1, )); return $query; } ?>