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.

CSS image/text...

Featured Replies

Hi guys,

 

How can I float a image to the left with text next to it and have it aligned properly? While using <h2> tag as a title in the text.

 

So far without using divs for each part, the text appears higher than the image.

 

<img src="images/quick-to-join.jpg" style="margin-right:10px; vertical-align:text-top; float:left;" /><h2>Lorem Ipsum...</h2>
<p>There are many variations of passages of Lorem Ipsum available, but the majority have suffered <span class="orange">alteration</span> in some form, by injected humour.<br /> <br />
<span class="orange">MORE</span><img src="images/arrow-blue.jpg" style="margin-left:5px; vertical-align:text-bottom"/></p>

post-22857-0-28890900-1374059594_thumb.png

Is there a reason you're using inline styles? Is this design for an email?

 

I'd use divs for this mark up, but you could just add top padding to <h2>.

I have used an image from my PC; it is going well both image and text are equally aligned. However, if you have a problem try to-margin for text.

inline style sheet is the best way to do this. i personally use inline style sheet method for the same problem and finally i got solution for using this technique.

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.