MissingRecipes port to V2

Quick and easy way to see what recipes your character is missing

Moderators: zeryl, Teta68

MissingRecipes port to V2

Postby Teta68 » Fri Dec 21, 2007 12:07 am

Hi,

I missed this addon in Roster v2, so I made a quick and dirty port from the original.

After installing in the RosterCP it adds an Icon in the Character Panel.

As you can see from the source, I stole most of the code from the "info" addon (in Roster v2) and the original addon. The port has only been checked with the enUS locale, I don't think it will work with other locales... up to you to test (and report back).

The port still gives some regedit and php errors that I need to fix. Don't know when I will do that, yet.

Anyway, have a go at using it and let me know how it works for you.

Teta

EDIT: Removed the attachment, download the addon in the downloads section.
Last edited by Teta68 on Tue Jun 24, 2008 8:45 pm, edited 3 times in total.
I break for giant Cyber-Hamsters.
User avatar
Teta68
Roster AddOn Dev
Roster AddOn Dev
 
Posts: 72
Joined: Fri Jan 19, 2007 12:15 pm
Location: Sweden

MissingRecipes port to V2

Postby benv666 » Fri Dec 21, 2007 4:03 am

Just installed it, but get a bunch of errors when I try to view it on my char:
Code: Select all
lib/functions.lib.php
  Warning line 1182: preg_match() [function.preg-match]: Compilation failed: missing ) at offset 19
  Warning line 1182: preg_match() [function.preg-match]: Compilation failed: missing ) at offset 19
  Roster Warning line 1169: UrlGrabber Error [CURL]: Operation timed out after 5 seconds with 865369 bytes received
addons/missingrecipes/char/index.php
  Notice line 119: Undefined offset: 2
  Warning line 119: Invalid argument supplied for foreach()
  Notice line 126: Undefined offset: 2
  Warning line 126: array_diff() [function.array-diff]: Argument #1 is not an array
  Notice line 151: Undefined index: skill_level
  Notice line 151: Undefined index: skill_level
  Notice line 166: Undefined index: pat_link
  Notice line 151: Undefined index: skill_level
  Warning line 154: Invalid argument supplied for foreach()


You can see it for yourself here: http://roster2.handofhades.eu/index.php ... pes&a=c:63
benv666
WR.net Apprentice
WR.net Apprentice
 
Posts: 42
Joined: Wed May 09, 2007 5:04 pm
Location: The Netherlands

Re: MissingRecipes port to V2

Postby Teta68 » Fri Dec 21, 2007 5:25 am

yeah, looks like the data from allakhazam didn't load in time (the curl error), and I don't capture that.

Try setting the timeout on the urlgrabber command to 30 instead of the default 5, that should help a little. This will make curl wait longer to receive the data.

I tried your site and the 2nd time I clicked the missing recipes icon, it worked. So the above fix should work.

Change every line like the one below
Code: Select all
$allrecipes[$i] = urlgrabber('http://wow.allakhazam.com/db/skill.html?line=171');

to
Code: Select all
$allrecipes[$i] = urlgrabber('http://wow.allakhazam.com/db/skill.html?line=171',30);

There are 9 lines like that in total, the first at line 46.
Be careful not to change the number behind 'line='. That would be bad :P

Teta
Last edited by Teta68 on Fri Dec 21, 2007 5:26 am, edited 1 time in total.
I break for giant Cyber-Hamsters.
User avatar
Teta68
Roster AddOn Dev
Roster AddOn Dev
 
Posts: 72
Joined: Fri Jan 19, 2007 12:15 pm
Location: Sweden

MissingRecipes port to V2

Postby benv666 » Mon Dec 24, 2007 3:25 am

Thanks for the reply :)

It indeed fixed a bunch of the errors, and the recipes show too, so that's good :)

However, there are still some errors left. (dunno if they're harmful, but I never like errors/warnings much :-p)

I see
Code: Select all
  Warning line 1182: preg_match() [function.preg-match]: Compilation failed: missing ) at offset 19

a bunch of times and
Code: Select all
  Notice line 151: Undefined index: skill_level
  Notice line 166: Undefined index: pat_link

appear a lot too.

Any fixes for those? :)
benv666
WR.net Apprentice
WR.net Apprentice
 
Posts: 42
Joined: Wed May 09, 2007 5:04 pm
Location: The Netherlands

Re: MissingRecipes port to V2

Postby Teta68 » Thu Dec 27, 2007 8:10 pm

The first one is due to a mistake in the regular expressions. I need to look at it, but after the holidays.

Same goes for the next two warnings: if a crafting skill is not learned from a pattern, you get the pat_link warning and if a skill has no skill level defined in the allakhazam database, you get the skill_level warning. I need to fix that too, but again, after the holidays.

I'll keep you up to date.

Teta
I break for giant Cyber-Hamsters.
User avatar
Teta68
Roster AddOn Dev
Roster AddOn Dev
 
Posts: 72
Joined: Fri Jan 19, 2007 12:15 pm
Location: Sweden

MissingRecipes port to V2

Postby Snoopy59 » Wed Jan 02, 2008 7:58 pm

Hi
I test to install it in frFR, but an error message appear, in the Addon panel :
Erreurs relatives au programme d'installation
Le fichier contenant les définitions du programme d'installation pour missingrecipes ne contient pas de classes d'installation correctes

If someone can help me ...

Thx
Snoopy59
WR.net Apprentice
WR.net Apprentice
 
Posts: 24
Joined: Fri Nov 17, 2006 7:06 pm

MissingRecipes port to V2

Postby Holgiranemsi » Wed Jan 02, 2008 10:30 pm

It seems that this AddOn does only work for US/EN-Rosters.
There is no feedback of the Addon at all for DE, FR, etc.
as it compares the chardata (f.e. existent in German with an english Website)
;-(
Holgiranemsi
WR.net Journeyman
WR.net Journeyman
 
Posts: 88
Joined: Fri Feb 16, 2007 12:28 pm

Re: MissingRecipes port to V2

Postby Teta68 » Sun Jan 06, 2008 11:31 am

Snoopy59 wrote:Hi
I test to install it in frFR, but an error message appear, in the Addon panel :
Erreurs relatives au programme d'installation
Le fichier contenant les définitions du programme d'installation pour missingrecipes ne contient pas de classes d'installation correctes

If someone can help me ...

Thx
Hi,

As I said in my first post, this port of the original Missing Recipes will not work in other locales than enUS. If you find a site like allakhazam that can give all the recipes in french, you could try and work out a frFR version.

Teta
I break for giant Cyber-Hamsters.
User avatar
Teta68
Roster AddOn Dev
Roster AddOn Dev
 
Posts: 72
Joined: Fri Jan 19, 2007 12:15 pm
Location: Sweden

Re: MissingRecipes port to V2

Postby Theophilius » Mon Jan 07, 2008 1:40 am

Hi,

I'm just trying to make it works in frFR locale.

Allakhazam can be seen in frFR by adding the &locale=frFR to the used url.

For exemple, if you want to have the test db for the french alchemy just enter :

http://wow.allakhazam.com/db/skill.html ... ocale=frFR

8)

I'll post if I solve this.

Best regards.
Last edited by Theophilius on Mon Jan 07, 2008 1:41 am, edited 1 time in total.
User avatar
Theophilius
WR.net Apprentice
WR.net Apprentice
 
Posts: 28
Joined: Sat Feb 24, 2007 4:49 pm

Re: MissingRecipes port to V2

Postby Teta68 » Mon Jan 21, 2008 6:13 pm

I updated the addon to get rid of those annoying errors and warnings.
Download the new file (in the first post) and install the addon again.

Teta
Last edited by Teta68 on Tue Jan 22, 2008 7:48 pm, edited 2 times in total.
I break for giant Cyber-Hamsters.
User avatar
Teta68
Roster AddOn Dev
Roster AddOn Dev
 
Posts: 72
Joined: Fri Jan 19, 2007 12:15 pm
Location: Sweden

Re: MissingRecipes port to V2

Postby Theophilius » Tue Jan 22, 2008 2:52 am

Hi,

Here is a quick and dirty frFR only port. It's a pre-alpha one :)

It queries the test source from allakhazam as it's the most up-to-date and complete source for frFR (Edit: it seemed... arrrgggggg... :roll: ).

Some recipes are reported to be missing due to uppercase/lowercase issue even if you already know them. I'm not sure that accentuated letters are not posing problems too.

What need to be done :
- doing a localized version by introducing locale variables in the php code (ex: the words for Professions, Secondary skills, riding, fishing, etc are hardcoded) ;
- adding the good locale to the db url by adding a &locale=frFR or deDE or esES... (issue for multilingual roster ?) ;
- in frFR, solve the upper/lower/accent problem (Edit: Typo(s) in Allakhazam frFR db :( - mmmm, sounds like it could be better to write a parser for the judgehype liste :? ).

Enjoy (if it can be ;) )

Chris.
Attachments
missingrecipes-1.9.9.1555-frfr.zip
Quick and dirty frFR port
(4.71 KiB) Downloaded 414 times
Last edited by Theophilius on Tue Jan 22, 2008 5:24 am, edited 4 times in total.
User avatar
Theophilius
WR.net Apprentice
WR.net Apprentice
 
Posts: 28
Joined: Sat Feb 24, 2007 4:49 pm

Re: MissingRecipes port to V2

Postby Wyren » Tue Jan 22, 2008 8:58 pm

What I would like to see added to this addon is the "Bank Availability" mod that was done to the old roster 1.7.x addon. And perhaps grabbing the recipes from wowhead instead of allakhazam to get the recipe source (Drop, Vendor, Quest etc)
Wyren
WR.net Journeyman
WR.net Journeyman
 
Posts: 81
Joined: Wed Jul 26, 2006 3:07 pm

Re: MissingRecipes port to V2

Postby Teta68 » Tue Jan 22, 2008 9:31 pm

Hi Wyren,

I don't know what you mean with "bank availablity". Could you please explain?

I looked at the wowhead site, and I can't find a way to show all recipes of a certain profession on one page. It always shows the first 50, there's no "show all" option. If you can find a way to show them all on one page, I would be willing to give you the option of using allakhazam or wowhead in the addon.

Regards,

Teta

EDIT: It also seems that wowhead only shows the recipes, not what you can learn from profession trainers, or am I missing something?
Last edited by Teta68 on Tue Jan 22, 2008 9:37 pm, edited 1 time in total.
I break for giant Cyber-Hamsters.
User avatar
Teta68
Roster AddOn Dev
Roster AddOn Dev
 
Posts: 72
Joined: Fri Jan 19, 2007 12:15 pm
Location: Sweden

Re: MissingRecipes port to V2

Postby Holgiranemsi » Tue Jan 22, 2008 10:25 pm

@Theo
Where to get it? Is there a DL-Link for your version supporting FR (possibly DE) ?

Holgi :P
Holgiranemsi
WR.net Journeyman
WR.net Journeyman
 
Posts: 88
Joined: Fri Feb 16, 2007 12:28 pm

Re: MissingRecipes port to V2

Postby Diska » Tue Jan 22, 2008 10:52 pm

Teta68 wrote:EDIT: It also seems that wowhead only shows the recipes, not what you can learn from profession trainers, or am I missing something?


That depends on where you're looking. The page you want is probably the listing of all spells belonging to a profession, e.g.: http://www.wowhead.com/?spells=11.171

With items you can add &xml to a URL to get the results in XML, but that doesn't work with spell listings unfortunately. The XML option is present for item tooltips, not for data mining the website, that's why the feature isn't implemented.
User avatar
Diska
Roster AddOn Dev
Roster AddOn Dev
 
Posts: 179
Joined: Tue Jul 04, 2006 2:05 pm

Next

Return to Missing Recipes

Who is online

Users browsing this forum: No registered users and 0 guests

cron