Programming Forums
User Name Password Register
 

RSS Feed
FORUM INDEX | TODAY'S POSTS | UNANSWERED THREADS | ADVANCED SEARCH

Reply
 
Thread Tools Display Modes
Old Mar 2nd, 2006, 4:42 AM   #1
guess
Programmer
 
Join Date: Feb 2006
Posts: 40
Rep Power: 0 guess is on a distinguished road
str_replace

Quote:
"HACIVAT KARAGOZ NEDEN OLDURULDU"
in this string, I want to use str_replace function in order to put ' instead of "
although I tried lots of combinations,I couldnt manage.
I think Im missing one point...
guess is offline   Reply With Quote
Old Mar 2nd, 2006, 9:59 PM   #2
ludesign
Newbie
 
ludesign's Avatar
 
Join Date: Feb 2006
Posts: 8
Rep Power: 0 ludesign is on a distinguished road
hi,

blah ... can you exmplain it more detailed, because i don't get what you want to change in this string?

thanks.
__________________
Винаги се цели в луната, така и да пропуснеш, пак ще си сред звездите!
by ludesign
ludesign is offline   Reply With Quote
Old Mar 2nd, 2006, 10:13 PM   #3
tempest
Programming Guru
 
tempest's Avatar
 
Join Date: Oct 2004
Posts: 1,041
Rep Power: 6 tempest is on a distinguished road
Send a message via ICQ to tempest Send a message via AIM to tempest Send a message via Yahoo to tempest
[php]
$str = "\"HACIVAT KARAGOZ NEDEN OLDURULDU\"";
echo str_replace("\"", "'", $str);
[/php]
__________________

tempest is offline   Reply With Quote
Old Mar 3rd, 2006, 2:00 AM   #4
guess
Programmer
 
Join Date: Feb 2006
Posts: 40
Rep Power: 0 guess is on a distinguished road
Man it is not right.

I have found it yesterday finally.It is str_replace('"',"'");
guess is offline   Reply With Quote
Old Mar 3rd, 2006, 3:22 AM   #5
ludesign
Newbie
 
ludesign's Avatar
 
Join Date: Feb 2006
Posts: 8
Rep Power: 0 ludesign is on a distinguished road
Quote:
Originally Posted by guess
Man it is not right.

I have found it yesterday finally.It is str_replace('"',"'");
How i got what you mean .. hehe, never mind, but i suggesting you to use stripslashes() before str_replace().

__________________
Винаги се цели в луната, така и да пропуснеш, пак ще си сред звездите!
by ludesign
ludesign is offline   Reply With Quote
Reply

Bookmarks

« Previous Thread in Forum | Next Thread in Forum »

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump




DaniWeb IT Discussion Community
All times are GMT -5. The time now is 12:30 PM.

Powered by vBulletin® Version 3.7.0, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Copyright ©2007 DaniWeb® LLC