Change Size of Projects Section Widget's Images

Hey guys,

I’m using the Illdy Theme for Wordpress, and it’s amazing.
But I would like to change the image size of the Projects Section images. I don’t want to use square images. I think it wouldn’t be a problem to change the CSS but the theme always uses the square image as the background of a project.
For example:
style=‘background-image: url(“linkToImage-476x476.png”);’

Is there a way to change the kind of the selected image, so just use “LinkToImage.png” without the size at the end?

Here is the link to my homepage: http://trainyour.team/

Best Regards,
Marco

Hey there,
Hope you’re doing well today

Unfortunately, that’s not going to be possible, however, you could add more width to the png images in order to make them square. After making them square, they’ll scale to the size of the project section and essentially work perfectly.

I’m sorry it isn’t able to display rectangular images, however, the idea above is probably the best way to get your rectangular images to show correctly.

Please feel free to let me know if there are any other questions that I may help with.

Best Regards,
Support

Thank you for your fast answer.

Meanwhile I found a workaround by myself. It very very dirty code, but it works. Maybe it will helps other users too.

At first you have to change the widget php (wp-content/plugins/illdy-companion/widgets/class-widgetproject.php)
Insert at line 60 the following code, override the creation of the ouput variable (see screenshot “php-code”, i couldn’t add php code to this answer, even if i declared it as code)

This causes that the theme use your original image size. After that you have to change the CSS like this:

#projects .widget_illdy_project {
	display: block;
	float:left;
}

#projects a.project {
	height: auto !important;
}

#projects a.project img{
	width: 100%;
	height: 100%
}

By the way I found a little bug in your customizer (I’m using Version: 2.0.1 of Illdy)
If I insert a URL into the project widget it works fine in the frontend, but after saving, it won’t be display in the customizer that a URL was stored in this field (see screenshot: “costumizer-bug”).

Hello there,

I am glad you found a solution to the issue.

Thank you for notifying us of this bug, I will go ahead and send this post to our development team so that a fix can be pushed out in a new update to the theme.

Best Regards,
Support

Hello,

I’m very interested in code that was used to change picture size in class-widgetproject.php, but attachements from this old post are already gone. Can admins repost it? Thank you.

Hi there

Sorry, I can’t repost it because apparently it’s lost, and the ticket is very old as well, may I know what is your problem?

Hi,

I’d like to make front pages projects pictures bigger than it’s in original theme. I see that now it divides full width of the page into 4 parts and adjusts project pictures accordingly (i.e. 1920px is the full width of the container and 25% of it is 480px - so projects pictures are resized to 480x480px). I’d like to have 2 pictures (instead of default 4), but with bigger size… let’s say 800 px or smth similar).

Unfortunately, cant find where it’s defined in theme code.

Thank you

Hi

On your website, you posted in the initial ticket you are using not our theme, if URL of your website is the same you have to contact the theme author, if its a new project with a new URL you have to post it here

I was not initial topic starter, so that website is not mine. I’m talking about http://home-staging.online/ website I’m trying to edit.

Hi there

That’s what happens when several users are posting in one ticket :)))
Ok, you may use this custom CSS to increase the size of the process pictures:

#projects .project {
height: 570px !important;
}