lavijain
Forum Replies Created
-
Forum: Plugins
In reply to: [Meta Box] how to use meta boxhttps://themergency.com/wordpress-meta-box-roundup/
here u can find everything about it…
i am using wp alterna theme i have downloaded alll the plugins from wordpress i am using latest wp version and i guess all the other plugins i have added are latest as i added them from wp site ..
i guess problem is here where i shown in code the file can’t be uploaded …
i guess problem arises here in bold lines..
// Handles image field type saving.
if (isset($_FILES[‘field_’.$field_id]) && $_FILES[‘field_’.$field_id][‘size’] > 0) {
$field = new BP_XProfile_Field($field_id);
if ($field->type == ‘image’) {
$ext_allowed = array(‘jpg’,’jpeg’,’gif’,’png’);
apply_filters(‘images_ext_allowed’, $ext_allowed);
} elseif ($field->type == ‘file’) {
$ext_allowed = array(‘doc’,’docx’,’pdf’);
apply_filters(‘files_ext_allowed’, $ext_allowed);
}$ext = strtolower(substr($_FILES[‘field_’.$field_id][‘name’], strrpos($_FILES[‘field_’.$field_id][‘name’],’.’)+1));
if (in_array($ext, $ext_allowed)) {
require_once( ABSPATH . ‘/wp-admin/includes/file.php’ );
add_filter( ‘upload_dir’, ‘bxcft_profile_upload_dir’, 10, 1 );
$_POST[‘action’] = ‘wp_handle_upload’;
$uploaded_file = wp_handle_upload( $_FILES[‘field_’.$field_id] );
$destino = str_replace(‘0’, $user_id, $uploaded_file[‘file’]);
$aux = explode(“/”, $destino);
if (!file_exists(str_replace(‘/’.$aux[count($aux)-1], ”, $destino))) {
mkdir(str_replace(‘/’.$aux[count($aux)-1], ”, $destino));
}
copy($uploaded_file[‘file’], $destino);
unlink($uploaded_file[‘file’]);
$value = str_replace($uploads[‘baseurl’], ”, str_replace(‘0’, $user_id, $uploaded_file[‘url’]));
}
} else {
if ($field->type == ‘image’ && (!isset($_POST[‘field_’.$field_id.’_deleteimg’]) || !$_POST[‘field_’.$field_id.’_deleteimg’]) && isset($_POST[‘field_’.$field_id.’_hiddenimg’]) && $_POST[‘field_’.$field_id.’_hiddenimg’] != ”) {
$value = $_POST[‘field_’.$field_id.’_hiddenimg’];
}
elseif ($field->type == ‘file’ && (!isset($_POST[‘field_’.$field_id.’_deletefile’]) || !$_POST[‘field_’.$field_id.’_deletefile’]) && isset($_POST[‘field_’.$field_id.’_hiddenfile’]) && $_POST[‘field_’.$field_id.’_hiddenfile’] != ”) {
$value = $_POST[‘field_’.$field_id.’_hiddenfile’];
}
}xprofile_set_field_data( $field_id, $user_id, $value );
}
}
}
}
add_action(‘bp_core_signup_user’, ‘bxcft_signup_user’, 10, 5);function bxcft_profile_upload_dir( $upload_dir, $user_id=0 ) {
if ($user_id == 0)
$user_id = bp_displayed_user_id();
$profile_subdir = ‘/profiles/’ . $user_id;$upload_dir[‘path’] = $upload_dir[‘basedir’] . $profile_subdir;
$upload_dir[‘url’] = $upload_dir[‘baseurl’] . $profile_subdir;
$upload_dir[‘subdir’] = $profile_subdir;return $upload_dir;
}someone plz help me out…
what i see is the image when i upload it goes to a path
https://www.mysite.com/wp-content/uploads/profiles/newcreatedfolder/image.png
this is how it is going when i see that it is having problem about at the path image upload not working i added the image manually and i see that image working now but i want upload to work itself where is the problem..
please anyone plz help me out …
is there none who has resolved the issue or i should not use this plugin…
plz someone help…
Forum: Plugins
In reply to: [HMS Testimonials] testimonial form(not getting data )so how can i solve this cache problem in wordpress ..
Forum: Plugins
In reply to: [HMS Testimonials] testimonial form(not getting data )no as u have told me when i use the form on simple page and submit form it shows success mesaage and when i approve the testimonial and get page refreshed it again show me the success msg
i closed the window reopen it but it is showing me the same success message that means a user can submit it only once by a browser if i open it using another browser at the same time it shows form .
is this a caching problem or any browser problem
what should i do..
help plz…
??
Forum: Plugins
In reply to: [HMS Testimonials] testimonial form(not getting data )thanks but what if i want to make it work on lightbox ..
no user is going to reopen his window..
i am trying for it…
Forum: Plugins
In reply to: [HMS Testimonials] testimonial form(not getting data )so any idea how to make it work and one more thing doesn’t matter how many times i refresh the site but it just stick on the message testimonial is submitted…
i am not getting the form again..
it is having problems ..
plz give any idea to sort this out can i add some extrra code on site and apply js on that ..
or what is the option for this..
Forum: Plugins
In reply to: [HMS Testimonials] testimonial form(not getting data )okay how to get the successs msg just below the form when i submit it as we got in contact form 7 .. what should i need to do for that..
plz give me any idea about this as any user will not go to see the popup again to see his succees msg..
Forum: Plugins
In reply to: [HMS Testimonials] testimonial form(not getting data )ok it’s working…..
thanks…
?? ??
i was logged in as admin and trying to add testimonials may be becoz of that it was not working…
is this so….
Forum: Plugins
In reply to: [HMS Testimonials] testimonial form(not getting data )hey you have added a testimonial why i was not getting when i do the same….
Forum: Plugins
In reply to: [HMS Testimonials] testimonial form(not getting data )submit testimonial here
on link then may be you grab the problem by watching it…
Forum: Plugins
In reply to: [HMS Testimonials] testimonial form(not getting data )that is same i expected but not working…
i am not getting any mail when i submit any form i used recaptcha also and i can’t see them on list i have only the testimonials(only 2) which i added from backend so what should i do now….where is the problem in it i searched all settings but nothing found..
can u help me more about it…
we will continue on this thread only i added my topic there…so anyone can response soon..
Forum: Reviews
In reply to: [HMS Testimonials] Testimonial for hms testimonialsthat is same i expected but not working…
i am not getting any mail when i submit any form i used recaptcha also and i can’t see them on list i have only the testimonials(only 2) which i added from backend so what should i do now….where is the problem in it i searched all settings but nothing found..
can u help me more about it…