Hocam şu işlemi kod üzerinde gsterbilirsen daha iyi anlayacağım. sana zahmet kod üzerinde nerenin değişeceğini gsterebilirmisin Yaşamın amacı "Amacı olan bir yaşammıdır" Hacı?

multipart ile formdan gnderiyosan veriyi alırken request. form dersen bo$ veri kaydeder veritabanına. gelen veriyi tanımladıgın upload degi$keniyle alıcaksın. meselaSet Upload = Server. CreateObject dediysenveri = Upload. form $eklinde alıcaksın. screw you guys! i"m goin" hoooome!

Merhaba arkadaşlar kendime bi haber ekleme sayfası yapmak istedim. Haber formu multipart/data formu kullanmak istedim. Sorunum şu. Sayfayı çalıştırıp haber eklediğimde hiç bir hata vermiyor ama veri tabanına sadece tarih kaydediyor, başka hiç bir veri kaydetmiyor. Veritabonu tablo ismi : tbl haber sütun isimleri : id, baslik, ozet, resim, tarih acaba multipart/data form kullanarak veri tabanına nasıl veri kaydedebilirim <!--#include file ="conn. asp"--> <head> <meta http-equiv="Content-Language" content="tr"> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-9" /> <meta http-equiv="Content-Language" content="tr"> </head> <script language="javascript" type="text/javascript" src="jscripts/tiny_mce/tiny_mce. js"></script> <script language="javascript" type="text/javascript"> tinyMCE. init({ // General options mode : "textareas", theme : "advanced", plugins : "safari, pagebreak, style, layer, table, save, advhr, advimage, advlink, emotions, iespell, inlinepopups, insertdatetime, preview, media, searchreplace, print, contextmenu, paste, directionality, fullscreen, noneditable, visualchars, nonbreaking, xhtmlxtras, template", // Theme options theme_advanced_buttons1 : "save, newdocument,|, bold, italic, underline, strikethrough,|, justifyleft, justifycenter, justifyright, justifyfull,|, styleselect, formatselect, fontselect, fontsizeselect", theme_advanced_buttons2 : "cut, copy, paste, pastetext, pasteword,|, search, replace,|, bullist, numlist,|, outdent, indent, blockquote,|, undo, redo,|, link, unlink, anchor, image, cleanup, help, code,|, insertdate, inserttime, preview,|, forecolor, backcolor", theme_advanced_buttons3 : "tablecontrols,|, hr, removeformat, visualaid,|, sub, sup,|, charmap, emotions, iespell, media, advhr,|, print,|, ltr, rtl,|, fullscreen", theme_advanced_buttons4 : "insertlayer, moveforward, movebackward, absolute,|, styleprops,|, cite, abbr, acronym, del, ins, attribs,|, visualchars, nonbreaking, template, pagebreak", theme_advanced_toolbar_location : "top", theme_advanced_toolbar_align : "left", theme_advanced_statusbar_location : "bottom", theme_advanced_resizing : true, // Example content CSS content_css : "css/content. css", // Drop lists for link/image/media/template dialogs template_external_list_url : "lists/template_list. js", external_link_list_url : "lists/link_list. js", external_image_list_url : "lists/image_list. js", media_external_list_url : "lists/media_list. js", // Replace values for the template plugin template_replace_values : }); </script> <table border="1" width="100%" id="table1" height="50" cellspacing="0" cellpadding="0" bordercolor="#FFFFFF"> <form action="haberekle. asp?islem=ekle" method="post" enctype="multipart/form-data"> <tr> <td width="239" height="25" bordercolor="#C0C0C0"> HABER BAŞLIĞI</td> <td height="25" bordercolor="#C0C0C0"> <p><input type="text" name="baslik" size="88"></p> </td> </tr> <tr> <td width="239" bordercolor="#C0C0C0"> HABER ZETİ</td> <td bordercolor="#C0C0C0"><input type="text" name="ozet" size="88"></td> </tr> <tr> <td width="239" bordercolor="#C0C0C0"> HABER RESMİ</td> <td bordercolor="#C0C0C0"><input class="formic" type="file" name="resim"></td> </tr> <tr> <td width="239" bordercolor="#C0C0C0"> HABER İÇERİĞİ</td> <td bordercolor="#C0C0C0"><textarea name="haber" rows="12" cols="65"> </textarea></td> </tr> <tr> <td width="239" bordercolor="#C0C0C0"> </td> <td bordercolor="#C0C0C0"><input type="submit" value="Gnder" name="B3"></td> </tr> </table> </form> <% dim islem islem = Request. QueryString if islem = "ekle" then baslik = Request. Form ozet = Request. Form resim = Request. Form haber = Request. Form set kaydet = Server. CreateObject SQL = "Select from tblhaber " kaydet. open SQL, conn,1,3 kaydet. Addnew kaydet = baslik kaydet = ozet kaydet = haber kaydet = Date kaydet. update kaydet. close set kaydet = nothing conn. close set conn = nothing end if %> Yaşamın amacı "Amacı olan bir yaşammıdır" Hacı?

yazdıgım bi sayfayı direk atıyorum hocam. i$ine yarayan yaramayan her$ey var icinde :D editlemeden koyuyorum. <!--#include file="conn. asp"--><!--#include file="kontrol. asp"--><%Islem=Trim(Replace(Request. QueryString ,"'",""))LogoID=Trim(Replace(Request. QueryString ,"'",""))%><html><head><meta http-equiv="Content-Type" content="text/html; charset=windows-1254"><link href="../style. css" rel="stylesheet" type="text/css"><title>Logolar</title></head><body><% If Islem="LogoEkle" Then %><div align="center"> <form action="?Islem=LogoEkleTamam" method="post" enctype="multipart/form-data" accept-charset="utf-8"> <table border="0" width="301" height="57" cellpadding="0"> <tr> <td height="19" width="68" align="right">Resim:</td> <td height="19" width="230" align="left"><input type="file" name="Resim" size="10"></td> </tr> <tr> <td height="19" width="68" align="right">Açıklama:</td> <td height="19" width="230" align="left"><input type="text" name="Aciklama" size="22"></td> </tr> <tr> <td height="20" width="68" align="right">Sıra:</td> <td height="20" width="230" align="left"><input type="text" name="Sira" size="22" value="1"></td> </tr> <tr> <td height="20" width="68" align="right"></td> <td height="20" width="230" align="left"><input type="submit" value="Kaydet" name="Kaydet"></td> </tr> </table> </form></div><%ElseIf Islem="LogoEkleTamam" ThenServer. ScriptTimeout = 500000Function kod Const szDefault = "abcdefghijklmnopqrstuvxyzABCDEFGHIJKLMNOPQRSTUVXYZ0123456789" Dim nCount Dim sRet Dim nNumber Dim nLength Randomize If sValidChars = "" Then sValidChars = szDefault End If nLength = Len For nCount = 1 To nNoChars nNumber = Int + 1) sRet = sRet & Mid( sValidChars, nNumber,1) Next kod = sRetEnd FunctionRastgeleKod = "resim-" + kod(30,"")Set Upload = Server. CreateObject Upload. CodePage = 65001 Upload. OverwriteFiles = False Upload. ProgressID = PID Yol = Server. MapPath &"/" Upload. IgnoreNoPost = True Upload. OverwriteFiles = False YeniDosya = session. sessionID& "_" &RastgeleKod Upload. Save For Each File in Upload. Files File. Move Yol & YeniDosya & File. Ext resim_adi = yenidosya & File. ExtSet Jpeg = Server. CreateObject Path = Server. MapPath Jpeg. Open Path Jpeg. Width = Jpeg. OriginalWidth jpeg. Height = Jpeg. OriginalHeight Jpeg. Canvas. Brush. Solid = False Jpeg. Save Server. MapPath Set fso = CreateObject fso. DeleteFile(Server. MapPath Set Fso = NothingNextrs. Open "Select From Logolar", baglanti,1,3rs. AddNewrs =resim_adirs =Upload. Form Sira=Upload. Form If Sira="" Then Sira=1rs =Int rs. UpdateLogoID=rs rs. CloseResponse. Write "<script>window. location. href='logo_onizleme. asp?LogoID=" & LogoID & "';</script>"%><%ElseIf Islem="LogoDuzenle" ThenIf LogoID="" Or IsNumeric =False Then Response. Write "<script>window. location. href='logolar. asp';</script>"%><div align="center"> <form action="?Islem=LogoDuzenleTamam" method="post"> <table border="0" width="301" height="57" cellpadding="0"> <% rs. Open "Select From Logolar Where LogoID=" & LogoID, baglanti,1,3 %> <tr> <td height="19" width="68" align="right">Açıklama:</td> <td height="19" width="230" align="left"><input type="text" name="Aciklama" size="22" value="<% =rs %>"></td> </tr> <tr> <td height="20" width="68" align="right">Sıra:</td> <td height="20" width="230" align="left"><input type="text" name="Sira" size="22" value="<% =rs %>"></td> </tr> <tr> <td height="20" width="68" align="right"><input type="hidden" name="LogoID" value="<% =LogoID %>"></td> <td height="20" width="230" align="left"><input type="submit" value="Kaydet" name="Kaydet"></td> </tr> <% rs. Close %> </table> </form></div><%ElseIf Islem="LogoDuzenleTamam" ThenLogoID=Request. Form If LogoID="" Or IsNumeric =False Then Response. Write "<script>window. location. href='logolar. asp';</script>"rs. Open "Select From Logolar Where LogoID=" & LogoID, baglanti,1,3rs =Request. Form Sira=Request. Form If Sira="" Then Sira=1rs =Int rs. Updaters. CloseResponse. Write "<script>window. location. href='logolar. asp';</script>"%><%ElseIf Islem="LogoSil" ThenIf LogoID="" Or IsNumeric =False Then Response. Write "<script>window. location. href='logolar. asp';</script>"rs. Open "Select From Logolar Where LogoID=" & LogoID, baglanti,1,3If rs. EOF ThenResponse. Write "<center>Hata!</center>"ElseResimYolu=rs OnizlemeResim=rs rs2. Open "Delete From Logolar Where LogoID=" & LogoID, baglanti,1,3Set fso = CreateObject fso. DeleteFile(Server. MapPath fso. DeleteFile(Server. MapPath Set Fso = NothingResponse. Write "<script>window. location. href='logolar. asp';</script>"End If%><% Else %><div align="center"> <table border="1" width="301" height="41" cellpadding="0" style="border-collapse: collapse" bordercolor="#CCCCCC"> <tr> <td height="19" width="25" align="center">Sıra</td> <td height="19" width="243" align="center">Açıklama</td> <td height="19" width="30" align="center">Sil</td> </tr> <% rs. Open "Select From Logolar Order By Sira Asc", baglanti,1,3 Do Until rs. EOF %> <tr> <td height="20" width="25" align="center"><% =rs %></td> <td height="20" width="243" align="center"><a href="?Islem=LogoDuzenle&LogoID=<% =rs %>"><% =rs %></a></td> <td height="20" width="30" align="center"><a href="?Islem=LogoSil&LogoID=<% =rs %>"><img border="0" src="img/remove. gif" width="15" height="15"></a></td> </tr> <% rs. MoveNext Loop rs. Close %> </table> <p align="center"><font size="2"><a href="?Islem=LogoEkle">Logo Ekle</a></font></p></div><% End If %></body></html> screw you guys! i"m goin" hoooome!

Hocam persist upload a gre şyle bir sayfa yazdım. Lütfen yaptığım hataları düzeltebelirmisin, bende ğreneyim. Yapmak istediğim şu bir haber ekle sayfası yapıp haber basliği, ozeti, haber resmi ve haber verileri oluşturup bunları db ye yazmak. Tabi bunu yaparken de kullanacağım haber resmini sunucuya upload edip resim dosyası ismini de db ye kayıt edip link olarak kullanabilmek. Yardımcı olursanız sevinirim. db tablosu sütun isimleri : id, baslik, ozet, resim, tarih <!--#include file ="conn. asp"--><head><meta http-equiv="Content-Language" content="tr"></head><script language="javascript" type="text/javascript" src="../jscripts/tiny_mce/tiny_mce. js"></script><script language="javascript" type="text/javascript">tinyMCE. init({ // General options mode : "textareas", theme : "advanced", plugins : "safari, pagebreak, style, layer, table, save, advhr, advimage, advlink, emotions, iespell, inlinepopups, insertdatetime, preview, media, searchreplace, print, contextmenu, paste, directionality, fullscreen, noneditable, visualchars, nonbreaking, xhtmlxtras, template", // Theme options theme_advanced_buttons1 : "save, newdocument,|, bold, italic, underline, strikethrough,|, justifyleft, justifycenter, justifyright, justifyfull,|, styleselect, formatselect, fontselect, fontsizeselect", theme_advanced_buttons2 : "cut, copy, paste, pastetext, pasteword,|, search, replace,|, bullist, numlist,|, outdent, indent, blockquote,|, undo, redo,|, link, unlink, anchor, image, cleanup, help, code,|, insertdate, inserttime, preview,|, forecolor, backcolor", theme_advanced_buttons3 : "tablecontrols,|, hr, removeformat, visualaid,|, sub, sup,|, charmap, emotions, iespell, media, advhr,|, print,|, ltr, rtl,|, fullscreen", theme_advanced_buttons4 : "insertlayer, moveforward, movebackward, absolute,|, styleprops,|, cite, abbr, acronym, del, ins, attribs,|, visualchars, nonbreaking, template, pagebreak", theme_advanced_toolbar_location : "top", theme_advanced_toolbar_align : "left", theme_advanced_statusbar_location : "bottom", theme_advanced_resizing : true, // Example content CSS content_css : "css/content. css", // Drop lists for link/image/media/template dialogs template_external_list_url : "lists/template_list. js", external_link_list_url : "lists/link_list. js", external_image_list_url : "lists/image_list. js", media_external_list_url : "lists/media_list. js", // Replace values for the template plugin template_replace_values : });</script> <table border="1" width="100%" id="table1" height="50" cellspacing="0" cellpadding="0" bordercolor="#FFFFFF"><form action="haberekle. asp?islem=ekle" method="post" enctype="multipart/form-data"> <tr> <td width="239" height="25" bordercolor="#C0C0C0"> HABER BAŞLIĞI</td> <td height="25" bordercolor="#C0C0C0"> <p><input type="text" name="baslik" size="88"></p> </td> </tr> <tr> <td width="239" bordercolor="#C0C0C0"> HABER ZETİ</td> <td bordercolor="#C0C0C0"><input type="text" name="ozet" size="88"></td> </tr> <tr> <td width="239" bordercolor="#C0C0C0"> HABER RESMİ</td> <td bordercolor="#C0C0C0"><input class="formic" type="file" name="resim"></td> </tr> <tr> <td width="239" bordercolor="#C0C0C0"> HABER İÇERİĞİ</td> <td bordercolor="#C0C0C0"><textarea name="haber" rows="12" cols="65"> </textarea></td> </tr> <tr> <td width="239" bordercolor="#C0C0C0"> </td> <td bordercolor="#C0C0C0"><input type="submit" value="Gnder" name="B3"></td> </tr></table></form><%dim islemislem = Request. QueryString if islem = ekle thenSet Upload = Server. CreateObject Upload. OverwriteFiles = FalseUpload. codePage = 1254Upload. save Server. MapPath Set File1 = upload. Files set kaydet = Server. CreateObject SQL = "Select from tblhaber"kaydet. open SQL, conn,1,3 baslik = Request. Form ozet = Request. Form haber = Request. Form kaydet = kaydet = kaydet = +file1. filenamekaydet = kaydet. updatekaydet. closeset kaydet = nothingconn. closeset conn = nothingresponse. Redirect request. ServerVariables end if%> Yaşamın amacı "Amacı olan bir yaşammıdır" Hacı?

hocam dei$iklik deilde ekleme yapılması gerek. multipart kullandıgına gre bi upload i$lemi yapıcaksın anladıgım kadarıyla?upload icin gerekli kodu ekle. düzenleme kısmını yaparım ben :)upload işlemi yoksa enctype'ı kaldır calı$ır zaten. screw you guys! i"m goin" hoooome!

hatayı da yazarmısın

Hocam şunu kendi sayfam üzerinden gsterebilseydin iyi olacaktı :) Yaşamın amacı "Amacı olan bir yaşammıdır" Hacı?