Всем привет, я новичок и впервые на форуме прошу сильно не пинать. Помогите с кодом, все работает как надо но насколько это правильно вставлять код в placeholder. echo '<div class="ramka1b"><form name="form" action="?act=chat" method="post">'; echo '<textarea rows="5" name="msg" style="background-color: #000; width: 98%; height: 50%;" placeholder="'; //------------------------------------------- $req = mysql_query("SELECT * FROM `gchat` WHERE `id` >= '1' ORDER BY `time` DESC LIMIT " . $start . "," . $kmess); for ($i = 0; $res = mysql_fetch_assoc($req); ++$i) { echo ' [чат] ' . $res['name'] . ': ' . $res['text'] . ''; } //------------------------------------------- echo '"></textarea>'; echo '<input type="submit" style="background-color: #000; width: 100%; height: 50%;" name="submit_chat" class="blokknred" value="Отправить"/></form></div>';
@Харитон пользуйся ббкодами code или php чтобы оформить код в сообщении. --- Добавлено --- я не понимаю вопрос, что значит "вставлять код в placeholder" ?
PHP: function myfunction() { return 'Hello world'; } $format = "<html>%s</html>"; printf($format, myfunction());