vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   Modification Graveyard (https://vborg.vbsupport.ru/forumdisplay.php?f=224)
-   -   Add-On Releases - gItemStats - World of Warcraft Itemstats (https://vborg.vbsupport.ru/showthread.php?t=141177)

sweede 11-30-2007 01:44 PM

I have the parser working as it should be,
http://dramaloot.com/test2.php
what happens is you do the normal [item]whatever[/item] , and it goes off to grab the xml from wowhead (it needs to get the item id). after parsing the XML, it writes a URL link in the proper format
HTML Code:

<a class="q4" href="http://www.wowhead.com/?item=32239">[Slippers of the Seacaller]</a>
So now, I need to implement caching, because having to hit wowhead each page refresh is pretty inefficent.

I don't think i'll be able to have the entire thing as a plugin w/no external files to upload, but i dont think that will be a problem.

The cache will use the existing gItemStats tables because it stores the two things you need, the item id and the item name.

Newfarm 11-30-2007 02:23 PM

Awesome, that's really, really cool! Keep it up :)

sweede 11-30-2007 03:41 PM

My own release.
While i could be a jerk and post as my own plugin, i wouldnt have made this if it wasnt for Gryphon anyways.

This replaced gItemStats mod all together

install the attached XML file

then un-install the gItemStats

after that, you can delete the itemstats folder and the /includes/functions_gitemstats.php file

My plugin creates a new database table and copies the needed data (item name, item id and item quality) from your existing gitemstats table.

I don't see it being a challege to modify it so that it would either use thottbot or wowhead, but i prefer wowhead so i'm not changing it :)

actually, hold on a few. i used to use the itemstats_parse() function in other areas, so im going to replace that in my addon.

sweede 11-30-2007 04:03 PM

Since the main functions load up in global_start , you can use itemstats_parse("item name"); in things like custom pages and VBAdvanced modules.

I already had two custom modules written that used the gItemStats method itemstats_parse("[item]Guild Tabard[/item]");

so i adapted it to work with that also.

Gryphon 11-30-2007 04:06 PM

My originial intention with gItemStats was just make ItemStats a simple upload and configure via vB options.

It appears you are doing exactly what I am working on for my revamp of the code. I never suggested there would be no caching.

*Edit, posted while I was posting. Any reason you include xml parser code when vBulletin already has it's own class?

Ninok 11-30-2007 04:50 PM

Quote:

Originally Posted by sweede (Post 1392408)
Since the main functions load up in global_start , you can use itemstats_parse("item name"); in things like custom pages and VBAdvanced modules.

I already had two custom modules written that used the gItemStats method itemstats_parse("[item]Guild Tabard[/item]");

so i adapted it to work with that also.

I imported this into my board and it works, but for some reason the "A class=q4" is no where to be found. So the links are showing up incorrectly. I will wait for Gryphon to release his update and see if he allows wowhead and whatnot.

sweede 11-30-2007 06:04 PM

go to any page in your browser and view source

Look for

HTML Code:

<!-- WoWHead Mouseover-Tooltips -->
<script src="http://www.wowhead.com/widgets/power.js" type="text/javascript"></script>
<!-- /WoWHead Mouseover-Tooltips -->

somewhere in your header (the template is wowhead_headerinclude)

Ninok 11-30-2007 06:15 PM

Quote:

Originally Posted by sweede (Post 1392472)
go to any page in your browser and view source

Look for

HTML Code:

<!-- WoWHead Mouseover-Tooltips -->
<script src="http://www.wowhead.com/widgets/power.js" type="text/javascript"></script>
<!-- /WoWHead Mouseover-Tooltips -->

somewhere in your header (the template is wowhead_headerinclude)

I looked for sometype of include, and it didn't exist.
I had to manually add that line to the header of the style, and now it works. With is was Bold like iteam stats though. That really made it stand out against darkers styles.

sweede 11-30-2007 06:17 PM

odd.

create a new template named
wowhead_headerinclude

put the
HTML Code:

<!-- WoWHead Mouseover-Tooltips -->
<script src="http://www.wowhead.com/widgets/power.js" type="text/javascript"></script>
<!-- /WoWHead Mouseover-Tooltips -->

in it and that should fix it.

Gryphon 11-30-2007 06:32 PM

You didn't include any templates in your product, that is why it is missing.


All times are GMT. The time now is 08:07 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01266 seconds
  • Memory Usage 1,746KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (4)bbcode_html_printable
  • (2)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)pagenav_pagelinkrel
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete