omor Posted June 2, 2016 Report Share Posted June 2, 2016 Olá, com eu faço para chamar uma funcao em uma url? mais ou menos isso que eu quero: <?php include_once('classes/Url.php'); echo "<script type='text/javascript'>"location.href='".echo URL::getBase()&irpara=3."'"</script>"; ?> Quote Link to comment Share on other sites More sharing options...
0 Stoma Posted June 2, 2016 Report Share Posted June 2, 2016 Olá. Você pode concatenar assim: echo "<script type='text/javascript'>location.href = '" . URL::getBase() . "&irpara=3';</script>"; Quote Link to comment Share on other sites More sharing options...
0 omor Posted June 2, 2016 Author Report Share Posted June 2, 2016 24 minutos atrás, Stoma disse: Obrigado Gender, mas eu preciso de transformar esse link aqui //echo "<script type='text/javascript'>location.href='../index.php?link=3'</script>"; onde link=3 corresponde a pagina carrinho.php por esse concatenado echo "<script type='text/javascript'>location.href = '" . URL::getBase() . "&irpara=3';</script>"; desse jeito não está dando certo echo "<script type='text/javascript'>location.href = '" . URL::getBase() . "&irpara=3';</script>"; Quote Link to comment Share on other sites More sharing options...
0 omor Posted June 2, 2016 Author Report Share Posted June 2, 2016 29 minutos atrás, omor disse: Obrigado Gender resolvi o problema colocando assim: echo "<script type='text/javascript'>location.href = '../carrinho';</script>"; Quote Link to comment Share on other sites More sharing options...
0 Stoma Posted June 3, 2016 Report Share Posted June 3, 2016 Que bom que conseguiu resolver! Abraço Quote Link to comment Share on other sites More sharing options...
0 omor Posted June 5, 2016 Author Report Share Posted June 5, 2016 23 horas atrás, Stoma disse: Que bom que conseguiu resolver! Abraço abraço Quote Link to comment Share on other sites More sharing options...
Question
omor
Olá, com eu faço para chamar uma funcao em uma url?
mais ou menos isso que eu quero:
<?php
include_once('classes/Url.php');
echo "<script type='text/javascript'>"location.href='".echo URL::getBase()&irpara=3."'"</script>";
?>
Link to comment
Share on other sites
5 answers to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.