Ir para conteúdo

POWERED BY:

Arquivado

Este tópico foi arquivado e está fechado para novas respostas.

arldin

como faço para aparecer o R$

Recommended Posts

Olha amigos estou com um pequeno poblema quando eu coloco a função de noeda para aparewcer nos totais ele não faz a soma no totalgeral, quando coloco no totalgeral não aparece nos outros se eu coloco nos dois ele não ne da a soma do totalgeral como posso resolver

 

 

Este e o script e a pagina

 

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">

<HTML><HEAD><TITLE>Formulario de Pedido</TITLE>

<META http-equiv=Content-Type content="text/html; charset=windows-1252">

<script language=javascript>

 

var nItens = 39;

 

function recalculaTotais (frm)

{

var total = 0;

for (var i = 0; i < nItens; i++)

{

frm.total.value = Math.round(frm.preco.value * frm.quant.value * 100+"."+"00") / 100+"."+"00";

total += parseFloat(frm.total.value);

}

frm.totalgeral.value = forma(total);

}

function forma(num) {

num = num.toString().replace(/\$|\,/g,'');

if(isNaN(num)) num = "0";

cents = Math.floor((num*100+0.5)%100);

num = Math.floor((num*100+0.5)/100).toString();

if(cents < 10) cents = "0" + cents;

for (var i = 0; i < Math.floor((num.length-(1+i))/3); i++)

num = num.substring(0,num.length-(4*i+3))+','+num.substring(num.length-(4*i+3));

return ("R$ " + num + "." + cents);

}

</SCRIPT>

 

<META content="MSHTML 6.00.2900.3354" name=GENERATOR>

<FORM id=formEmail name=formEmail action=envia1.asp method=post></HEAD>

<BODY background=Arldinartfest5/index_arquivos/image306.gif>

<H1 TYPE="Hidden">Formulario de Pedido<FONT color=#0000ff

size=1></TD> <INPUT id=emaild type=hidden value=arldin@arldinartfest.com.br

name=emaild></FONT><TD width="150"></TD></TR><FONT size=1><FONT color=#0000ff>

</FONT></FONT></H1><FORM name="f">

<TABLE style="WIDTH: 599px; HEIGHT: 315px">

<TBODY>

<TR>

<TH>Imagen

<TH>Códico

<TH>Produto

<TH>Preço

<TH>Quantidade

<TH>Total

<TR>

<TD><IMG style="WIDTH: 40px; HEIGHT: 31px" height=35 alt=""

src="Arldin/baixados1/001.JPG" width=47>

<TD>Cód.001

<TD TYPE="Hidden" READONLY="0">Homem Aranha

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[0].focus() type=hidden size=6 value=10.00

name=preco1>

<TD SIZE="8"><INPUT id=quant onchange=recalculaTotais(this.form) size=4

name=quant1>

<TD><INPUT id=total onfocus=this.form.quant[1].focus() size=8 value=R$0.00

name=total1>

<TR>

<TD><IMG style="WIDTH: 41px; HEIGHT: 33px" height=31 alt="" hspace=0

src="Arldin/baixados1/002.JPG" width=40 border=0>

<TD>Cód.002

<TD READONLY="1" SIZE="8" VALUE="10.00">Flamengo

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[1].focus() type=hidden size=6 value=10.00

name=preco2>

<TD SIZE="8" VALUE="R$0.00"><INPUT id=quant

onchange=recalculaTotais(this.form) size=4 name=quant2>

<TD><INPUT id=total onfocus=this.form.quant[2].focus() size=8 value=R$0.00

name=total2>

<TR>

<TD><IMG style="WIDTH: 37px; HEIGHT: 36px" height=31 alt="" hspace=0

src="Arldin/baixados1/003.jpg" width=40 border=0>

<TD>Cód.003

<TD>Vasco

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[2].focus() type=hidden size=6 value=10.00

name=preco3>

<TD SIZE="8"><INPUT id=quant onchange=recalculaTotais(this.form) size=4

name=quant3>

<TD><INPUT id=total onfocus=this.form.quant[3].focus() size=8 value=R$0.00

name=total3>

<TR>

<TD><IMG style="WIDTH: 35px; HEIGHT: 36px" height=31 alt="" hspace=0

src="Arldin/baixados1/004.jpg" width=40 border=0>

<TD>Cód.004

<TD>Botafogo

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[3].focus() type=hidden size=6 value=10.00

name=preco4>

<TD SIZE="8"><INPUT id=quant onchange=recalculaTotais(this.form) size=4

name=quant4>

<TD><INPUT id=total onfocus=this.form.quant[4].focus() size=8 value=R$0.00

name=total4>

<TR>

<TD><IMG style="WIDTH: 40px; HEIGHT: 39px" height=31 alt="" hspace=0

src="Arldin/baixados1/005.jpg" width=40 border=0>

<TD>Cód.005

<TD>Fluminense

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[4].focus() type=hidden size=6 value=10.00

name=preco5>

<TD SIZE="8"><INPUT id=quant onchange=recalculaTotais(this.form) size=4

name=quant5>

<TD><INPUT id=total onfocus=this.form.quant[5].focus() size=8 value=R$0.00

name=total5>

<TR>

<TD><IMG height=44 alt="" src="Arldin/baixados1/006.jpg" width=36>

<TD>Cód.006

<TD>Corintians

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[5].focus() type=hidden size=6 value=10.00

name=preco6>

<TD SIZE="8"><INPUT id=quant onchange=recalculaTotais(this.form) size=4

name=quant6>

<TD><INPUT id=total onfocus=this.form.quant[6].focus() size=8 value=R$0.00

name=total6>

<TR>

<TD><IMG height=40 alt="" src="Arldin/baixados1/007.jpg" width=39>

<TD>Cód.007

<TD>São Paulo

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[6].focus() type=hidden size=6 value=10.00

name=preco7>

<TD SIZE="8"><INPUT id=quant onchange=recalculaTotais(this.form) size=4

name=quant7>

<TD><INPUT id=total onfocus=this.form.quant[7].focus() size=8 value=R$0.00

name=total7>

<TR>

<TD><IMG height=46 alt="" src="Arldin/baixados1/008.jpg" width=42>

<TD>Cód.008

<TD>Santos

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[7].focus() type=hidden size=6 value=10.00

name=preco8>

<TD SIZE="4"><INPUT id=quant onchange=recalculaTotais(this.form) size=4

name=quant8>

<TD><INPUT id=total onfocus=this.form.quant[8].focus() size=8 value=R$0.00

name=total8>

<TR>

<TD><IMG height=46 alt="" src="Arldin/baixados1/009.jpg" width=41>

<TD>Cód.009

<TD>Palmeiras

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[8].focus() type=hidden size=6 value=10.00

name=preco9>

<TD SIZE="8"><INPUT id=quant onchange=recalculaTotais(this.form) size=4

name=quant9>

<TD><INPUT id=total onfocus=this.form.quant[9].focus() size=8 value=R$0.00

name=total9>

<TR>

<TD><IMG style="WIDTH: 50px; HEIGHT: 37px" height=46 alt=""

src="Arldin/baixados1/010.jpg" width=50>

<TD>Cód.010

<TD>Atlético MG

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[9].focus() type=hidden size=6 value=10.00

name=preco10>

<TD SIZE="8"><INPUT id=quant onchange=recalculaTotais(this.form) size=4

name=quant10>

<TD><INPUT id=total onfocus=this.form.quant[10].focus() size=8

value=R$0.00 name=total10>

<TR>

<TD><IMG height=41 alt="" src="Arldin/baixados1/011.jpg" width=45>

<TD>Cód.011

<TD>Cruzeiro

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[10].focus() type=hidden size=6 value=10.00

name=preco11>

<TD SIZE="8"><INPUT id=quant onchange=recalculaTotais(this.form) size=4

name=quant11>

<TD><INPUT id=total onfocus=this.form.quant[11].focus() size=8

value=R$0.00 name=total11>

<TR>

<TD><IMG height=46 alt="" src="Arldin/baixados1/012.jpg" width=47>

<TD>Cód.012

<TD>Atlético PR

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[11].focus() type=hidden size=6 value=10.00

name=preco12>

<TD SIZE="8"><INPUT id=quant onchange=recalculaTotais(this.form) size=4

name=quant12>

<TD><INPUT id=total onfocus=this.form.quant[12].focus() size=8

value=R$0.00 name=total12>

<TR>

<TD><IMG height=47 alt="" src="Arldin/baixados1/013.jpg" width=46>

<TD>Cód.013

<TD>Coritiba

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[12].focus() type=hidden size=6 value=10.00

name=preco13>

<TD SIZE="8"><INPUT id=quant onchange=recalculaTotais(this.form) size=4

name=quant13>

<TD><INPUT id=total onfocus=this.form.quant[13].focus() size=8

value=R$0.00 name=total13>

<TR>

<TD><IMG height=44 alt="" src="Arldin/baixados1/014.jpg" width=35>

<TD>Cód.014

<TD>Paraná

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[13].focus() type=hidden size=6 value=10.00

name=preco14>

<TD SIZE="8"><INPUT id=quant onchange=recalculaTotais(this.form) size=4

name=quant14>

<TD><INPUT id=total onfocus=this.form.quant[14].focus() size=8

value=R$0.00 name=total14>

<TR>

<TD><IMG height=37 alt="" src="Arldin/baixados1/015.jpg" width=41>

<TD>Cód.015

<TD>Internacional

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[14].focus() type=hidden size=6 value=10.00

name=preco15>

<TD SIZE="8"><INPUT id=quant onchange=recalculaTotais(this.form) size=4

name=quant15>

<TD><INPUT id=total onfocus=this.form.quant[15].focus() size=8

value=R$0.00 name=total15>

<TR>

<TD><IMG height=37 alt="" src="Arldin/baixados1/016.jpg" width=44>

<TD>Cód.016

<TD>Grêmio

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[15].focus() type=hidden size=6 value=10.00

name=preco16>

<TD SIZE="8"><INPUT id=quant onchange=recalculaTotais(this.form) size=4

name=quant16>

<TD><INPUT id=total onfocus=this.form.quant[16].focus() size=8

value=R$0.00 name=total16>

<TR>

<TD><IMG height=48 alt="" src="Arldin/baixados1/017.jpg" width=42>

<TD>Cód.017

<TD>Sel. Brasileira

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[16].focus() type=hidden size=6 value=10.00

name=preco17>

<TD SIZE="8"><INPUT id=quant onchange=recalculaTotais(this.form) size=4

name=quant17>

<TD><INPUT id=total onfocus=this.form.quant[17].focus() size=8

value=R$0.00 name=total17>

<TR>

<TD><IMG height=44 alt="" src="Arldin/baixados1/018.jpg" width=63>

<TD>Cód.018

<TD>Baby Disney

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[17].focus() type=hidden size=6 value=10.00

name=preco18>

<TD SIZE="8"><INPUT id=quant onchange=recalculaTotais(this.form) size=4

name=quant18>

<TD><INPUT id=total onfocus=this.form.quant[18].focus() size=8

value=R$0.00 name=total18>

<TR>

<TD><IMG height=38 alt="" src="Arldin/baixados1/019.JPG" width=52>

<TD>Cód.019

<TD>Branca de Neve

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[18].focus() type=hidden size=6 value=10.00

name=preco19>

<TD SIZE="8"><INPUT id=quant onchange=recalculaTotais(this.form) size=4

name=quant19>

<TD><INPUT id=total onfocus=this.form.quant[19].focus() size=8

value=R$0.00 name=total19>

<TR>

<TD><IMG height=52 alt="" src="Arldin/baixados1/020.JPG" width=50>

<TD>Cód.020

<TD>Cinderela

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[19].focus() type=hidden size=6 value=10.00

name=preco20>

<TD SIZE="8"><INPUT id=quant onchange=recalculaTotais(this.form) size=4

name=quant20>

<TD><INPUT id=total onfocus=this.form.quant[20].focus() size=8

value=R$0.00 name=total20>

<TR>

<TD><IMG height=43 alt="" src="Arldin/baixados1/021.JPG" width=75>

<TD>Cód.021

<TD>Turma da Mônica

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[20].focus() type=hidden size=6 value=10.00

name=preco21>

<TD SIZE="4"><INPUT id=quant onchange=recalculaTotais(this.form) size=4

name=quant21>

<TD><INPUT id=total onfocus=this.form.quant[21].focus() size=8

value=R$0.00 name=total21>

<TR>

<TD><IMG height=51 alt="" src="Arldin/baixados1/022.JPG" width=49>

<TD>Cód.022

<TD>Palhaço

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[21].focus() type=hidden size=6 value=10.00

name=preco22>

<TD SIZE="8"><INPUT id=quant onchange=recalculaTotais(this.form) size=4

name=quant22>

<TD><INPUT id=total onfocus=this.form.quant[22].focus() size=8

value=R$0.00 name=total22>

<TR>

<TD><IMG height=54 alt="" src="Arldin/baixados1/023.JPG" width=50>

<TD>Cód.023

<TD>Batmam

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[22].focus() type=hidden size=6 value=10.00

name=preco23>

<TD SIZE="8"><INPUT id=quant onchange=recalculaTotais(this.form) size=4

name=quant23>

<TD><INPUT id=total onfocus=this.form.quant[23].focus() size=8

value=R$0.00 name=total23>

<TR>

<TD><IMG height=56 alt="" src="Arldin/baixados1/024.jpg" width=52>

<TD>Cód.024

<TD>Baby Looney Tuber

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[23].focus() type=hidden size=6 value=10.00

name=preco24>

<TD SIZE="8"><INPUT id=quant onchange=recalculaTotais(this.form) size=4

name=quant24>

<TD><INPUT id=total onfocus=this.form.quant[24].focus() size=8

value=R$0.00 name=total24>

<TR>

<TD><IMG style="WIDTH: 46px; HEIGHT: 38px" height=31 alt="" hspace=0

src="Arldin/baixados1/025.JPG" width=40 border=0>

<TD>Cód.025

<TD>Sherek

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[24].focus() type=hidden size=6 value=10.00

name=preco25>

<TD SIZE="8"><INPUT id=quant onchange=recalculaTotais(this.form) size=4

name=quant25>

<TD><INPUT id=total onfocus=this.form.quant[25].focus() size=8

value=R$0.00 name=total25>

<TR>

<TD><IMG height=39 alt="" src="Arldin/baixados1/026.jpg" width=48>

<TD>Cód.026

<TD VALUE="R$0.00">Nemo

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[25].focus() type=hidden size=6 value=10.00

name=preco26>

<TD SIZE="8"><INPUT id=quant onchange=recalculaTotais(this.form) size=4

name=quant26>

<TD><INPUT id=total onfocus=this.form.quant[26].focus() size=8

value=R$0.00 name=total26>

<TR>

<TD><IMG height=55 alt="" src="Arldin/baixados1/027.jpg" width=44>

<TD>Cód.027

<TD>Barbie

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[26].focus() type=hidden size=6 value=10.00

name=preco27>

<TD SIZE="8"><INPUT id=quant onchange=recalculaTotais(this.form) size=4

name=quant27>

<TD><INPUT id=total onfocus=this.form.quant[27].focus() size=8

value=R$0.00 name=total27>

<TR>

<TD><IMG style="WIDTH: 41px; HEIGHT: 54px" height=62 alt=""

src="Arldin/baixados1/028.JPG" width=42>

<TD>Cód.028

<TD>Pica Pau

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[27].focus() type=hidden size=6 value=10.00

name=preco28>

<TD SIZE="8"><INPUT id=quant onchange=recalculaTotais(this.form) size=4

name=quant28>

<TD><INPUT id=total onfocus=this.form.quant[28].focus() size=8

value=R$0.00 name=total28>

<TR>

<TD><IMG style="WIDTH: 56px; HEIGHT: 45px" height=47 alt=""

src="Arldin/baixados1/029.jpg" width=62>

<TD>Cód.029

<TD>Os Incriveis

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[28].focus() type=hidden size=6 value=10.00

name=preco29>

<TD SIZE="8"><INPUT id=quant onchange=recalculaTotais(this.form) size=4

name=quant29>

<TD><INPUT id=total onfocus=this.form.quant[29].focus() size=8

value=R$0.00 name=total29>

<TR>

<TD><IMG style="WIDTH: 54px; HEIGHT: 40px" height=42 alt=""

src="Arldin/baixados1/030.jpg" width=63>

<TD>Cód.030

<TD>Fámilia Dinossauro

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[29].focus() type=hidden size=6 value=10.00

name=preco30>

<TD SIZE="8"><INPUT id=quant onchange=recalculaTotais(this.form) size=4

name=quant30>

<TD><INPUT id=total onfocus=this.form.quant[30].focus() size=8

value=R$0.00 name=total30>

<TR>

<TD><IMG style="WIDTH: 52px; HEIGHT: 38px" height=40 alt=""

src="Arldin/baixados1/031.JPG" width=59>

<TD>Cód.031

<TD>Ursinhos Carinhosos

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[30].focus() type=hidden size=6 value=10.00

name=preco31>

<TD SIZE="8"><INPUT id=quant onchange=recalculaTotais(this.form) size=4

name=quant31>

<TD><INPUT id=total onfocus=this.form.quant[31].focus() size=8

value=R$0.00 name=total31>

<TR>

<TD><IMG style="WIDTH: 58px; HEIGHT: 47px" height=50 alt=""

src="Arldin/baixados1/032.JPG" width=69>

<TD>Cód.032

<TD>Ursinho Pulf

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[31].focus() type=hidden size=6 value=10.00

name=preco32>

<TD SIZE="8"><INPUT id=quant onchange=recalculaTotais(this.form) size=4

name=quant32>

<TD><INPUT id=total onfocus=this.form.quant[32].focus() size=8

value=R$0.00 name=total32>

<TR>

<TD><IMG style="WIDTH: 46px; HEIGHT: 54px" height=62 alt=""

src="Arldin/baixados1/033.jpg" width=51>

<TD>Cód.033

<TD>Jovens Titãs

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[32].focus() type=hidden size=6 value=10.00

name=preco33>

<TD SIZE="8"><INPUT id=quant onchange=recalculaTotais(this.form) size=4

name=quant33>

<TD><INPUT id=total onfocus=this.form.quant[33].focus() size=8

value=R$0.00 name=total33>

<TR>

<TD><IMG height=38 alt="" src="Arldin/baixados1/034.JPG" width=70>

<TD>Cód.034

<TD>Rei Leão

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[33].focus() type=hidden size=6 value=10.00

name=preco34>

<TD SIZE="8"><INPUT id=quant onchange=recalculaTotais(this.form) size=4

name=quant34>

<TD><INPUT id=total onfocus=this.form.quant[34].focus() size=8

value=R$0.00 name=total34>

<TR>

<TD><IMG height=35 alt="" src="Arldin/baixados1/035.JPG" width=57>

<TD>Cód.035

<TD>Hello Kity

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[34].focus() type=hidden size=6 value=10.00

name=preco35>

<TD SIZE="8"><INPUT id=quant onchange=recalculaTotais(this.form) size=4

name=quant35>

<TD><INPUT id=total onfocus=this.form.quant[35].focus() size=8

value=R$0.00 name=total35>

<TR>

<TD><IMG style="WIDTH: 56px; HEIGHT: 33px" height=37 alt=""

src="Arldin/baixados1/036.JPG" width=61>

<TD>Cód.036

<TD>Os Dálmatas

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[35].focus() type=hidden size=6 value=10.00

name=preco36>

<TD SIZE="8" VALUE="R$0.00"><INPUT id=quant

onchange=recalculaTotais(this.form) size=4 name=quant36>

<TD><INPUT id=total onfocus=this.form.quant[36].focus() size=8

value=R$0.00 name=total36>

<TR>

<TD><IMG style="WIDTH: 47px; HEIGHT: 43px" height=46 alt=""

src="Arldin/baixados1/037.JPG" width=53>

<TD>Cód.037

<TD>Moranguinho

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[36].focus() type=hidden size=6 value=10.00

name=preco37>

<TD SIZE="8" VALUE="R$0.00"><INPUT id=quant

onchange=recalculaTotais(this.form) size=4 name=quant37>

<TD><INPUT id=total onfocus=this.form.quant[37].focus() size=8

value=R$0.00 name=total37>

<TR>

<TD><IMG style="WIDTH: 48px; HEIGHT: 46px" height=53 alt=""

src="Arldin/baixados1/038.jpg" width=51>

<TD>Cód.038

<TD>X-Mem

<TD TYPE="Hidden">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[37].focus() type=hidden size=6 value=10.00

name=preco38>

<TD SIZE="8" VALUE="R$0.00"><INPUT id=quant

onchange=recalculaTotais(this.form) size=4 name=quant38>

<TD><INPUT id=total onfocus=this.form.quant[38].focus() size=8

value=R$0.00 name=total38>

<TR>

<TD><IMG style="WIDTH: 42px; HEIGHT: 49px" height=52 alt=""

src="Arldin/baixados1/039.JPG" width=44>

<TD>Cód.039

<TD>O Mascara

<TD VALUE="R$0.00">R$ 10,00<INPUT id=preco

onfocus=this.form.quant[38].focus() type=hidden size=6 value=10.00

name=preco39>

<TD SIZE="8"><INPUT id=quant onchange=recalculaTotais(this.form) size=4

name=quant39>

<TD><INPUT id=total onfocus=this.form.nome.focus() size=8 value=R$0.00

name=total39>

<TR>

<TD></TD>

<TD></TD>

<TD></TD>

<TD></TD>

<TD><STRONG>Total :</STRONG> </TD>

<TD><INPUT id=totalgeral onfocus=this.form.bot.focus() size=8 value=R$0.00

name=totalgeral></TD></TR></TBODY></TABLE>

<P>

<TABLE cellSpacing=0 cellPadding=0 width="100%" border=1>

<TBODY>

<TR>

<TD>

<P>Nome do Comprador:<INPUT id=nome style="WIDTH: 384px; HEIGHT: 22px"

size=49 name=nome></P>

<P>Endereço:<INPUT id=end style="WIDTH: 356px; HEIGHT: 22px" size=45

name=end>  Numero:<INPUT id=num

style="WIDTH: 102px; HEIGHT: 22px" size=12 name=num></P>

<P>Cidade:<INPUT id=cid style="WIDTH: 245px; HEIGHT: 22px" size=31

name=cid> Estado:<SELECT size=1 name=estado> <OPTION value=""

selected></OPTION> <OPTION value=AC>AC</OPTION> <OPTION

value=AL>AL</OPTION> <OPTION value=AM>AM</OPTION> <OPTION

value=AP>AP</OPTION> <OPTION value=BA>BA</OPTION> <OPTION

value=CE>CE</OPTION> <OPTION value=DF>DF</OPTION> <OPTION

value=ES>ES</OPTION> <OPTION value=GO>GO</OPTION> <OPTION

value=MA>MA</OPTION> <OPTION value=MG>MG</OPTION> <OPTION

value=MS>MS</OPTION> <OPTION value=MT>MT</OPTION> <OPTION

value=PA>PA</OPTION> <OPTION value=PB>PB</OPTION> <OPTION

value=PE>PE</OPTION> <OPTION value=PI>PI</OPTION> <OPTION

value=PR>PR</OPTION> <OPTION value=RJ>RJ</OPTION> <OPTION

value=RN>RN</OPTION> <OPTION value=RO>RO</OPTION> <OPTION

value=RR>RR</OPTION> <OPTION value=RS>RS</OPTION> <OPTION

value=SC>SC</OPTION> <OPTION value=SE>SE</OPTION> <OPTION

value=SP>SP</OPTION> <OPTION value=TO>TO</OPTION></SELECT> Cep:<INPUT

id=cep name=cep></P>

<P>DDD:<INPUT id=ddd style="WIDTH: 72px; HEIGHT: 22px" size=9

name=ddd> Telefone:<INPUT id=tel style="WIDTH: 137px; HEIGHT: 22px"

size=17 name=tel>  Fax:<INPUT id=fax name=fax></P>

<P>Email de resposta: <INPUT id=responder

style="WIDTH: 278px; HEIGHT: 22px" size=33 name=responder></P>

<P>Formas de pagamendo<SELECT style="WIDTH: 149px" size=1 name=pag>

<OPTION value="" selected></OPTION> <OPTION

value="Boleto bancario">Boleto bancario</OPTION> <OPTION

value="Cheque pre">Cheque pre</OPTION> <OPTION

value=Deposit>Deposito</OPTION> <OPTION value="A vista">A

vista</OPTION></SELECT>Cheque num:<INPUT id=numch

style="WIDTH: 152px; HEIGHT: 22px" size=19 name=numch></P>

<P>Banco Num:<INPUT id=bcnum style="WIDTH: 93px; HEIGHT: 22px" size=12

name=bcnum> C/c:<INPUT id=cc name=cc>Bom para:<INPUT id=dta

style="WIDTH: 117px; HEIGHT: 22px" size=13 name=dta></P>

<P>

<TABLE cellSpacing=0 cellPadding=0 width="100%" border=1>

<TBODY>

<TR>

<TD>                              

Coloque outros temas que não tem no formulario</TD></TR>

<TR>

<TD>                                        

<TEXTAREA style="WIDTH: 229px; HEIGHT: 126px" name=mensagem rows=7 cols=25></TEXTAREA></TD></TR></TBODY></TABLE></P></TD></TR></TBODY></TABLE></P>

<P><INPUT type=submit value=Envia name=bot> </P>

<P></FORM></P></BODY></HTML>

 

 

desde ja agradeço as colaboração :rolleyes:

 

RESOLVIDO

Compartilhar este post


Link para o post
Compartilhar em outros sites

O melhor é você colocar o R$ fora dos inputs..

já que você SEMPRE vai colocar isso, já deixa pronto na tabela.. algo do tipo:

<td>R$</td><TD VALUE="R$0.00">10,00<INPUT id=preco 
onfocus=this.form.quant[38].focus() type=hidden size=6 value=10.00 
name=preco39>
Teu código tá bem bagunçado...

Seria melhor montar esse relatório Tableless ^^

 

Além doque teu JS já te devolve o sinal de R$!! você não tem que colocar ele..

return ("R$ " + num + "." + cents);
Desculpa amigo, mas você copiou da onde? e qual gerador de códigos fez essa tabela monstro pra você?

 

Tenta um pouco na unha... um pouquinho de Bloco de Notas não faz mal à ninguem.

Compartilhar este post


Link para o post
Compartilhar em outros sites

Oi amigo a sua dica não resolve pois ele não reorna no total o R$ ele continua dando o total sem o R$

Obrigado

Compartilhar este post


Link para o post
Compartilhar em outros sites

"A minha dica", foi você colocar o <td>R$</td> antes do total.. uê..

ai é lógico que teremos o simbolo onde você quiser... to falando para fazer com HTML e não com JS do jeito que tá ai... fica mais simples, e livre de bugs...

Compartilhar este post


Link para o post
Compartilhar em outros sites

Eu ja resolvi, o nosso amigo OTATA me passou um script que funciona do jeito que eu queria, mais muito obrigado pela dica

Compartilhar este post


Link para o post
Compartilhar em outros sites

×

Informação importante

Ao usar o fórum, você concorda com nossos Termos e condições.