Skip to content
View in the app

A better way to browse. Learn more.

Web Designer Forum

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Button Alighnment

Featured Replies

Hi, 

I was wondering if anyone can help me, I am creating a page in which I have three images below each an explanation. Below the explanation I have added a "Learn More" button however I have been unable to align the buttons to the centre of each image. Below is the HTML and CSS that I am using. Can anyone advise me on the best way to do this? I have also added a screen shot of the images. 

<style>

button {
     background-color: #ebebeb;
}

</style>

<div class="container">
         <div class="row">
          <div class="col-lg-4">
        <img src="Original.JPG" style="width: 400px; height: 400px; padding: 40px"><p>Small individual cakes for a special surprise</p>
         <button type="button" class="btn btn-default">Learn More</button>
          </div>
          <div class="col-lg-4">
         <img src="Christening.jpg" style="width: 400px; height: 400px; padding: 40px"><p>Cakes for special celebrations</p>
         <br>
         <button type="button" class="btn btn-default" >Learn More</button>
          </div>
          <div class="col-lg-4">
          <img src="Horse.jpg" style="width: 400px; height: 400px; padding: 40px"><p>Theamed cakes for much loved hobbies</p>
         <button type="button" class="btn btn-default">Learn More</button>
          </div>
        </div>
        </div>

2087290584_Screenshot2018-05-2613_56_24.thumb.png.3df1388099c7103154a08b7058e42d8e.png


       

Can you link to the website. Much easier to see the css for the button.

But even without this there are number of problems with your code. For example, you have a fixed image width which means it won't display properly on small screens.

And the font size is way too small.

and semantically that "read more" link should be styled as an anchor i.e. a normal link because it goes to another page/section and doesn't perform an action like a button does e.g. the "send" button of a form for example. 

Good point. It shouldn't be a button.

And the image styles should be part of the stylesheet not inline.

Do you have your own website? If so just upload everything to a root folder. EG: www.mysite.com/newsite/

Create an account or sign in to comment

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.