Jump to content

[SOLVED] str_replace with spaces.


sneamia

Recommended Posts

You wrote your ternary wrong. It should be

 

$_GET['user'] = ($_GET['user'] == NULL) ?  'roflwaffle' : str_replace(' ', '_', strtolower($GET['user']));

 

Assuming that you were wanting to assign 'roflwaffle' to it if it's null, str_replace if not.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.