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.
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!
help removing unwanted graphic
How do I remove the small elongated rectangular shape between the "Latest post" and "Archives" section at http://www.simonlindgren.com ?The code surrounding this place
CURL XML Request [From C to PHP]
Hi, I need some help converting this into something that will work with PHP.Code:
How to generate a random array of integers subject to a certain constraint
I am writing a program that asks the user to enter an integer N and then generates a random array of integers of size 2^N, each of whose entries range from 1 to N+1. The final random array, however,
Display Database
I need to create a shopping cart. I found this code online: http://conceptlogic.com/jcart/Unfortunately, I dont know how to display my product from MYSQL rather than hardcoding as shown in the script
Different actions for different parts of a string
<?phpfunction dosomething($string, $else = '') { if (empty($else)) $string = "<b>$string</b>"; else $string =
how to export excel file in same server
My first post - php newbie, so appreciate your support.I'm currently using headers to save web page as excel file.$filename="sms.xls";header("Pragma: public");header("Expires:
weeks in a year
hi,i found this snippet on php.netQuoteFor the week number for weeks starting on Sunday:<?phpfunction week_of_year($month, $day, $year) {$day_of_year = date('z', mktime(0, 0, 0, $month, $day,
selectbox+database connection retrive problem
Code: [Select] <tr> <th align="left" scope="col"><span class="style2 style8">Features
IIS & NW MII on the same server
Hi,
Creating a db with a query
Hello everyone.I'm having troubles creating a db with a query.I'm reading a book called PHP Bibles from Tim Converse I get this errorFatal error: Call to undefined function mysql_create_db() in