=== Plugin Name ===
Contributors: wpxue,ym99
Tags: php,widget
Stable tags:trunk
Requires at least: 2.8
Tested up to: 3.0.1
== Description ==
This plugin adds a new widget called PHP Widget, which will allow you to include PHP code, you can have Text, HTML, Javascript, Flash and/or PHP code wordpress template tags as content or title in this widget.
So, as long as you want, it can do everything, that is greatful.
== Installation ==
1. Upload the folder wp-php-widget to the `/wp-content/plugins/
2. Activate the plugin through the 'Plugins' menu in WordPress
3. Navigate to Appear > widget > PHP widget
you will see PHP widget ,Use the widget like any other widget.
when you add the PHP widget ,you will see help.
== Help? ==
when you add the PHP widget ,you will see help.
==Usage . example==
`
title:
code:
test
title:url test
code:test
title:title
code:test
title:video
code:
title:New Posts最新文章
code:
title:Rand Posts随即文章
code:
'rand', 'showposts' => 10));
if (have_posts()) :
while (have_posts()) : the_post();?>
title:orderby comments评论排行
code:
get_results("SELECT comment_count,ID,post_title FROM $wpdb->posts ORDER BY comment_count DESC LIMIT 0 , 10");
foreach ($result as $post) {
setup_postdata($post);
$postid = $post->ID;
$title = $post->post_title;
$commentcount = $post->comment_count;
if ($commentcount != 0) { ?>
-
()
title:new comments最新评论
code:
title:postviews热门文章
code:
title:Time加载时间
code:
queries in s.
`
etc
You can have Text, HTML, Javascript, Flash and/or PHP code as content or title in this widget.
So, as long as you want, it can do everything, that is greatful.
== Screenshots ==
1. The widgets screen showing a PHP widget in use.
2. PHP widget .
== Changelog ==
= 1.0.2 =
fixed usage,add help link
= 1.0.1 =
add usage code
= 1.0.0 =
create PHP widget