wptechnology
Forum Replies Created
-
Very interesting, thanks for sharing. And thanks a lot for your speed.
Hello Tim,
Well I can’t remember where I have seen that adding @sourceLanguage in the comments made for the settings of the plugin, it helps explaining what is the primary language of this plugin.
I was hopping that you used it to know what kind of source language is the text.
Anyway, I have tried your following trick :function use_alternative_source_language( array $apis ){
foreach( $apis as $i => $api ){
$apis[$i]['src'] = 'fr';
}
return $apis;
}
add_filter('loco_api_providers','use_alternative_source_language',999,1);
And it works fine for the translation (meaning translator assume correctly that source language is French).
However, Loco Translate still write the mini “EN” tag when showing the source text in its interface ?Here is the next adventures of this crazy bug :
I took a look at the database, and find my 3 items in the posts database of wordpress.
So I have isolated them by a simple mysql command:SELECT * FROM
XXXXXXXposts
WHEREID
IN (1119,2188,1895);
So I have the view on my 3 services.
Using the phpMyAdmin inline editing facilities, I change the name and the slug of the services directly in the database to have the good name in the good order
(2188 was “Séance de Psychothérapie” renamed to “Séance de Neurothérapie”, etc…)
And TADA : the order stay the same, and with the service name I wanted to have…
So guys, I thing there’s a problem in the way you save the service information, because when I use the backoffice, the bug is here, and when I directly use PhpMyAdmin, it works the way I want….Unfortunately, from my side, I have deactivated the plugin and uninstalled it… Too bad that they don’t answer nor fix the bug…
Hi,
How can you make a custom tab to save their fields ?
I tried the given sample by UM source code without success :
https://docs.ultimatemember.com/article/65-extend-ultimate-member-account-page-with-custom-tabs-contentglobal $ultimatemember; $id = um_user('ID'); $names = [ 'pilot_total_hours','pilot_hours_cdb','pilot_hours_cdb_last_year','pilot_hours_cdb_3months','pilot_hours_since_ppl']; $fields = []; foreach($names as $name) $fields[$name] = UM()->builtin()->get_specific_field($name); $fields = apply_filters('um_account_secure_fields', $fields, get_current_user_id()); foreach( $fields as $key => $data ) $output2 .= UM()->fields()->edit_field( $key, $data ); echo str_ireplace("\\", "", $output2);
Any idea on this ?
Well in fact it seems that you also need to save the value in user_meta too,
so you need to add also this line :update_user_meta($user_id, 'name_of_field','its_value');
Found it.
To save / update field value into profile account, you need to call update_profile from user class :global $ultimatemember; $user_id = um_user('ID'); um_fetch_user($user_id); $toupdate[] = array('name_of_field' => 'its_value'); UM()->user()->update_profile($toupdate);
Answering to myself for people who will need this information:
If you’ve created (or want to create) a profile value to be saved & retrieved using um_user(‘name_of_field’); you can save it like this :
global $ultimatemember; $user_id = um_user('ID'); um_fetch_user($user_id); $toupdate[] = array('name_of_field' => 'its_value'); UM()->user()->update_profile($toupdate);
I’ve got exactly the same problem.
Seems like custom fields are not custom meta.
Meaning update_user_meta() save on extra information that can be retrieve with get_user_meta()
I’ve opened a topic to get the good information on how to save custom fields retrievable by using um_user(‘name_of_field’)
Will post the answer when I’ll found it.
Or if someone has it, please post it ?Hello,
I tried this on my own tab but in fact when I change some field values, then click on the “update” button, the form says that my account has been updated but the values aren’t saved.
Am I missing something ?Forum: Plugins
In reply to: [Contact Form 7] Validate form before sendingHi Takayuki.
Personaly I’ve tried to implement my own custom validation on text-fields but it seems like it is never called.
On this sample I’ve tested I’ve coded an extreme mode that reject every text field with an error, but nothing occured… The form is validated… :function wpcf7_voucher_code_validation_filter($result,$tag) { $tags = new WPCF7_Shortcode( $tags ); $result->invalidate( $tags, __( 'NOT VALID', 'mytest' )); return $result; } add_filter('wpcf7_validate_text', 'wpcf7_voucher_code_validation_filter', 20, 2); add_filter('wpcf7_validate_text*', 'wpcf7_voucher_code_validation_filter', 20, 2);
How is it possible ?
- This reply was modified 7 years, 6 months ago by wptechnology.
Forum: Reviews
In reply to: [Category Featured Images Extended] Unable to install : ErrorHi CK MacLeod,
And thanks for this so quick fix/correction.
You were right, the PHP version was set (for an unknown reason) to 5.3.3 which I changed, but just before I tried your last update and it was working correctly.
Thanks for that and sorry for the bad note… The good (to compensate the bad) is that it allows you to think about people that doesn’t upgrade their PHP ?? Will try to told friends to note your plugin if they use it too.
Regards.