Hi,
This is a bug specific to mobile display. I will fix it for the next update.
You can edit the template rencontre_portrait_edit.php && rencontre_portrait.php and add the class “w3-mobile” && “w3-center” At the following places :
// Portrait_edit : Line 31
// Portrait : Line 25
<div class="w3-card w3-renc-blbg w3-center">
// Portrait_edit : Line 41
// Portrait : Line 35
<div class="w3-card w3-renc-blbg w3-margin-top w3-mobile" style="width:<?php echo $photoWidth;?>px">
You also can add w3-mobile on “portraitGrande” ID but image will be zoomed in and lose sharpness.
Otherwise, you will have to change the size of the “grande” images. See rencImgSize filter in FAQ or in Développeurs para here. It is better not to change the code. Use the filters.
Regards
Thread Starter
mand01
(@mand01)
Thank you for your responsiveness, Jacques.
Here is a screenshot of the result of the codes entered in the two templates: https://ibb.co/C7z2jPf
indeed, we see a centered image but which does not occupy the whole block. In addition this affects the thumbnails below which are also centered but this point can be resolved by displaying 10 thumbnails rather than 8.
As a result, going through the filters… I’m afraid of not managing the operation.
-
This reply was modified 3 years, 5 months ago by
mand01.
-
This reply was modified 3 years, 5 months ago by
mand01.
Thread Starter
mand01
(@mand01)
If I understood correctly about the filter “rencImgSize”,
function myRencImgSize($size) {
// 1. Modification des photos "-grande"
foreach($size as $k=>$v) {
if($v['label']=='-grande') $size[$k] = array('label'=>'-grande', 'width'=>300, 'height'=>300, 'quality'=>75);
}
// 2. Ajout du format "-wide"
$size[] = array('label'=>'-wide', 'width'=>400, 'height'=>180, 'quality'=>70);
//
return $size;
}
add_filter('rencImgSize', 'myRencImgSize', 10, 1);
It is that I have to enter this code directly in the file whose path is :
inc/rencontre_filter.php – fonction rencPhotoSize() ?
You will have to insert your function (filter) in the ‘functions.php’ file of your theme or create a specific, ultra-simple plugin hosting this function. If you don’t use a child theme, it’s better to create a plugin to avoid deleting your modification when updating the theme.
Aide en Français : Développeurs > Mise en place des modifications
Change size to 600×600 :
function myRencImgSize($size) {
foreach($size as $k=>$v) if($v['label']=='-grande') $size[$k] = array('label'=>'-grande', 'width'=>600, 'height'=>600, 'quality'=>75);
return $size;
}
add_filter('rencImgSize', 'myRencImgSize', 10, 1);
When done, you should click on “regenerate images”.
Regards
Thread Starter
mand01
(@mand01)
Thanks Jack for your help.
I chose the path of wisdom by creating a plugin, as you indicate. Unfortunately, these actions have not changed anything for the mobile display problem.
-
This reply was modified 3 years, 5 months ago by
mand01.