Foros del Web » Programando para Internet » PHP »

Cambiar moneda en sitio echo en php

Estas en el tema de Cambiar moneda en sitio echo en php en el foro de PHP en Foros del Web. hOLA TENGO UN SITIO DE ANUNCIOS CLASIFICADOS ECHO EN PHP, PERO ESTA EN DOLARES LA MONEDA, ALGUIEN ME PODRIA DECIR DONDE TENGO QUE BUSCAR O ...
  #1 (permalink)  
Antiguo 03/04/2011, 01:29
(Desactivado)
 
Fecha de Ingreso: septiembre-2010
Mensajes: 7
Antigüedad: 13 años, 7 meses
Puntos: 0
Cambiar moneda en sitio echo en php

hOLA TENGO UN SITIO DE ANUNCIOS CLASIFICADOS ECHO EN PHP, PERO ESTA EN DOLARES LA MONEDA, ALGUIEN ME PODRIA DECIR DONDE TENGO QUE BUSCAR O QUE CODIGO TENGO QUE IR PARA CAMBIAR A EUROS.


Muchas gracias
  #2 (permalink)  
Antiguo 03/04/2011, 04:08
 
Fecha de Ingreso: diciembre-2009
Ubicación: España
Mensajes: 380
Antigüedad: 14 años, 3 meses
Puntos: 1
Respuesta: Cambiar moneda en sitio echo en php

Cita:
<?php
$euros = $dolares * 0,702543206;
?>
  #3 (permalink)  
Antiguo 04/04/2011, 08:50
(Desactivado)
 
Fecha de Ingreso: septiembre-2010
Mensajes: 7
Antigüedad: 13 años, 7 meses
Puntos: 0
Respuesta: Cambiar moneda en sitio echo en php

Creo que no me he explicado bien, lo que me ocurre, es que el sitio en php no logro localizar la moneda y esta en dolares, queria saber como puedo cambiarlo a euros,


muchas gracias
  #4 (permalink)  
Antiguo 04/04/2011, 13:39
(Desactivado)
 
Fecha de Ingreso: septiembre-2010
Mensajes: 7
Antigüedad: 13 años, 7 meses
Puntos: 0
Respuesta: Cambiar moneda en sitio echo en php

os dejo el codigo que sale en la pagina a ver si asi podeis ayudarme.

<br><br>

<form method=get action="payment.php" name=PricesForm>

<table align=center width=400 cellspacing=0>
<caption align=center>
<br>
<font color=red size=2 face=verdana><b></b></font>

</caption>

<tr style="background-color:D3D4E8; color:black; font-family:verdana; font-size:11; font-weight:bold">
<td width=20>&nbsp;</td>
<td width=270>Plan</td>
<td width=100 align=right>Precio</td>
</tr>

<tr bgcolor=dddddd>
<td align=center><input type=radio name="SelectedPackage" value="1"></td>
<td>1 anuncios por 7 dias <sup><font color="#990000" face=verdana size=2><b>Destacado</b></font></sup></td>
<td align=right>$19.95</td>
</tr>
<tr bgcolor=white>
<td align=center><input type=radio name="SelectedPackage" value="6"></td>
<td>1 anuncios por 14 dias <sup><font color="#990000" face=verdana size=2><b>Destacado</b></font></sup></td>
<td align=right>$24.95</td>
</tr>
<tr bgcolor=dddddd>
<td align=center><input type=radio name="SelectedPackage" value="5"></td>
<td>1 anuncios por 30 dias <sup><font color="#990000" face=verdana size=2><b>Destacado</b></font></sup></td>
<td align=right>$29.95</td>
</tr>
<tr bgcolor=white>
<td align=center><input type=radio name="SelectedPackage" value="2"></td>
<td>1 anuncios por 7 dias</td>
<td align=right>$2.95</td>
</tr>
<tr bgcolor=dddddd>
<td align=center><input type=radio name="SelectedPackage" value="3"></td>
<td>1 anuncios por 14 dias</td>
<td align=right>$3.95</td>
</tr>
<tr bgcolor=white>
<td align=center><input type=radio name="SelectedPackage" value="4"></td>
<td>1 anuncios por 30 dias</td>
<td align=right>$4.95</td>
</tr>

<tr>
<td colspan=3 align=center style="padding-top:20">
Forma de pago:
<select name="PaymentGateway">
<option value="paypal">PayPal</option>

</select>

<input type=submit name=s1 value=Enviar>
</td>
</tr>

</table>

</form>

</td>
</tr>
<tr valign="bottom">
<td align="right">
<table border="0" cellpadding="0" cellspacing="0" width="95%" height="58" background="images/fon_bot.gif">
<tr>
<td>
<br>
  #5 (permalink)  
Antiguo 04/04/2011, 13:42
Avatar de Nano_  
Fecha de Ingreso: febrero-2006
Ubicación: Bogotá, Colombia
Mensajes: 1.866
Antigüedad: 18 años, 2 meses
Puntos: 96
Respuesta: Cambiar moneda en sitio echo en php

Saludos

No entendí absolutamente nada
__________________
:.:Nano.:: @nano_hard - Retornando al foro
  #6 (permalink)  
Antiguo 04/04/2011, 14:24
(Desactivado)
 
Fecha de Ingreso: septiembre-2010
Mensajes: 7
Antigüedad: 13 años, 7 meses
Puntos: 0
Respuesta: Cambiar moneda en sitio echo en php

mi sitio es www.barceweb.com, el sitio esta echo en php, utuliza dolares, quisiera cambiarlo a euros, no se si puede o como deberia hacerlo para cambiarlo desde php admin,


gracias
  #7 (permalink)  
Antiguo 04/04/2011, 14:33
Avatar de Aaronus23  
Fecha de Ingreso: diciembre-2010
Ubicación: https://home
Mensajes: 81
Antigüedad: 13 años, 4 meses
Puntos: 4
Respuesta: Cambiar moneda en sitio echo en php

pfff... necesitariamos ver la web completa para decirte jajajajaja
  #8 (permalink)  
Antiguo 05/04/2011, 11:36
(Desactivado)
 
Fecha de Ingreso: septiembre-2010
Mensajes: 7
Antigüedad: 13 años, 7 meses
Puntos: 0
Respuesta: Cambiar moneda en sitio echo en php

Hola, ya el logrado cambiar a la moneda euro, aqui os dejo el codigo, el problema que me surge ahora es a la hora de que pagen con paypal , todavia coje la moneda como dolar. www.barceweb.com. gracias

<?
require_once("conn.php");
require_once("includes.php");

//get the prices
$q1 = "select * from class_prices order by PriorityLevel desc, ads, days";
$r1 = mysql_query($q1) or die(mysql_error());

$col = "white";

while($a1 = mysql_fetch_array($r1))
{
if($col == "white")
{
$col = "dddddd";
}
else
{
$col = "white";
}

$Prices .= "<tr bgcolor=$col>\n\t<td align=center>";

if($_GET[SelectedPackage] == $a1[PriceID])
{
$Prices .= "<input type=radio name=\"SelectedPackage\" value=\"$a1[PriceID]\" checked>";
}
else
{
$Prices .= "<input type=radio name=\"SelectedPackage\" value=\"$a1[PriceID]\">";
}


$Prices .= "</td>\n\t<td>$a1[ads] anuncios por $a1[days] dias";

if($a1[PriorityLevel] == '1')
{
$Prices .= " <sup><font color=\"#990000\" face=verdana size=2><b>Destacado</b></font></sup>";
}

$Prices .= "</td>\n\t";

$Prices .= "<td align=right>€$a1[price]</td>\n</tr>\n";
}

if($_GET[e] == '1')
{
$error = "Seleccione un plan, por favor!";
}
elseif($_GET[e] == '2')
{
$error = "Seleccione una forma de pago, por favor!";
}

if($_GET[PaymentGateway] == "paypal")
{
$selected1 = "selected";
}
elseif($_GET[PaymentGateway] == "2checkout")
{
$selected2 = "selected";
}


//get the templates
require_once("templates/HeaderTemplate.php");
require_once("templates/PricesTemplate.php");
require_once("templates/FooterTemplate.php");

?>
  #9 (permalink)  
Antiguo 05/04/2011, 13:44
Avatar de Nemutagk
Colaborador
 
Fecha de Ingreso: marzo-2004
Ubicación: México
Mensajes: 2.633
Antigüedad: 20 años
Puntos: 406
Respuesta: Cambiar moneda en sitio echo en php

En primera, deverias de decir si tu sitio es uno hecho a medida o utiliza algun administrador prefabricado, el adivino anda de vacaciones y para los simples mortales es imposible adivinar como esta construido tu sitio para poder ayudarte
__________________
Listo?, tendría que tener 60 puntos menos de IQ para considerarme listo!!!
-- Sheldon Cooper
http://twitter.com/nemutagk
PD: No contestaré temas vía mensaje personal =)
  #10 (permalink)  
Antiguo 05/04/2011, 14:20
(Desactivado)
 
Fecha de Ingreso: septiembre-2010
Mensajes: 7
Antigüedad: 13 años, 7 meses
Puntos: 0
Respuesta: Cambiar moneda en sitio echo en php

PERDON, PERO SOY BASTANTE NOVATO EN ESO, ESTA ECHO EN UN ADMINISTRADOR PREFRABRICADO Y ESTAVA CONFIGURADO EN DOLARES, Y NECESITO QUE VAYA EN EUROS, AHORA LO QUE ME OCURRE ES SOLAMENTE EN LOS PLANES, AUNQUE EN LA PAGINA PONE DOLARES, CUANDO REALIZA EL PAGO, COBRA EN DOLARES.


saludos

Última edición por GatorV; 05/04/2011 a las 15:21
  #11 (permalink)  
Antiguo 06/04/2011, 12:35
(Desactivado)
 
Fecha de Ingreso: septiembre-2010
Mensajes: 7
Antigüedad: 13 años, 7 meses
Puntos: 0
Respuesta: Cambiar moneda en sitio echo en php

os dejo el archivo PAYMENT.PHP , es este:

<?
require_once("conn.php");
require_once("includes.php");

if(empty($_GET[SelectedPackage]))
{
header("location:$_SERVER[HTTP_REFERER]?e=1&PaymentGateway=$_GET[PaymentGateway]");
exit();
}
elseif(empty($_GET[PaymentGateway]))
{
header("location:$_SERVER[HTTP_REFERER]?e=2&SelectedPackage=$_GET[SelectedPackage]");
exit();
}
else
{
if(!empty($_SESSION[AgentID]))
{
$MyID = $_SESSION[AgentID];
}

if(!empty($_SESSION[MemberID]))
{
$MyID = $_SESSION[MemberID];
}

//get the agent details
$q1 = "select * from class_members where MemberID = '$MyID' ";
$r1 = mysql_query($q1) or die(mysql_error());
$a1 = mysql_fetch_array($r1);

//get the price details
$q2 = "select * from class_prices where PriceID = '$_GET[SelectedPackage]' ";
$r2 = mysql_query($q2) or die(mysql_error());
$a2 = mysql_fetch_array($r2);

/*

flags:

r -> renew

n -> new

m -> more

*/

if(ereg("renew.php", $_SERVER[HTTP_REFERER]))
{
$flag = "r";
$action = "Renewal";
}
elseif(ereg("more.php", $_SERVER[HTTP_REFERER]))
{
$flag = "m";
$action = "Upgrade";
}
else
{
$flag = "n";
$action = "Activation";
}

if($_GET[PaymentGateway] == "paypal")
{
header("location:https://www.paypal.com/xclick?business=$aset[PayPalEmail]&item_name=$a2[ads] anuncios por $a2[days] dias&first_name=$a1[FirstName]&last_name=$a1[LastName]&email=$a1[email]&item_number=1&custom=$MyID|$_GET[SelectedPackage]|$flag&amount=$a2[price]&notify_url=http://$_SERVER[HTTP_HOST]".dirname($_SERVER[PHP_SELF])."/notify.php&return=http://$_SERVER[HTTP_HOST]".dirname($_SERVER[PHP_SELF])."/login.php");

exit();

}

}

?>

y el archivo PAYPA.PHP


<br><br>

<form method=get action="payment.php" name=PricesForm>

<table align=center width=400 cellspacing=0>
<caption align=center>
<br>
<font color=red size=2 face=verdana><b><?=$error?></b></font>

</caption>

<tr style="background-color:D3D4E8; color:black; font-family:verdana; font-size:11; font-weight:bold">
<td width=20>&nbsp;</td>
<td width=270>Plan</td>
<td width=100 align=right>Precio</td>
</tr>

<?=$Prices?>

<tr>
<td colspan=3 align=center style="padding-top:20">
Forma de pago:
<select name="PaymentGateway">
<option value="paypal">PayPal</option>
</select>

<input type=submit name=s1 value=Enviar>
</td>
</tr>

</table>

</form>

gRACIAS DE ANTEMANO

Etiquetas: echo, moneda
Atención: Estás leyendo un tema que no tiene actividad desde hace más de 6 MESES, te recomendamos abrir un Nuevo tema en lugar de responder al actual.
Respuesta




La zona horaria es GMT -6. Ahora son las 14:41.