cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Frans_365CH
Advocate III
Advocate III

html text create a footer

Hi, need some help,

<style>
.footer {
  position: fixed;
  left: 0;
  bottom: 0;
  width: 100%;
  background-color: red;
  color: white;
  text-align: center;
}
</style>

<div class="footer">
  <p>Footer</p>
</div>

This don't work in the HTML text in PowerApps, how can i build a footer?

Or any idea

 

25 REPLIES 25
RandyHayes
Super User
Super User

@Frans_365CH 

The HTML control does not support styles like that.  You have to put them inline:\

<div style="position: fixed;  left: 0;  bottom: 0; width: 100%; background-color: red; color: white; text-align: center;">
  <p>Footer</p>
</div>

I hope this is helpful for you. 

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up below. Solved your problem? - Click on Accept as Solution below. Others seeking the same answers will be happy you did.
NOTE: My normal response times will be Mon to Fri from 1 PM to 10 PM UTC (and lots of other times too!)
Check out my PowerApps Videos too! And, follow me on Twitter @RandyHayes

Really want to show your appreciation? Buy Me A Cup Of Coffee!

Thank you, I didn't know that, I haven't got it working yet but continue....


footer.JPG

for everyone who reads this:

The use of double quote " results in an error in the HTML Text object of PowerApps.

I use this single quote ' and that works

This works: position must be absolute of course

<div style='position: absolute; left: 0; bottom: 0; width: 100%; background-Color: red; color: white; text-align: center;'> <p>Footer</p> </div>

But the the flow with the pdf converter do not support this 😞

ok.JPG

@Frans_365CH 

Duh...<*smacks head*>  Sorry about that.  I did just a copy paste from your posted formula and forgot to adjust double quotes to single because, yes, you need single quotes.  If, for some reason (which is not the case in HTML) you needed to actually have the double quotes, you would need to use "" (two double quotes).

 

Glad you are progressing.

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up below. Solved your problem? - Click on Accept as Solution below. Others seeking the same answers will be happy you did.
NOTE: My normal response times will be Mon to Fri from 1 PM to 10 PM UTC (and lots of other times too!)
Check out my PowerApps Videos too! And, follow me on Twitter @RandyHayes

Really want to show your appreciation? Buy Me A Cup Of Coffee!

<div style=""position: absolute; left: 0; bottom: 0; width: 100%;""> 

 

True, this works indeed! Funny!

I'm on a dead end, all HTML - PDF converters don't work. The "Footer" does not go to the foot of the page. 

Do you have any idea with which trick I can fix this? 

Thanks for all your time and alle the best.

 

 

 






 

@Frans_365CH 

Ah...converting to PDF!!

Here is the thing, the conversion tools to PDF do not recognize the inline styles properly.  To have an HTML presentation in an HTML Text control in PowerApps, you need to fiddle with the inline styles.  If you are going to convert to PDF, then you have to use the internal styles as well.  It's a royal pain, but once you have both in, it works pretty well.

If your goal is to convert to PDF, I would focus on that aspect...don't worry about getting it to look properly in PowerApps.  If your goal is to do both, then you have to do both internal and inline.

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up below. Solved your problem? - Click on Accept as Solution below. Others seeking the same answers will be happy you did.
NOTE: My normal response times will be Mon to Fri from 1 PM to 10 PM UTC (and lots of other times too!)
Check out my PowerApps Videos too! And, follow me on Twitter @RandyHayes

Really want to show your appreciation? Buy Me A Cup Of Coffee!

@RandyHayes @Frans_365CH 

Just curious, do both of you code your invoices from scratch or is there an HTML invoice builder somewhere I have not heard about, LOL 😉

 

---
Please click "Accept as Solution" if my post answered your question so that others may find it more quickly. If you found this post helpful consider giving it a "Thumbs Up."

@mdevaney 

I wish...from scratch for me.

However, I usually will do the invoice (or whatever) in Word or other editor and then export to HTML.  It gets me about 60-70% of the way there, then I just have to clean and polish into HTML.

 

I would love something more "automated".

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up below. Solved your problem? - Click on Accept as Solution below. Others seeking the same answers will be happy you did.
NOTE: My normal response times will be Mon to Fri from 1 PM to 10 PM UTC (and lots of other times too!)
Check out my PowerApps Videos too! And, follow me on Twitter @RandyHayes

Really want to show your appreciation? Buy Me A Cup Of Coffee!

Helpful resources

Announcements
PA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

This training provides practical hands-on experience in creating Power Apps solutions in a full-day of instructor-led App creation workshop.

PWREduCon768x460.png

Join us at PWR EduCon - A Power Platform Conference

Learn from the top Power BI, Power Apps, Power Automate & Power Virtual Agents experts!

Top Solution Authors
Top Kudoed Authors
Users online (3,262)