Apr
2007
4

How to fix UTW when it stops returning Tags

by

Ultimate Tag Warrior is an awesome plugin. If you don't have it, get it, NOW!  *waiting...waiting*

Ok, now that everyone is back, let's discuss a problem I ran into and how to fix it. When you write a post and have the UTW plugin activated, you will notice a section below the post edit box that gets related tags for you. UTW sends your post to Yahoo's content api, and then Yahoo returns keywords based on the content...really cool stuff. You can see the Yahoo content API Here.

The API will only send 5,000 queries per application ID. So if you click on the "Get Keyword Suggestions From Yahoo" button and nothing happens UTW has probably reached it's limit of queries. Think about how many blogs UTW is installed on...it's a lot.

You can fix this by adding your own Yahoo API Application ID. I know it sounds hard but I don't think you have to even go to yahoo to change it.

The file to edit is in the UTW plugin folder. The file name is ultimate-tag-warrior-ajax.php 

On line 95 you will see $appID = "wp-UltimateTagWarrior"; If your editor does not have line numbers, you can search for "wp-UltimateTagWarrior". Change the appID to whatever you want, but make it unique because if the appID is already in use by another large website you might just run into the same problem as before. I changed the appID to my credit card number: 4532-2344... J/k Tongue out

anyhow, once it is changed, re-upload the file and go check it on a post...it should work and return the tags based on the content of your post. 

Here is another useful code snippet I use to return tags based on content
You can try the code out here: My Keyword Generator
Simply send it content and it returns the keywords, don't forget to change the appID in the snippet too.

PHP:
  1. function get_keywords($context)
  2. {
  3. // output=php means that the request will return serialized PHP
  4. $request'http://search.yahooapis.com/ContentAnalysisService/V1/termExtraction';
  5. $ch = curl_init($request);
  6. $fields = array(
  7. "context" => $context,
  8. "appid" => 'your_App_ID',
  9. "output" => 'php'
  10. );
  11. $sendheaders = array("User-Agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; .NET CLR 1.1.4322; .NET CLR 2.0.50727)",);
  12. curl_setopt($ch, CURLOPT_POST, 1);
  13. curl_setopt($ch, CURLOPT_HEADER, 0); // set to 0 to eliminate header info from response
  14. curl_setopt($ch, CURLOPT_NOBODY, 0); // set to 1 to eliminate body info from response
  15. curl_setopt($ch, CURLOPT_HTTP_VERSION, CURL_HTTP_VERSION_1_0); // use HTTP/1.0 instead of 1.1
  16. curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); // Returns response data instead of TRUE(1)
  17. curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, FALSE); // uncomment this line if you get no gateway response. ###
  18. curl_setopt($ch, CURLOPT_HTTPHEADER, $sendheaders);
  19. curl_setopt($ch, CURLOPT_POSTFIELDS, $fields); // use HTTP POST to send form data
  20.  
  21. $resp = curl_exec($ch); //execute post and get results
  22. curl_close ($ch);
  23. //echo $resp;
  24.  
  25. if ($resp === false) {
  26.     die('Request failed');
  27. }
  28.  
  29. $phpobj = unserialize($resp);
  30. return $phpobj;
  31. }

Popularity: 7% [?]

Other posts you might be interested in
  • Better SEO for your Website using Plugins and Tags -Part 2  Ok, so we have our tags set up from part 1 for single post pages. Now we need to make
  • Real World SEO Examples – How important is your website title?  First off, I hate SEO, (search engine optimization)...I hate it because, for one, nobody really knows what the search engine
  • Post your Single Property Website to Craigslist, No Editing Required   First, I want to note that Craigslist has updated their formatting again...Our flyers, Postlets and Vflyer are all affected by
  • Hiding Pages with Wordpress part 2 – Errors, Omissions, and Solutions  In a previous post, how to hide pages in wordpress, I talked about hiding pages in wordpress. I gave three
  • pingback bouncer…stop the refer spam with this plugin  I was reading a post on condodomain, about a crackberry???? and email addiction. Good post, but you will never get


  • Leave a Reply

    Close
    E-mail It
    Rodney's Adsense-Deluxe Add ons plugged in.