kasra 4929 ارسال شده در تیر 93 گزارش بازنشر ارسال شده در تیر 93 من PHP Code Widget رو نصب کردم : http://wordpress.org/plugins/php-code-widget/ و کد های بالا رو به این شکل : <script src="http://code.jquery.com/jquery-latest.js" type="text/javascript">[b] Forum latest posts[/b]<script type="text/javascript"> $(document).ready(function() { $(".last-rls-movies").filter(function() { $(this).find("a").attr("target", "_blank"); }) }) در ابزارک PHP گذاشتم ولی کار نکرد . با افزونه vbulletin-latest-threads هم تست کردم که به این مشکل برخوردم وگرنه کار میکنه اون : برای این کار نکرد که کدهارو به صورت کامل نزاشتید ... 2 نقل قول لینک به ارسال
Black_Sky 6349 ارسال شده در تیر 93 گزارش بازنشر ارسال شده در تیر 93 با اجازه استادان کد زیر توی غانکشن قرار بدید:function _fetch_rss_feed($url) {while ( stristr($url, 'http') != $url )$url = substr($url, 1);if ( empty($url) )return;$rss = fetch_feed($url); $desc = ''; $link = '';if ( ! is_wp_error($rss) ) {$desc = esc_attr(strip_tags(@html_entity_decode($rss->get_description(), ENT_QUOTES, get_option('blog_charset'))));$link = esc_url(strip_tags($rss->get_permalink()));while ( stristr($link, 'http') != $link )$link = substr($link, 1);}$url = esc_url(strip_tags($url));wp_widget_rss_output($rss);}و کد زیر در هرجایی از قالب قرار بدید:<!-- wordpress --><script src="http://code.jquery.com/jquery-latest.js" type="text/javascript"></script><div class="last-wp-parsi"><h1>آخرین ارسال های انجمن</h1><?php _fetch_rss_feed('http://forum.wp-parsi.com/rss/forums/3-wp-parsi');?></div><script type="text/javascript">$(document).ready(function() {$(".last-wp-parsi").filter(function() {$(this).find("a").attr("target", "_blank");})})</script><!-- /wordpress -->موفق باشیدمن PHP Code Widget رو نصب کردم :http://wordpress.org...hp-code-widget/و کد های بالا رو به این شکل :<script src="http://code.jquery.com/jquery-latest.js" type="text/javascript"></script><div class="last-rls-movies"><h1>Forum latest posts</h1><?php _fetch_rss_feed('http://www.forum.rls-movies.com/external.php?type=rss2/');?></div><script type="text/javascript">$(document).ready(function() {$(".last-rls-movies").filter(function() {$(this).find("a").attr("target", "_blank");})})</script>در ابزارک PHP گذاشتم ولی کار نکرد .با افزونه vbulletin-latest-threads هم تست کردم که به این مشکل برخوردم وگرنه کار میکنه اون :http://forum.wp-pars...ه-اول-وردپرس-؟/شما هم همون مراحل بالا انجام بدید و کد گفته شده در فانشن قرار بدیددرضمن برای فعال سازی php در ابزارک نیاز به افزونه نیست کد زیر فانشک اضافه کنید :<?phpfunction php_execute($html){if(strpos($html,"<"."?php")!==false){ob_start();eval("?".">".$html);$html=ob_get_contents();ob_end_clean();}return $html;}?> 1 نقل قول لینک به ارسال
پست های پیشنهاد شده
به گفتگو بپیوندید
هم اکنون می توانید مطلب خود را ارسال نمایید و بعداً ثبت نام کنید. اگر حساب کاربری دارید، برای ارسال با حساب کاربری خود اکنون وارد شوید .