I am creating a simple Proxy server for my website. Why I am not using mod_proxy and mod_cache is a different discussion. Here's the code:
shell_exec("nohup curl --create-dirs -o {$write_path} {$source_url} > /dev/null 2> /dev/null & echo $!");
sleep(1);
$read_speed = 65.5; # 65.5 kb/s download rate
$handle = fopen($write_path, "rb");
$content_type = select_meta_item($headers, 'Content-Type');
$file_size = select_meta_item($headers, 'Content-Length');
send_headers($content_type, $file_size);
flush();
while (!feof($handle))
{
echo fread($handle, round($read_speed * 1024));
flush();
sleep(1);
}
fclose($handle);
Streaming an MP3 doesn't work using this method. Plays in Chrome, but not in Firefox. Initially I'll be using this to stream MP3 files through Long Tail's JW Player. If it all works out, I'll also be using this to send ZIP files
Linking with Foreign Keys
I have been getting an erro when I try and link:
Blank record injected into database
I always found several blank records inside my database, although $SESSION is required to insert the data into database.Why can this happen? how to prevent this?
generate seo frienly url from a text like wordpress
Convert: "åäö" to "aao", "space" to "-", "!?" to "nothing", and all to lower case.function MakeSeo($string){ ???}i want a php
foreach iterator
Hi GuysDoes the foreach loop have an inbuilt iterator ?
Javascript or not?
How many people prefer javascript/ajax sites? How many prefer the good old fashion straight php sites?
question about header() security
is is safe to just use the header() function to redirect someone if they are, say, not logged in? or should i always put a die() function underneath the header() function?
Need help: how to catch acess of undefined class properties
Hello. I am learning OO with PHP and have hit a problem.Some code runs as perfectly valid code, where i would like PHP to issue a warning / error.I guess this is because of the loose typing of PHP,
InternetOpenUrl() Invalid cert
Hi all,
Problem with "dynamic" index page
Hi. I have one question. In my index.php page I have this kind of code:Code: // listaa sivut$pages = Array ("etusivu" => "etusivu.php",,"linkit" =>
Forgot password won't work
My forgot password thing is not working properly. It is giving me this errorMailbox unavailable. The server response was: <andrewsmd87@gmail.com> No such user here