привет, я нашел этот скрипт, он работает, когда я использую обычный charcter, но когда я пытаюсь вставить какие-то специальные символы, не работает, я попробовал json бежать, не повезло, может кто-нибудь помочь мне, что случилось? получить ошибкуWordpress auto post script
PHP Синтаксическая ошибка: синтаксическая ошибка, неожиданный 'HTTP' (T_STRING) в /var/www/html/auto_post.php на линии 20
<?php
require('wp-load.php');
function simpleImportPost($title,$import_id,$content){
// Create post object
$my_post = array();
$my_post['post_title'] = $title;
$my_post['import_id']=$import_id;
$mypost['comment_status'] = 'closed';//I'll set all closed
$my_post['post_content'] = $content;
$my_post['post_status'] = 'publish';
$my_post['post_author'] = 1;
$my_post['post_category'] = array(0);
// Insert the post into the database
return wp_insert_post($my_post);
}
$ch_name="Live_tv_1";
simpleImportPost("$ch_name",35,"<iframe src="http://site.xxx/jwplayer_6/elchourouk.html" style="width: 640px; height: 480px" scrolling="no" frameborder=0 ALLOWTRANSPARENCY="true" overflow:hidden; ></iframe>");
?>