![]() |
![]() |
![]() |
||||
Welcome to the GoFuckYourself.com - Adult Webmaster Forum forums. You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today! If you have any problems with the registration process or your account login, please contact us. |
![]() ![]() |
|
Discuss what's fucking going on, and which programs are best and worst. One-time "program" announcements from "established" webmasters are allowed. |
|
Thread Tools |
![]() |
#1 |
Confirmed User
Join Date: Feb 2006
Posts: 994
|
Wordpress question
Hi Guys,
I've tweaked my theme long ago heavily but i forgot where to edit tag cloud is it stored in functions.php? Single post on my site looks like this: Leaked photos of very cute Chinese police girl blowing her BF part 1/3 | Asian Sex tags are at the bottom i would like to edit tags somehow so i'll have displayed only those tags which are from current post not top 50 tags. this is tag cloud code i've copied from functions.php is it this code which i need to edit? Code:
add_filter ( 'wp_tag_cloud', 'tag_cloud_count' ); function tag_cloud_count( $return ) { $tags = explode('</a>', $return); $regex = "#(.*title[=]')(.*)( topic.*)#e"; foreach( $tags as $tag ) { $tagn[] = preg_replace($regex, "('$1$2$3 ($2 post'.(($2!=1)?'s':'').')')", $tag ); } $return = implode('</a>', $tagn); return $return; }
__________________
Pure Japan japanese babes blog |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#2 |
Too lazy to set a custom title
Industry Role:
Join Date: Jun 2006
Posts: 11,408
|
You are kidding right ???
![]() |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#3 |
Confirmed User
Join Date: Feb 2006
Posts: 994
|
not at all. i really don't remember where to edit tags code.
year ago i've replaced standard tag code with one which displays posts count next to tag but i don't remember where was it.
__________________
Pure Japan japanese babes blog |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#4 |
Confirmed User
Join Date: Feb 2006
Posts: 994
|
i googled and i found this piece of code:
To get a list of only the tag IDs for a particular post: Code:
global $post; $tag_ids = wp_get_post_tags( $post->ID, array( 'fields' => 'ids' ) ); wp_get_post_tags() which is located in wp-includes/post.php is that correct? how to call it inside post? tried this one: <?php wp_get_post_tags( $post_id, $args ) ?> but effect is blank space ed.: ok, ive tried different code: <?php $posttags = get_the_tags(); if ($posttags) { foreach($posttags as $tag) { echo $tag->name . ' '; } } ?> but it displays tags with no links, but i'm getting close :D ed2.: with this code i'm getting what i wanted <?php the_tags( 'Tagged with: ', ' • ', '<br />' ); ?> now i need to find how to add tag counts.
__________________
Pure Japan japanese babes blog |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#5 |
Grrrrrrrrr
Industry Role:
Join Date: Oct 2002
Location: Dreamland
Posts: 4,974
|
Get a plugin.
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#6 |
Just Doing My Own Thing
Industry Role:
Join Date: Jan 2011
Location: London, Spain, New Zealand, GFY - Not Croydon...
Posts: 25,064
|
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#7 |
Confirmed User
Industry Role:
Join Date: Jun 2012
Posts: 457
|
|
![]() |
![]() ![]() ![]() ![]() ![]() |