Skip to content

Commit

Permalink
スマホでの表示崩れ対応
Browse files Browse the repository at this point in the history
  • Loading branch information
akagane99 committed Feb 9, 2018
1 parent 2692584 commit c0773ad
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
5 changes: 4 additions & 1 deletion View/PhotoAlbumPhotos/slide.ctp
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,10 @@ $srcPrefix = $this->Html->url(
if ($frameSetting['PhotoAlbumFrameSetting']['display_type'] == PhotoAlbumFrameSetting::DISPLAY_TYPE_SLIDE &&
isset($frameSetting['PhotoAlbumFrameSetting']['slide_height'])
) {
echo 'height:' . $frameSetting['PhotoAlbumFrameSetting']['slide_height'] . 'px';
// echo 'height:' . $frameSetting['PhotoAlbumFrameSetting']['slide_height'] . 'px';
echo 'max-height:' . $frameSetting['PhotoAlbumFrameSetting']['slide_height'] . 'px;';
list($width, $height) = getimagesize( WWW_ROOT . $photo['UploadFile']['photo']['path'] . $photo['UploadFile']['photo']['id'] . DS . $photo['UploadFile']['photo']['real_file_name']);
echo 'padding-top:' . ($height / $width * 100) . '%;';
}
?>
"
Expand Down
2 changes: 1 addition & 1 deletion webroot/css/photo_albums.css
Original file line number Diff line number Diff line change
Expand Up @@ -226,7 +226,7 @@
left: 10%;
}
.photo-albums-slide-photo {
height: 400px;
/*height: 400px;*/
width: 100%;
background-repeat: no-repeat;
background-position: center center;
Expand Down

0 comments on commit c0773ad

Please sign in to comment.