Type: Posts; User:
You could do it like this:
$str = 'This is a test. This is also a test.';
$str = preg_replace('/^(.*?)test/i', '$1foo', $str);
$str = '<FRAME NAME="TOP" MARGINHEIGHT=0 MARGINWIDTH=0 SCROLLING=NO NORESIZE SRC="top.htm">';
preg_match('/<frame(.*?)src="(.*?)"/i', $str, $matches);
These forums are not meant to be money-makers. A job is where you'll make the money, and this is where you can share you knowledge.
I've got an office set up here at home. Do most of my work here, with the occasional business trip to do work on-site.
Just hung out with The Girl... We were going to go out to eat at a nice restraunt, but she went and got sick, so that will have to wait until she's feeling better. Had a great night, though... Hope...
^^Starts recursion (couldn't resist :D)
But why condone using a bad thing? I think it's good to let them know it's a bad idea and then let them make their own decision. You're not forcing them to do anything, just being a good, responsible...
An even more attractive option would be finding a new host... Having to make usability decisions based on what you host allows shouldn't be the solution.
The first issue of this one wasn't bad: http://particletree.com/treehouse/
If you are on an Apache server, you could look into mod_rewrite. Take a look at this: http://www.ryanbrill.com/archives/cruft-free-urls/
See if this is enough to get you going: http://www.webdevfaqs.com/php.php#mailer
Check out what php.net has to say about handling file uploads: http://us2.php.net/manual/en/features.file-upload.php
Ok, update your query to look like this, and delete the line below it ($sql = ...):
$query = "INSERT INTO $database VALUES ('$username', '$password', '$question', '$answer',
lavashark, post your code and I'll show you what needs to be done...
Hey, it happens to the best of us... ;)
I would highly recommend using a MySQL timestamp, rather than a PHP timestamp, since you are adding it to a database. The reason for this, is if you need to run queries related to the date, you'll...
How about this: http://www.infinitypages.com/research/download.htm
You forgot to close you second parenthesis...
Run a phpinfo script and make sure GD is installed...
Something like this:
$db_server = 'localhost';
$db_user = 'username';
$db_pass = 'password';
$db_name = 'db_name';
mysql_connect($db_server, $db_user, $db_pass) or...
You are only supposed to use the ternary opperator when you want to return a value. ;)
First of all, I'll start by stating that I'm a PHP developer and am not a fan of ASP (or .NET). However, you hardly make a compelling argument.
A good quality host is going to cost about the same,...
Actually, get a web host that supports the one you choose. ;) That's the better option, I'd say.