donmik
Forum Replies Created
-
I have just tested it with latest versions and I can’t see this error. What fields are you using?
This issue is related to this too.
I hope next monday I can release 2.4.6 to fix the autolink errors with Image, Files and multiselector field types.
Forum: Plugins
In reply to: [Buddypress Xprofile Custom Fields Type] Images field broken on front endYou’re right. This is due to the last update where I changed my plugin to make the autolink feature from buddypress work.
Images and Files cannot work with this feature because you cannot search (for now at least) by an image or file. I hope next monday to release a new update which may solve this error but maintain the autolink feature working for the rest of the fields.
Thanks!
Forum: Plugins
In reply to: [Buddypress Xprofile Custom Fields Type] Custom Post/Taxonomy – AutolinkLet me know if autolink is working as expected when you update to version 2.4.5.
Thanks!
add_filter( 'bp_get_the_profile_field_birthdate', 'my_profile_field_birthdate', 10, 2); function my_profile_field_birthdate($html, $type) { // Check if $type is "year" and not "day" or "month". if ($type === 'year') { // Modify to only an option with a leap-year like 2016. $html = '<option value="2016">2016</option>'; } return $html; }Forum: Plugins
In reply to: [Buddypress Xprofile Custom Fields Type] Custom Post/Taxonomy – AutolinkYou are right, I was not aware of the new Autolink Box feature from Buddypress. My plugin is breaking this new feature. In next update (2.4.5) I will solve this. I hope I can release this update next monday.
If you need this right now, you can modify a line in my plugin waiting for my update.
Replace line 43 of bp-xprofile-custom-fields-type.php:
add_filter( 'bp_get_the_profile_field_value', array($this, 'bxcft_get_field_value'), 10, 3 );With:
add_filter( 'bp_get_the_profile_field_value', array($this, 'bxcft_get_field_value'), 8, 3 );Ummm, Your best chance is possibly hide the year component with css and then use the filter to modify the way the birthdate is displayed if you want.
You need also to fix the year to a leap-year to be sure you have 29 days in february just in case somebody needs it. You can probably achieve this with javascript or using the filter: “bp_get_the_profile_field_birthdate” you can change the selected year value.
Forum: Plugins
In reply to: [Buddypress Xprofile Custom Fields Type] Minimum birthdate ageOk, I understand what you want is not allow users to enter invalid birthdates… What I did is validate the birthdate with PHP. So when you send the birthdate, if the user is less than 18, the page will display an error saying the user must be at least 18 and the registration will fail.
I will try to update my plugin and see if I can fill the dropdown boxes only with correct birthdates.
Solved in version 2.4.4. Thanks!
Forum: Plugins
In reply to: [Buddypress Xprofile Custom Fields Type] Minimum birthdate ageI’ve added a new option to birthdate fields. You can now choose a minimum age. Hope this help you. Check version 2.4.4.
Forum: Plugins
In reply to: [Buddypress Xprofile Custom Fields Type] Modify Birthdate in the edit formWow! If the only thing you need is to change order of dropdown select boxes, it’s much easier to do it with javascript or maybe just css. Rewrite my class is possible but it’s too much work for this task.
With only css:
.bxcft-birthdate-month { float: left; }You will see month, day, year.
With javascript it’s a bit more code:
jQuery(function($) { $('.bxcft-birthdate-month').insertAfter($('.bxcft-birthdate-month').parent().find('label')); });Forum: Plugins
In reply to: [Buddypress Xprofile Custom Fields Type] Fields not showingRead the FAQ please, check your theme.
Forum: Plugins
In reply to: [Buddypress Xprofile Custom Fields Type] Custom Post/Taxonomy – AutolinkI don’t know this “autolink” function. Can you explain it to me maybe with an example?
Forum: Plugins
In reply to: [Buddypress Xprofile Custom Fields Type] Wrap 'Required' in a spanYou can use this hook “bxcft_field_label”.
Something like this should work:
function my_field_label($label) { return str_replace("(required)", "<span>(required)</span>", $label); } add_filter('bxcft_field_label', 'my_field_label');Forum: Plugins
In reply to: [Buddypress Xprofile Custom Fields Type] Buddypress Xprofile Phone Type FieldI’m sorry but this code is not from my plugin. There is no “phone” field in my plugin, so maybe someone added this to my plugin in your website but it’s not from the official plugin. Download it if you want and you will see there is no “phone” field.