• 20-11-2012, 04:04:12
    #1
    Mrb arkadaşlar kafayı yiyeceğim yardım edim bir tane emlak scripti buldum kurdum kurulum sorunsuz ama tek eksiği resim yükleyince resmi hosta yüklemiyor siteyede eklemiyor. Rica etsem yardımcı olabilecek biri var mı? Hayrına ya da ücretli de olabilir sadece şunu halledelim.

    Resmi upload ettiğim dosya kodları;

    <? include "include/all.php";?>
    <?
     $ParentID = $_REQUEST['ParentID'];
     $Action   = $_REQUEST['Action']; 
     $ID       = $_REQUEST['ID'];
     
     if (isset($_REQUEST['miSend'])) 
     { 
     	 $sql = "insert into t_advert_images (ParentID, Seq, Visible) values('".$ParentID."', '".$_REQUEST['Seq']."', '".getVisible($_REQUEST['Visible'])."')";
    	 insertSql($sql);
    	 $LastID = simpleQuery("select ID from t_advert_images where ParentID='".$ParentID."' order by Seq desc");
    	 
    	 $list = getImageInfo1();
    	 foreach ($list['items'] as $rs) 
    	 {
    	 	if(uploadImage($_FILES['Image']['tmp_name'], "../".$rs['path']."/".$ParentID."_".$LastID."_".$rs['name'].".jpg", $rs['width'], $rs['height'], $rs['compress'], $rs['watermark_image'], "../".$rs['watermark_logo'], $rs['watermark_border_width'], $rs['watermark_position'], $rs['image_text'], $rs['text'], "../".$rs['font_type'], $rs['font_size'], $rs['alpha'], $rs['text_position'], $rs['text_border_width']) == true)
    		{
    			$sql = "update t_advert_images set Images='".$ParentID."_".$LastID."' where ID='".$LastID."'";
    			updateSql($sql);
    		}
    		else
    		{
    			break;
    		}
    	 }
    	 
    	 if(!$error)
    	 {
    	 	 $CloseWindow  = "<script>\n";
    		 $CloseWindow .= "\twindow.opener.location.reload();\n";
    		 $CloseWindow .= "\twindow.close();\n";
    		 $CloseWindow .= "</script>\n";
    	 }
    	 else
    	 {
    	 	echo $error;
    	 }
     }
    
    
    	$sql = "select * from t_advert_images  where ID='".$ID."'";
    	$qr = mysql_query($sql);
    	$rs = mysql_fetch_array($qr);
    ?>
    <html>
    <head>
    <SCRIPT language=Javascript src="js/function.js"></SCRIPT>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
    <title> <?=($Title)?></title>
    <style type="text/css">
    <!--
    body {
    	background-color: #e0e0e0;
    	margin-left: 0px;
    	margin-top: 0px;
    	margin-right: 0px;
    	margin-bottom: 0px;
    }
    -->
    </style>
    <link href="css/style.css" rel="stylesheet" type="text/css">
    <?=(isset($CloseWindow)?$CloseWindow:"")?>
    <?=(isset($Err)?$Err:"")?>
    </head>
    <body>
    <br>
    <form method="post" action="advert_add_images.php" enctype="multipart/form-data">
    <input type="hidden" name="miSend" id="miSend" value="1">
    <input type="hidden" name="Action" id="Action" value="<?=($Action)?>">
    <input type="hidden" name="ParentID" id="ParentID" value="<?=($ParentID)?>">
    <input type="hidden" name="ID" id="ID" value="<?=($ID)?>">
    <?=(getContentTop(AddNewImage, "144"))?>
    <table width="100%" border="0" cellspacing="0" cellpadding="0">
      <tr>
        <td height="25" id="lang-menu"><table width="100%" height="25" border="0" cellpadding="0" cellspacing="0">
          <tr>
            <td width="5"><img src="images/spacer.gif" width="1" height="1"></td>
            <td class="FontBlueBold"></td>
            </tr>
        </table></td>
      </tr>
      <tr>
        <td><table width="100%" border="0" cellspacing="0" cellpadding="0">
          <tr>
            <td><table width="100%" border="0" cellpadding="0" cellspacing="0" bgcolor="e0e0e0">
              <tr>
                <td height="30" class="record-inactive">&nbsp;<?=(Image)?> 1</td>
                <td class="record-inactive"><table width="100%" border="0" cellspacing="0" cellpadding="0">
                    <tr>
                      <td width="100"><input name="Image" type="file" id="Image"></td>
                    </tr>
                </table></td>
              </tr>
              <tr>
                <td height="25" class="record-active">&nbsp;<?=(Sequence)?></td>
                <td class="record-active"><input name="Seq" type="text" id="Seq" class="price-input" onKeyDown="return CheckNumberCode(event);" value="<?=($rs['Seq']!=''?$rs['Seq']:GetName("select * from t_advert_images where ParentID='".$ParentID."'order by Seq desc", "Seq")+5)?>" size="5" maxlength="4"></td>
              </tr>
              <tr>
                <td width="120" height="25" class="record-inactive">&nbsp;<?=(Show)?></td>
                <td class="record-inactive"><input name="Visible" type="checkbox" id="Visible" value="1" class="checkbox" <?=($rs['Visible']==1?"checked":"")?>></td>
              </tr>
            </table></td>
          </tr>
        </table></td>
      </tr>
    </table>
    <?=(getContentFooter())?>   
    <table border="0" cellpadding="0" cellspacing="0" width="100%">
    	<tr>
        	<td>&nbsp;</td>
            <td width="100"><input type="button" class="button" onClick="window.close();" value="<?=(Cancel)?>"></td>
            <td width="5"></td>
            <td width="100"><input type="submit" class="button" value="<?=(Save)?>"></td>
            <td width="7"></td>
        </tr>
    </table>
    </form> 
    <br>
    </body>
    </html>
  • 20-11-2012, 10:56:06
    #2
    Üyeliği durduruldu
    $_REQUEST->$_POST olarak değiştirir misiniz?
  • 20-11-2012, 14:13:07
    #3
    Kimlik doğrulama veya yönetimden onay bekliyor.
    herhangibir hata firlatiyor mu kodlar?
  • 20-11-2012, 16:04:00
    #4
    Dün hata vermiyordu bugün resim yüklerken hata veriyor şöyle bir hata alıyorum;

    File Name : Resource id #20
    Function Name : imagecreatetruecolor()
    Message : Bilinmeyen hata olustu

    lap10 dediğin kodu denedim oda olmadı aynı hatayı veriyor.
  • 20-11-2012, 16:08:37
    #5
    klasörün yazma izinlerini kontrol ediniz
  • 20-11-2012, 16:13:23
    #6
    izinlerin hepsi 777 yazma izinleri var
  • 20-11-2012, 16:17:56
    #7
    imagecreatetruecolor fonksiyonunu kullanımında bi sıkıntı var fonksiyonun kullanıldığı yeri yani advert_add_images.php yazarsanız yardımcı olmaya çalışalım

    advert_add_images.php gerci bu sayfanın içeriğiymiş zaten arkadaşın dediği gibi all.php'de dönüyo hata
  • 20-11-2012, 16:18:17
    #8
    Üyeliği durduruldu
    Alıntı
    uploadImage($_FILES['Image']['tmp_name'], "../".$rs['path']."/".$ParentID."_".$LastID."_".$rs['name'].".jpg", $rs['width'], $rs['height'], $rs['compress'], $rs['watermark_image'], "../".$rs['watermark_logo'], $rs['watermark_border_width'], $rs['watermark_position'], $rs['image_text'], $rs['text'], "../".$rs['font_type'], $rs['font_size'], $rs['alpha'], $rs['text_position'], $rs['text_border_width']) == true
    uploadImage()
    bu fonksiyon include/all.php'in içerisinde ona bakarsan görebilirsin o fonksiyonu onu kontrol etmemek lazm . hata veren all.php'in içerisinde GD Kütüphanesinin mevcut oldugunu göreceksin.
    imagecreatetruecolor(); orda sıkıntı çıkarıyor
  • 20-11-2012, 16:21:54
    #9
    include/all.php bu dosya şifreli hocam

    Alıntı
    <?php //003ab
    if(!extension_loaded('ionCube Loader')){$__oc=strtolower(substr(php_uname(),0,3) );$__ln='ioncube_loader_'.$__oc.'_'.substr(phpvers ion(),0,3).(($__oc=='win')?'.dll':'.so');@dl($__ln );if(function_exists('_il_exec')){return _il_exec();}$__ln='/ioncube/'.$__ln;$__oid=$__id=realpath(ini_get('extension_d ir'));$__here=dirname(__FILE__);if(strlen($__id)>1 &&$__id[1]==':'){$__id=str_replace('\\','/',substr($__id,2));$__here=str_replace('\\','/',substr($__here,2));}$__rd=str_repeat('/..',substr_count($__id,'/')).$__here.'/';$__i=strlen($__rd);while($__i--){if($__rd[$__i]=='/'){$__lp=substr($__rd,0,$__i).$__ln;if(file_exists ($__oid.$__lp)){$__ln=$__lp;break;}}}@dl($__ln);}e lse{die('The file '.__FILE__." is corrupted.\n");}if(function_exists('_il_exec')){re turn _il_exec();}echo('Site error: the file <b>'.__FILE__.'</b> requires the ionCube PHP Loader '.basename($__ln).' to be installed by the site administrator.');exit(199);
    ?>
    4+oV5EgDpr8BRZHbnZHQSRnEOjSK5vH73hp46goizfA/rgRevHDRKoaaIpx9GoSHldBxSSZuFwTV
    OvbgaY96NG945Mk+pKnHXPj2B87nRDuSqqEtGho+DbdsMwNll+ LGFy10jfxUObhoioY9cXIPanzC
    EefOurngUTLZpkL03JOX1a5Qu01DAIOW2RF7YLhjSRShGoB8Rc EpFi/+NBS/ZXQxrZ76R2yW8Txv
    H2VcbRJKl6JNeJrw0xze8zDZBhmVBBZuNiVu6u4f86DUbh/fuQERfPQkhT7LClPP/+ocUPebC5i1
    v4cUn9SLkSs7X+E7mNPn+deujRdUebENlzaHj+Gp+kJhgs4ITj VELpt68NpraSTrl7lZvafJY53o
    aUjpU8n/acTFBJHlnLzXMAoAG79HcINT7kF72Cvi2VH/uHEhxP7P1UjepihXob/Co7Qgg3eF0wTn
    ho8sTjOuUVI6bArDle+g/9qGkLPzHfMcrDtTVr3aZza0nTMxZkjkZdDB0E2ZA8Um3ooDWA6 uvMDv
    31h4dprt3Pamo+Ql3P28L3rJJkpZjVurfaG1sxb+BbNyo3POUX Mg6wd2h+AhSKhzv8XG9BIBTnRQ
    rq/TtJjXmegd1SHAkVvUbSiMtdn0B3ESI2USUYJdcx6UctB9aqMVg xXVtro2tFq9ev7Z/bkSqRHV
    6yZm8KyIGmRD1eTRjOVNiPaq3ibM5//0KMT7vRTSh6Rk