Adding HTML to the Integrated Store Footer

1

Hello everyone! Is that okay?

Recently, I started in the middle of the e-market and created my virtual store via Integral Store. I'm trying to make some adjustments to the template that I bought, adapting it to my needs, but I'm new to coding.

I'm trying to put some information in the footer of the page, but to no avail. Here is the code below:

$("#rodape .institucional .container .row-fluid .span4").append(
    "<li class=\"email\">" +
        "<p><i class=\"fa fa-envelope\" aria-hidden=\"true\"></i>
            [email protected] </p>" +
    "<li>" +
    "<li class=\"endereco-loja\">" +
        "<span class=\"endereco\">" + 
        "<p><i class=\"fa fa-home\" aria-hidden=\"true\"></i> Teste de Endereço </p>" +
        "</span>" +
    "<li>");

Can anyone help me to elucidate this mystery of why it is not working? Thanks and hugs.

    
asked by anonymous 06.09.2016 / 06:36

1 answer

1

Points for attention and possible improvements:

  • The email has several spaces before the text itself that conflict with the operation of the code, so it is not working. But this is resolved by eliminating all the previous spaces and joining it to the previous line so that everything is in a single line (without line breaks).

  • In order to avoid putting a \ fault bar in each quotation mark ( " " ) that you find in every class/id that appears, just type the HTML normally and at the end of each line change the symbol + for an exhaust bar - \ as you will see in the example below the final result of your corrected and working code.

  • There are elements that are not properly enclosed </> .

Code in operation:

$('#rodape').append(
'<li class="email">\
  <p><i class="fa fa-envelope" aria-hidden="true"></i>[email protected]</p>\
</li>\
<li class="endereco-loja">\
  <span class="endereco">\
    <p><i class="fa fa-home" aria-hidden="true"></i> Teste de Endereço </p>\
  </span>\
</li>');
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.0/jquery.min.js"></script><divid="rodape">
  Rodapé institucional container
</div>
    
06.09.2016 / 09:04