php, mysql, html, css, js, c#, java, c++ coder

yerinde düzenleme javascript , onchange edit ~ saho

Eylül 8, 2008 | In: Ajax, Html, Yazılım

bir wm forumunda bir arkadaşımız istemiş pek destek vermiyorum ya artık :p öylesine bakıyordum bilen yok mu? Demiş bende gaza geldim hazırladım sıfırdan tamamen kendi ürünümdür sade oldu ama iş görür …

not: sql den düzenleme yaptırmak istiyorsanız 2 yöntem tavsiye edebilirim 1. si alttan gizli bir div açıp location.href=”sql_guncelle.php?veri=”+areaVal+”id=<?php echo $_GET['id'];?>” ye yönlendirip

sql_guncelle den gereken diğer işlemleri yapabilirsiniz veya simple , eyceks gibi sade kütüphane ler ile veriyi yine sql_guncelle gibi bir dosya ya post,get ile gönderip işleyebilirsiniz

1
<code><span style="color: #000000;"><span style="color: #007700;">&lt;</span><span style="color: #0000bb;">div id</span><span style="color: #007700;">=</span><span style="color: #dd0000;">"text" </span><span style="color: #0000bb;">onclick</span><span style="color: #007700;">=</span><span style="color: #dd0000;">"duz('text','area')"</span><span style="color: #007700;">&gt;</span><span style="color: #0000bb;">saho</span><span style="color: #007700;">&lt;/</span><span style="color: #0000bb;">div</span><span style="color: #007700;">&gt;</span></span>

<div id="area" style="display:none;">
<
textarea name="area_x" id="area_x"></textarea>
<
button onclick="duzenle('text','area')">duzenle</button>
<
button onclick="iptal('text','area')">iptal</button>
</
div>

<br />
<
a onclick="duz('text','area')">duz</a>

<script>
function
duz(id,idx) {
document.getElementById(idx).style.display="block";
document.getElementById(id).style.display="none";
divVal = document.getElementById(id).firstChild.nodeValue;
document.getElementById(idx+"_x").value=divVal;
}
function
duzenle(id,idx) {
document.getElementById(idx).style.display="none";
document.getElementById(id).style.display="block";
areaVal = document.getElementById(idx+"_x").value;
document.getElementById(id).innerHTML=areaVal;
}
function
iptal(id,idx){
document.getElementById(idx).style.display="none";
document.getElementById(id).style.display="block";
}
</script>

Paylaş ve HalayÇek: These icons link to social bookmarking sites where readers can share and discover new web pages.
  • Technorati
  • Digg
  • del.icio.us
  • YahooMyWeb
  • Taggly
  • Netvouz
  • DZone
  • ThisNext
  • MisterWong
  • Wists
  • blogmarks
  • IndiaGram
  • Internetmedia
  • Netscape
  • Reddit
  • Scoopeo
  • StumbleUpon

Comment Form

Takvim

Temmuz 2010
Pts Sal Çar Per Cum Cts Paz
« Haz    
 1234
567891011
12131415161718
19202122232425
262728293031