Page 1 of 1

How can I get an image to align to the bottom of the page?

Posted: Tue Jan 27, 2015 8:31 pm
by Patrick Kelly

I would like to place an image at the bottom of some pages, each page with a list. For most, the image stays at the bottom, but not all of my lists are very long, some only have 3 objects. On those pages, the image shows up right below the list, not at the bottom of the screen. Is there a functionality that would allow me to align an image to the bottom of the page? Maybe using JavaScript?


How can I get an image to align to the bottom of the page?

Posted: Tue Jan 27, 2015 9:10 pm
by Alena Prykhodko

Hello,

No. Better approach is to use CSS styles, especially when the image is static from Media Manager for instance.


How can I get an image to align to the bottom of the page?

Posted: Wed Jan 28, 2015 1:28 am
by Patrick Kelly

I'm only familiar with CSS in the context of building a webpage. How can I use the vertical-align property in Appery?


How can I get an image to align to the bottom of the page?

Posted: Wed Jan 28, 2015 7:46 am
by Evgene Karachevtsev

Hello Patrick,

You can create a new CSS file in Appery.io and add your code there.
http://devcenter.appery.io/documentat...
But please note that custom code is outside of the scope of our support.


How can I get an image to align to the bottom of the page?

Posted: Wed Jan 28, 2015 8:16 am
by M&M

Assuming that it is an Image component, you can do this

Place your image component on the screen

Add the following code to your CSS file. Replace the "myImgComponent" with your image component name. If you want the image to be centered in your page uncomment /* top: 50%; */ and comment bottom:0;

[dsid=myImgComponent] {
position: absolute;
/* top: 50%; */
left: 50%;
bottom:0;
width:100%;
-ms-transform: translate(-50%, -50%);
-webkit-transform: translate(-50%, -50%);
transform: translate(-50%, -50%);
}