Solved

aligning image inside table cell

Posted on 2016-10-20
4
49 Views
Last Modified: 2016-10-21
I have this fiddle

https://jsfiddle.net/edx7ma5c/

It looks like this:

my fiddle
If you notice there is a table cell with this class it has a red border on this cell <td class="colstyle2">

How do I align my chrome image on the top right of this cell.
So even if I resize the width of my browser the image always stays at the top right of this cell with the red border.

So it would look like this:
desired alignment, top right of cell with class colstyle2
0
Comment
Question by:maqskywalker
  • 2
  • 2
4 Comments
 
LVL 55

Accepted Solution

by:
Julian Hansen earned 500 total points
ID: 41853255
.colstyle2, .colstyle2 td {
  vertical-align: top;
  text-align: right;
}
.colstyle2 table {
  width: 100%;
}

Open in new window

0
 
LVL 7

Expert Comment

by:DPatel
ID: 41853260
In HTML Part do the below :

alignimage.PNG
Both the method @Julian Hansen and @D Patel will do the same task.
0
 
LVL 7

Expert Comment

by:DPatel
ID: 41853275
No Assisted Solution...
0
 
LVL 55

Expert Comment

by:Julian Hansen
ID: 41853343
@D Patel,

Your solution relies on deprecated tags -  the use of the align attribute is not supported in HTML5. You are expected to use a CSS solution instead.
0

Featured Post

Free Tool: Postgres Monitoring System

A PHP and Perl based system to collect and display usage statistics from PostgreSQL databases.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Get Pixel color of the x and y axis Html without canvas 8 50
DataTables + iCheck + pagination Issue 2 41
VBScript on Html 15 47
Accessing specific element - DOM PHP HTML 8 34
CSS is a visual language used to classify objects and define rules about how they should be displayed. CSS skills aren’t restricted to developers anymore, there is a big benefit to having a basic understanding of the language, regardless of your occ…
Is your Office 365 signature not working the way you want it to? Are signature updates taking up too much of your time? Let's run through the most common problems that an IT administrator can encounter when dealing with Office 365 email signatures.
In this tutorial viewers will learn how to code links for mobile sites that, once clicked, send a call or text to a specified number. For a telephone link (once clicked, calls a number), begin with a normal "<a href=" link tag. For the href, specify…
In this tutorial viewers will learn how to embed Flash content in a webpage using HTML5. Ensure your DOCTYPE declaration is set to HTML5: "<!DOCTYPE html>": Use the <object> tag to embed Flash content.: To specify that the object is Flash content, d…

792 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question