This topic is locked

Custom Button with icon ... Bootstrap

10/16/2016 8:11:32 PM
PHPRunner General questions
A
andreas.knab author

Hi All,
I wanted to Show a Icon on my custom Buttons in phpr 9 bootstrap. I created a table outside the container_add_delete Section on listpage to align them properly. I works for me by adding in html view maually a line with "SPAN" like this
<A class="rnr-button btn btn-custom1" id="On_Air1" href="#" typeid="ib">

<SPAN class="glyphicon glyphicon-cloud"> </SPAN>

<U>On&nbsp;Air</U><U></U>

</A>
It Looks really nice and I did some custom CSS to Change Colors and size.
Unfortunately each time i want to modify the button in design mode (like changing some Server or Client code) phpr scrambles the code to this:
<A class="rnr-button btn btn-custom1" id="test1" href="#" typeid="ib">

{$custom SPAN_CLASS__GLYPHICON_GLYPHICON_CLOUD___SPAN_U_ON_NBSP_AIRUU_U}

</A>
and if I do a next and back it Looks like this
<A class="rnr-button btn btn-dokstartonair" id="test1" href="#" typeid="ib">

</A>

</P>

{$custom __SPAN_CLASS
GLYPHICON_GLYPHICON_CLOUD__SPANU_ON_NBSP_AIRUU_U}

<A class="rnr-button btn btn-dokstartonair" id="test11" href="#" typeid="ib">

</A>

<P>

</P>

</TD>

<TD>
Nearly the same happens when i add a Icon in custom css. like:
.btn-dokstartreview:before{ content:' '; background-image: url('https://asprunner.com/forums/file.php?topicimage=1&fieldname=question&id=24226&image=1&table=forumtopics';); display: inline-block; width: 32px; height:32px; margin-right: 7px; vertical-align: -20%;}
I understand that if I do things manually like in html view phpr will not understand what I did.

The question is if there is a better way to add Icons to custom Buttons in custom css or if there is a solution to prevent phpr to Change the code when I click on the button ....
THX for your help

Andreas

H
headingwest 11/17/2016



The question is if there is a better way to add Icons to custom Buttons in custom css or if there is a solution to prevent phpr to Change the code when I click on the button ....


Hi Andreas, I have a similar problem where my html gets moved around and changed. Did you resolve this??

mbintex 11/18/2016



Hi Andreas, I have a similar problem where my html gets moved around and changed. Did you resolve this??


That´s due to automatic HTML code correction.
You can get rid of this if you Insert your custom HTML with PHP code insertion and "echo 'your custom html'"

A
andreas.knab author 11/20/2016

HI mbintex,
can you give an example please...
THX!!
Andreas