PHP Indonesia - Facebook | PHP Indonesia is a community for everyone that loves PHP. Our focus is in the PHP world but our topics encompass the entire LAMP stack. Topics include PHP coding, to memcached handling, db optimizations, server stack, web server tuning, code deploying, hosting options and much much more. Youtube Channel : http://www.youtube.com/user/OurPHPIndonesia Twitter : @php_indonesia NOTE: Rules for Wall posting: https://www.facebook.com/groups/35688476100/doc/10151597056316101/ Daftar Keanggotaan : http://www.facebook.com/groups/35688476100/doc/10150671770741101/ | |
 | Mobile Game Development Course
Learn how to create awesome HTML5 games that run on iPhone, iPad, Android and Desktop! Sign up today for this $99 online course.  | From our sponsors | | |
[ASK] permisi mau tanya gan misal : $message = "S... Aug 28th 2013, 08:50, by Malaikat Izrail | [ASK] permisi mau tanya gan misal :
$message = "SELAMAT DATANG \\ MEMBER PHP INDONESIA \ DI RADIO";
nah ane pgn "\\" atau "\" ke replace ama newline gimana ya? udah coba str_replace, tapi g bisa. mungkin ane salah kali ya makenya.
ane pake str_replace("\\","\n",$message);
terima kasih |
| | Kalo pake <BR> aja, gmn ?! |
| | idem gan, masih tidak bisa juga :( |
| | perhatikan.. tulisan message diatas sebelumnya akan menghasilkan SELAMAT DATANG \ MEMBER PHP INDONESIA ? DI RADIO namun hasilnnya akan jadi kacau kl km pake str_replace() saran saya adalah pastikan emang tulisannya demikian dahulu sebelum di str_replace |
| | hint.. coba cari kode asci dari \ |
| | 5C ascii to hexa, bener tidak? |
| | Tapi kok saya coba bisa gan.
$message = "SELAMAT DATANG \\ MEMBER PHP INDONESIA \ DI RADIO"; $newLine = str_replace("\\","<br>",$message); echo $newLine;
atau
echo str_replace("\\","<br>",$message); |
| | Nik nya serem bener | | |
|
Tidak ada komentar:
Posting Komentar