Problem with passing variables
Posted on
16th Feb 2014 07:03 pm by
admin
I'm not really a php programmer so I'm really struggling with this issue.
I have a banner script that is supposed to send people to an affiliate site and pass the parameters along with it.
Did you know?Explore Trending and Topic pages for more stories like this.
For instance: http://www.mydomain.com/had.php?name=Testbanner&url=http://links.affliatesite.com/?s=bubbly&p=ft&c=1&r=23794&j=13&t=treat&src=ads
It doesn't take anything after the &p
I know it's something to do with URL encoding but I can't figure it out.
Here's what the script coding looks like:
<?php
require_once "auth/config.php";
$link = @mysql_connect($hostname, $username,$password);
if($link)
{
$dbcon = @mysql_select_db($dbname,$link);
}
$name = $_GET['name'];
$url = $_GET['url'];
$rip = $_SERVER['REMOTE_ADDR'];
$today = getdate();
//Time of the visit
$time = $today['hours'].":".$today['minutes'].":".$today['seconds'];
//Date of the Visit
$day = $today['year']."-".$today['mon']."-".$today['mday'];
$sss = "insert into stats values('$name','$day','$time','$rip')";
@mysql_query($sss,$link);
?>
<script language=javascript>
document.location.href="<?php echo ($url); ?>";
</script>
I could really use some help. I've tried adding urlencde in several variations and places and just can't get it working.
Thanks!
Your Answer:
Login to answer
59
24
Other forums
How many users online in the last 24-hours using time()?
I'm fairly new to PHP. I have a MySQL table called 'users' and a field called 'loggedin' which is in
query help
Hi experts.
i have a table rep2 like this
PROD_COD ACCT_NO DUE_DAYS BALANCE
PHP Cannot redeclare class
I have 6 files, and two of them do not seem to want to play well. I keep getting a "Cannot rede
ClientScript.RegisterClientScriptBlock Issue
This is what I haveview plaincopy to clipboardprint?Protected Sub posrback_Click(ByVal sender As Obj
Help with parsing this html
Hi,
I've got some html i just need a couple of strings from.. argh, it's freaking me out. I've t
set xml path in flash when xml created in memorystream and webrequest
i am creating an xml file using memory stream and i want to load this xml file into the flash on cli
Help with some dates
I have a list of dates in an array:
$mondays = array(
strtotime("October 12, 2009
Pro-rata Billing in Periodic Billing for Rental
Hi guys,
We have a situation, where a rental contract starts at the mid of the month say
Timer control causing error
I recently decided to add a timer control to an existing page that uses AJAX on my site. As soon as
remove innitial and
tags
i am using tiny_mce as a text editor for my CMS.
buy now the problem is it add <p>