İngilizce

PHP - Keep The Values in The Form
This chapter shows how to keep the values in the input fields when the user hits the submit button.

To show the values in the input fields after the user hits the submit button, we add a little PHP script inside the value attribute of the following input fields: name, email, and website. In the comment textarea field, we put the script between the <textarea> and </textarea> tags. The little script outputs the value of the $name, $email, $website, and $comment variables.

Then, we also need to show which radio button that was checked. For this, we must manipulate the checked attribute (not the value attribute for radio buttons):

Türkçe

PHP - Formdaki Değerleri Koruma
Bu bölüm, kullanıcının gönder düğmesine bastığında giriş alanlarındaki değerlerin nasıl korunacağını göstermektedir.

Kullanıcı gönder düğmesine bastıktan sonra giriş alanlarındaki değerleri göstermek için, aşağıdaki giriş alanlarının değer özniteliğine küçük bir PHP betiği ekliyoruz: ad, e-posta ve web sitesi.yorum metin alanı alanında, betiği <textarea> ve </textarea> etiketleri arasına yerleştiriyoruz. Küçük betik, $name, $email, $website ve $comment değişkenlerinin değerini çıktı olarak verir.

Ardından, hangi radyo düğmesinin işaretlendiğini de göstermemiz gerekiyor. Bunun için, işaretli özniteliğini (radyo düğmeleri için değer özniteliğini değil) değiştirmemiz gerekir:

(5000 karakter kaldı)
İngilizce
Türkçe

İçindekiler

Son çeviriler

devamını göster›
ADS - REKLAMLAR