Richard Vencu
Forum Replies Created
-
Forum: Plugins
In reply to: [CubePoints] [Plugin: CubePoints] MultisiteAnd in cp_admin_config.php I did similar changes:
if (get_option('cp_mypoints')) { $cp_mypoints_checked = " checked='checked'"; } else { $cp_mypoints_checked = ""; } global $blog_id; //add this line here
and
[Code moderated as per the Forum Rules. Please use the pastebin]
Forum: Plugins
In reply to: [CubePoints] [Plugin: CubePoints] MultisiteSo for short, I did this:
incp_admin_manage.php
I changed the code like this:function cp_admin_manage() { global $blog_id; //add this line here
…
then:<form method="post" name="cp_manage_form_<?php echo $result->ID; ?>" id="cp_manage_form_<?php echo $result->ID; ?>"> <input type="hidden" name="cp_manage_form_id" value="<?php echo $result->ID; ?>" /> <input <?php if (is_multisite() && $blog_id > 1) echo " disabled='disabled'"; ?> type="text" name="cp_manage_form_points" value="<?php echo cp_getPoints($result->ID); ?>" /> <input <?php if (is_multisite() && $blog_id > 1) echo " disabled='disabled'"; ?> type="submit" value="<?php _e('Update', 'cp'); ?>" /> <img src="<?php echo WP_PLUGIN_URL.'/'.str_replace(basename(__FILE__),"",plugin_basename(__FILE__)). 'assets/load.gif'; ?>" style="display: none;" /> </form>
Forum: Plugins
In reply to: [CubePoints] [Plugin: CubePoints] MultisiteI am using version 3.1 of Cubepoints. By investigating the code and the database I can see there is only one wp_cp database. It is true, the options are different for each site but it seems that the points system is unique, meaning that if one user earns point into a site, he will have the points into any site.
Of course, this leaves a way for cheating, some site owners could trick the system to make points to use elswhere.
A simple solution I think of is to hardcode the points options by editing the code, then to make configuration and managememnt panels read-only.
Forum: Plugins
In reply to: [WP Resume] [Plugin: WP Resume] Sections orderWell, mistery solved. I need to save the sections order for every resume to get what I need. ??
No fault on the plugin.Forum: Plugins
In reply to: [WP Resume] [Plugin: WP Resume] Sections orderDoing a little var_dump I see that inside the database the order is actually not the one I was saving in the admin area. It is a bit strange because in the admin area I always see my preffered order of sections (so they are saved somewhere) but the frontend pulls another order.
Forum: Plugins
In reply to: [WP Resume] [Plugin: WP Resume] Sections orderAfter upgrading to version 2.2.3 the behaviour remains the same, still not getting the correct order in frontend.
Forum: Plugins
In reply to: [User meta shortcodes] [Plugin: User meta shortcodes] Invalid header@imeson Thanks, didn’t knew about that. I will update the plugin with your change.
Forum: Networking WordPress
In reply to: Big blog network, are those layers/hierarchy possible?I think WPMU Dev has a plugin for that – however it is premium plugin.
Forum: Plugins
In reply to: [Relevanssi - A Better Search] Database collationThanks
Thanks. I am not sure what strings come from Facebook and what from the plugin. I tried to use Codestyling Localization to check your localization but I could not find the plugin at all.
For 2 I am using Speaky, a child theme of twenty-ten. Switching to twenty-ten does not improve it. Looking for this string in twenty-ten show up nothing
Meanwhile I spoted another mistranslation: if someone else is the only who liked an article:
Adina Fulea and one other person like this.
comes in English
If I am among ones who liked an article:Richard Vencu ?i ?nc? o persoan? v? place.Nu ?mi place
is in Romanian but the translation is strange. It should sound like:Richard Vencu ?i ?nc? o persoan? plac acest articol.Nu ?mi place
In my opinion Facebook is still far to have a good translation engine. Many of the above problems appear with any Facebook integration plugin I have seen so far, still I encountered rare non-Wordpress sites that appears to handle the problem correctly.
The gettext calls in WordPress are much better.
Richard
I setup another test site I got and all seems fine so far. On the localization job please review this kind of translations
//Custom post type labels array $labels = array( 'name' => _x('Positions', 'post type general name'), 'singular_name' => _x('Resume Position', 'post type singular name'), 'add_new' => __('Add New Position'), 'add_new_item' => __('Add New Position'), 'edit_item' => __('Edit Position'), 'new_item' => __('New Position'), 'view_item' => __('View Position'), 'search_items' => __('Search Positions'), 'not_found' => __('No Positions Found'), 'not_found_in_trash' => __('No Positions Found in Trash'), 'parent_item_colon' => '', 'menu_name' => 'Resume', );
I think they need to be translated against your textdomain as well.
Hi,
I might be slow in checking the beta. I need to re-setup my dev site first.
I know how to localize, I will check this too,
Thanks,
RichardThe i18n is related, of course. If you plan to make your plugin translatable you need to take care of your hardcoded strings by including them in gettext calls.
The code in the other post on WPML should not break non-WPML users. WPML introduces a lot of filters on almost every aspect of WordPress so most of the queries return only current language results. The above get_terms() function is an exception this is why we need to filter it. However it is most probable if a new version of WPML will include this filter then we need to revert and delete this custom code.
When integrating with other plugins (of whom WPML might not be aware) we need to take care and add such filters for the non-standard queries.
Please take a look at wpml.org, I know they give free license of the commercial version for plugin developers so you can get your copy and your support access and play with it. In my opinion cooperating with such a plugin can only open the interest to non-English based WordPress users.
Hi Benjamin,
testing for WPML is done by this line
if (class_exists('SitePress'))
so to protect non-WPML users the above code should look like:
add_filter( 'list_terms_exclusions', 'exclude_the_terms' ); function exclude_the_terms($exclusions) { if (class_exists('SitePress')) { //if WPML we change the $exclusions global $sitepress; $exclusions .= $sitepress->exclude_other_terms( '', array( 'taxonomy' => 'wp_resume_section' ) ); } return $exclusions; }
Perfect. Thanks and congratulations for such a great plugin!