This site makes extensive use of JavaScript.
Please enable JavaScript in your browser.
Live
PTR
10.2.7
PTR
10.2.6
Beta
Force Wowhead script to ignore certain hyperlinks
Post Reply
Return to board index
Post by
eRAZOR2008
I would like to have certain items link to the corresponding page on wowhead, yet display my own tooltips for them. Unfortunately I need to display wowhead powered spell tooltips on a different section of the same page.
Is there a way to communicate to power.js to ignore individual links? If not, what are the chances that skosiris implements that in a timely fashion? :)
Post by
Wanderingfox
you can mess around with the javascript and remove the check for ?item= links but not spell, quest, or achievement links and then host the file locally.
However, the code for the power.js file is all obfuscated and you'll still need to properly site wowhead for their code.
Post by
pelf
You could write some simple PHP to make a quick fix to the problem. One possible way:
Create an item.php page.
Set it up to expect an ?item= GET parameter.
Make it tack the number after the ?item= onto the end of
http://www.wowhead.com/?item=
and just redirect to there.
The wowhead script wouldn't tooltip it because it's not linked to the right place, but clicking it would pretty instantly just redirect to the actual page.
Kind of a clunky way to do it, but it would work :). There are a lot of variations on the redirection idea.
Post by
eRAZOR2008
Would be much nicer if we could prevent the script from applying the tooltip by simply assigning a certain css class to the anchor tag.
Post by
pelf
Would be much nicer if we could prevent the script from applying the tooltip by simply assigning a certain css class to the anchor tag.
Agreed. They haven't been forthcoming in updating this stuff in the past, though. That's why I suggested it.
Post by
Erorus
I don't think the regular expression in the power.js will work on escaped characters. So you should be able to do something like:
http://www.wowhead.com/?%69tem=21870
Post by
eRAZOR2008
I don't think the regular expression in the power.js will work on escaped characters. So you should be able to do something like:
http://www.wowhead.com/?%69tem=21870
Allright, that's quite nice. Why didn't I come up with this :)
Post by
pelf
I don't think the regular expression in the power.js will work on escaped characters. So you should be able to do something like:
http://www.wowhead.com/?%69tem=21870
LOL! Genius.
Post by
eRAZOR2008
By the way, it works:
http://xarmory.com/c/8014717
The items link to wowhead, yet no tooltip is displayed even though the script is linked in the head section and used on the talent tab (talent tooltips).
Post by
pelf
By the way, it works:
http://xarmory.com/c/8014717
Nice site :). I hope you have some queuing system set up so you don't fall prey to the same issues a lot of those armory sites did where their requests got blocked because too many people started using them.
Also, on your about page, you have "developer's" instead of "developers".
Post by
eRAZOR2008
By the way, it works:
http://xarmory.com/c/8014717
Nice site :). I hope you have some queuing system set up so you don't fall prey to the same issues a lot of those armory sites did where their requests got blocked because too many people started using them.
Yes, we do :)
Also, on your about page, you have "developer's" instead of "developers".
Thanks. Fixed!
Post Reply
You are not logged in. Please
log in
to post a reply or
register
if you don't already have an account.