solved Changing default image sizes in Home Page Galleries, Profiles

Clay Gordon
Clay Gordon
@claygordon
11 years ago
744 posts
The default sizes are way huge for my taste. Is there a way to change them?

I would make a lot of sense for it to be a settable property in ACP in :

Media > Image Support
Media > Image Galleries
Profiles > User Profiles

My guess is that the sizes are set in the code somewhere but it's not intuitively obvious where they are set.

TIA,
:: Clay
updated by @claygordon: 02/01/15 09:36:01AM
brian
@brian
11 years ago
10,149 posts
There's a ton of different sizes you can set the images to, and lots of different places where they can be set, so it is all handled in the templates (not the ACP).

So this instance you will want to customize the skins/jrNingJa/jrGallery_index.tpl and skins/jrNingja/jrProfile_index.tpl - you can modify both of these from the "templates" tab of the NingJa skin in your ACP.

The NingJa skin however is responsive, which means it will adjust it's layout for both mobile and desktop - however this also means that you're a bit limited in the size you can make your images and have it look correct (i.e. still be responsive). Right now the jrGallery_index.tpl is setup to use the "col3" class, and with 12 "columns" on the page, you would have to move to a col2, which would make you go from 4 wide to 6 wide.

So to do that, everywhere you see "col3" change it to "col2", and in the {jrCore_list} function call near the bottom, change the "pagebreak" value from 12 to 18.

Hope this helps!


--
Brian Johnson
Founder and Lead Developer - Jamroom
https://www.jamroom.net
Clay Gordon
Clay Gordon
@claygordon
11 years ago
744 posts
Brian -

I was able to make the changes in skins/jrNingJa/jrGallery_index.tpl without any problems.

However, I don't see any similar mechanism inside "skins/jrNingja/jrProfile_index.tpl"

I did find a Col3 I could change to Col2 (and Col1 also works) in "skins/jrNingja/jrProfile_item_list.tpl" but there is no pagebreak call in this template. Where is that located? With thousands of members, I am sure one is needed.

In looking at the Image Galleries section on the home page I also don't see a way to change the sizes. However, I did notice what I think is a typo in the code. I am not sure how important it is but ....

defaul="All"} at the end of the clip below should probably be default="All"}. The HTML parser is stripping stuff so what follows is not an exact copy of what's in index.tpl.

{* BEGIN Latest Images Section *}
{if isset($_conf.jrNingja_latest_images) && $_conf.jrNingja_latest_images == 'on'}

{jrCore_lang skin=$_conf.jrCore_active_skin id="20" default="Latest"} {jrCore_lang module="jrGallery" id="25" default="Gallery"} {jrCore_lang skin=$_conf.jrCore_active_skin id="21" default="Images"}   {jrCore_lang skin=$_conf.jrCore_active_skin id="30" defaul="All"}
updated by @claygordon: 12/30/14 04:37:58PM
Clay Gordon
Clay Gordon
@claygordon
11 years ago
744 posts
Another typo?

skins/jrNingja/jrProfile_item_list.tpl

should crop="protrait" be crop="portrait" ?
douglas
@douglas
11 years ago
2,804 posts
thechocolatelife:
Another typo?

skins/jrNingja/jrProfile_item_list.tpl

should crop="protrait" be crop="portrait" ?

Yes, it should be portrait. I'll get that fixed up for the next release.

Thanks!


--

Douglas Hackney
Jamroom Team - Designer/Developer/Support
FAQ-Docs-Help Videos
douglas
@douglas
11 years ago
2,804 posts
thechocolatelife:
Brian -

I was able to make the changes in skins/jrNingJa/jrGallery_index.tpl without any problems.

However, I don't see any similar mechanism inside "skins/jrNingja/jrProfile_index.tpl"

I did find a Col3 I could change to Col2 (and Col1 also works) in "skins/jrNingja/jrProfile_item_list.tpl" but there is no pagebreak call in this template. Where is that located? With thousands of members, I am sure one is needed.

In looking at the Image Galleries section on the home page I also don't see a way to change the sizes. However, I did notice what I think is a typo in the code. I am not sure how important it is but ....

defaul="All"} at the end of the clip below should probably be default="All"}. The HTML parser is stripping stuff so what follows is not an exact copy of what's in index.tpl.

{* BEGIN Latest Images Section *}
{if isset($_conf.jrNingja_latest_images) && $_conf.jrNingja_latest_images == 'on'}

{jrCore_lang skin=$_conf.jrCore_active_skin id="20" default="Latest"} {jrCore_lang module="jrGallery" id="25" default="Gallery"} {jrCore_lang skin=$_conf.jrCore_active_skin id="21" default="Images"}   {jrCore_lang skin=$_conf.jrCore_active_skin id="30" defaul="All"}

The jrProfile_index.tpl uses the jrProfile_item_list.tpl by default, which is why you don't see a template parameter in the jrCore_list function in your jrProfile_index.tpl.

So you can change the page break in the jrProfile_index.tpl file, and the image size in the jrProfile_item_list.tpl for the Profile page.

I've also got the index.tpl typo fixed for the next release.

Hope this helps! :)


--

Douglas Hackney
Jamroom Team - Designer/Developer/Support
FAQ-Docs-Help Videos
Clay Gordon
Clay Gordon
@claygordon
10 years ago
744 posts
@Brian -

I was able to change the size of the gallery images but then I ran into the title length issue which was causing really ugly wraps and gaps. If I went down one size the string lengths I could use made everything nonsensical so I ended up going with the default size.

Search helps a lot!
updated by @claygordon: 01/01/15 02:26:25PM

Tags