• Resolved savedave

    (@savedave)


    Hi all,

    I am working on this site: https://www.nadaav.com/n – in particular I am playing with this page: https://www.nadaav.com/n/press

    I have a gallery on that page. At the moment I have it set so that the gallery objects link to the media files only. This is because when I like to the attachment page, which would be my preference, the page itself is really ugly.

    I would like to alter the attachment page to have a smaller title, less padding under the title, and no metadata. It is only the attachment pages and nothing else in my site that I would like to alter in this regard. I cannot find where in style.css code about this is, and so cannot work out what to put in my style.css in my child theme.

    This is the closest I can find in the style sheet:

    /* =Attachments
    ----------------------------------------------- */
    
    .image-attachment div.attachment {
    	background: #f9f9f9;
    	border: 1px solid #ddd;
    	border-width: 1px 0;
    	margin: 0 -8.9% 1.625em;
    	overflow: hidden;
    	padding: 1.625em 1.625em 0;
    	text-align: center;
    }
    .image-attachment div.attachment img {
    	display: block;
    	height: auto;
    	margin: 0 auto 1.625em;
    	max-width: 100%;
    }
    .image-attachment div.attachment a img {
    	border-color: #f9f9f9;
    }
    .image-attachment div.attachment a:focus img,
    .image-attachment div.attachment a:hover img,
    .image-attachment div.attachment a:active img {
    	border-color: #ddd;
    	background: #fff;
    }
    .image-attachment .entry-caption p {
    	font-size: 10px;
    	letter-spacing: 0.1em;
    	line-height: 2.6em;
    	margin: 0 0 2.6em;
    	text-transform: uppercase;
    }

    Is there anything in here that affects the appearance of the page I am talking about in the way I want to alter it?

    Thanks so much for your help with this.

Viewing 3 replies - 1 through 3 (of 3 total)
  • the template for the attachment pages is image.php where you could try and remove the postmeta;

    the title is formatted with .singular .entry-title {} which you could make more specific by using in your child theme .attachment.singular .entry-title {} to change the font-size etc..

    example:
    .attachment.singular .entry-title { font-size: 28px !important; }

    the !important is needed because you use !important already for a .singular .entry-title ..

    Thread Starter savedave

    (@savedave)

    thanks for this – I managed to resolve it adequately enough resolve this using similar if not identical code. If it breaks down, I will try what you have suggested. I think the over use of important is part of my problem!

    Hi –

    I have read all the other posts, and am not sure that anything there will fix my problem.

    I created an Image Gallery with six images on it, in two rows

    I would like each Image on the Image Gallery page to be larger, like 320×320. How do I do this? I also want as little white space as is possible between each image side-by-side.

    I would like the “attachment page” for each image to NOT look like a blog page. Specifically, my theme has “landing page” as a type, and I want the “attachment page” to be a “landing page.” No date, author name, heading, menus, footer, nothing. How do I do this? I have already created “landing pages” for each of the images. Is there a way to link these pages to the images in the Image Gallery? With a normal image, you can edit it and make it link to a page. Why can’t I do this with an Image in an Image Gallery?

    I also want to edit the font size of the Caption for each of the Images.

    I have done some pretty basic editing of the style.css, and have not broken anything. I am a former software engineer, in very different languages, but am, mostly, given specific code and places to put, comfortable with putting that in.

    Thanks for all your help.

    Sandy
    https://www.sandyeulitt.com, but in Maintenance Mode right now, as it is being overhauled.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘[twenty eleven] customising gallery attachment pages.’ is closed to new replies.