konuyla ilgili bilgisi olan arkadaşların yardımını bekliyorum.
ekle.php den sql sorgu güncelleyen satırlar aşağıdaki gibidir. yaparım diyen arkadaşlardan pm bekliyorum
$sorgu="INSERT INTO wp_posts(ID, post_author, post_date, post_date_gmt, post_content, post_title, post_category, post_excerpt, post_status, comment_status, ping_status, post_password, post_name, to_ping,pinged, post_modified, post_modified_gmt, post_content_filtered, post_parent, guid, menu_order, post_type, post_mime_type, comment_count) VALUES (NULL , '1', '$tarih', '$tarih', '$icerik', '$baslik', '0', '', 'publish', 'open', 'open', '', '$baslik_seo', '', '', '$tarih', '$tarih', '', '0', '', '0', 'post', '', '0') ";
mysql_query($sorgu);
$post_id=mysql_insert_id();//update yapilacak guid için
$guid_ekle=$eklenecek_site."?p=".$post_id;
mysql_query("update wp_posts set guid='$guid_ekle' where id='$post_id' limit 1");
//echo $kategori_id." - ";
$kategori_id_bul=@mysql_result(mysql_query("select term_taxonomy_id from wp_term_taxonomy where term_id='$kategori_id' and taxonomy='category'"),"term_taxonomy_id");
//echo $kategori_id_bul;
//post ile kategori birlestriliyor
mysql_query("INSERT INTO `wp_term_relationships` (`object_id`, `term_taxonomy_id`, `term_order`) VALUES ( '$post_id', '$kategori_id_bul' , '0' )");
//kategori degeri 1 arttirisiyor
mysql_query("update wp_term_taxonomy set `count`= `count` + '1' where term_id='$kategori_id' and taxonomy='category' limit 1");
//post ile keyword birlestiriliyor
$keywords_all=@p(",",$keywords);
//print_r($keywords_all);
foreach($keywords_all as $keyword){
$tag_id=wp_keyword_ekle($keyword);
//print_r($tag_id);
mysql_query("INSERT INTO `wp_term_relationships` (`object_id`, `term_taxonomy_id`, `term_order`) VALUES ( '$post_id' , '$tag_id' , '0') ");
}/**/
}
}//if sonu
?>