Okay
  Print

How to adjust the height of the portfolio slider on portfolio single page?

=====================================================================

*NOTE: Below instruction is for the theme version prior to v2.0.0. If you are using the theme v2.0.0 and above, you can just upload the portfolio images and they will be automatically scaled down to fit the area without hard cropping anymore. It means that the height of the image will now be flexible depending on the uploaded image's proportion.

=====================================================================

1. Install and activate "Simple Image Sizes" plugin: http://wordpress.org/plugins/simple-image-sizes/

2. Install and activate "Regenerate Thumbnails" plugin: http://wordpress.org/plugins/regenerate-thumbnails/

3. Go to "Settings > Media" and add a new image size with dimension and also specify the "Crop?" to "Yes" or "No" depending on you whether to make WordPress crop the uploaded image or not. 

For example, create "new-portfolio-size" into the list with 1100px width and 900px height then define the Public name to be the same as "new-portfolio-size". 

(Tip: If you want to create a flexible height which will depend on its width, just set the height as "9999px" with "No" for the "Cropping?" option.)

4. Copy the Public name or the name of that created size (make sure they are the same) then open the "/uxb_templates/single-portfolio.php" theme file and find this code:

$image_size = 'uxb-port-single-landscape';

Change it to:

$image_size = 'new-portfolio-size';

Notice that it is the copied Public name here.

5. Go to "Tools > Regen. Thumbnails" and click the button to regenerate all images to make WordPress applies the new image size to all the uploaded ones.

6. Done. Now each slide of your portfolio single page (with "Landscape layout mode") should use the new defined dimension.

If you would like to customize the "Portrait layout mode", just use the same concept.