1. New to the forums? Check out our Mentorship Program!
    Our mentors will answer your questions and help you become a part of the community!
  2. Welcome to Smogon Forums! Please take a minute to read the rules.

Programming Smogon Search: Google Chrome Extension

Discussion in 'Technical Projects' started by Premonition, Oct 19, 2010.

  1. Premonition

    Premonition

    Joined:
    Oct 17, 2010
    Messages:
    9
    "A simple search engine for Smogon."

    First off, I'm pretty new to Smogon forums so tell me if I put this in the wrong place.

    This extension can search for Pokemon, items, abilities, moves, articles and more on Smogon's vast web pages. Simply click and type anything and the search engine will open a new tab with the desired web page.

    The search engine even comes with a maximum common subsequence, if you mispel a word, the extension will 'auto-correct' it and will redirect you to that page. For example, if you typed 'Growlathe' into the search bar, it will redirect you to 'Growlithe'.

    You can download this free extension here.

    Give me feedback, questions or whatever because I'm happy to answer them.
  2. auramaster

    auramaster

    Joined:
    Dec 17, 2008
    Messages:
    764
    I love the idea, but I tried it in both Chrome and Chromium, and it didn't work. Could just be my computer though.

    Technical info (open)
    Chrome is Linux 64-bit, version 6.0.472.63

    Chromium is Linux 64-bit, version 6.0.472.63 (59676)
  3. Veedrock

    Veedrock

    Joined:
    Oct 18, 2008
    Messages:
    2,780
    Wasn't working for me originally, but I updated my browser from 6.x.xxx.x to 7.0.517.41 and it's working great now.

    The mcs seems to work really well too, I butchered a few names pretty bad and it got me to the pages no problem. One thing I've noticed that doesn't work is if I put in a type (ie fire) the URL will come up http://www.smogon.com/dp/types/Fire, which directs to an invalid page because of the capital F in fire. Don't know how hard that would be to alter (personally I'd rather see this fixed on the site to accept caps, but that's not in your jurisdiction). It'd be nice if it cleared itself after each search too but that's nothing major.

    Thanks a lot, I'm glad to have a Smogon search that doesn't occupy the omnibar.
  4. Premonition

    Premonition

    Joined:
    Oct 17, 2010
    Messages:
    9
    OK, fixed the type problem. For some reason the site doesn't accept types starting with caps. Simply re-install the extension from the link i gave you. I also made the text clear itself so you don't have to backspace all the time.

    About the technical errors, I'm not sure about how to fix them but updating Google Chrome will probably solve it, though I'm pretty sure it isn't an error with the extension.

    Also, there is a slight size problem with the popup window which I am working on, though I still can't find the source of the problem. Tell me if you are experiencing similar errors in which the popup window changes size.

    I will update the extension as soon as I can. Thanks heaps for reviews and pointing out errors ^^

    You can help in fixing the size error if anyone is willing. Just right-click the extension then go to 'Inspect popup' then go to the 'Resources' tab and enable resource tracking if it isn't already enabled. I suspect the error is somewhere in 'popup.html', 'popup.css' or 'popup.js' though I might be wrong. Post where I got it wrong if you can find it.
  5. Ranigad

    Ranigad

    Joined:
    Jun 9, 2010
    Messages:
    123
    Um, I don't have this application, however my address bar allows me to search some websites by typing their name and hitting tab. I can already search google (google + tab), wikipedia (wikipedia + tab), smogon (smogon + tab), etc. o_O Anyone else have this?
  6. doominic77

    doominic77

    Joined:
    Jul 3, 2010
    Messages:
    394
    this is really cool, it'd be awesome if you could make one for firefox
  7. Professor Lamb

    Professor Lamb

    Joined:
    Oct 4, 2010
    Messages:
    187
    Thanks for this. It is very helpful. I found no big errors with it (so far).
  8. Premonition

    Premonition

    Joined:
    Oct 17, 2010
    Messages:
    9
    There is already a Smogon search bar for Firefox 2+. Look here. I haven't tried it and I'm pretty sure it doesn't have a mcs (auto-correct) but hopefully it's what you're looking for.

    The problem with searching Smogon in the address bar and hitting tab is that it does not auto-correct for you. Try typing 'Pekachu' in the address bar. It doesn't redirect you to 'Pikachu'.
  9. Professor Lamb

    Professor Lamb

    Joined:
    Oct 4, 2010
    Messages:
    187
    Alright, well I found my first error. I searched for "Mew" and it redirected me to "Howl". Not sure how those two things are related but that's what it did.
  10. Premonition

    Premonition

    Joined:
    Oct 17, 2010
    Messages:
    9
    Ok, I'm fixing it. If you experience more problems like that, you can type things like 'Pokemon Mew' instead of just 'Mew' and it will redirect you to the right page. Just thought I'd tell you that.

    EDIT: I just got Windows 7 on my mac through bootcamp and I have noted some changes on the extension. The padding is not the same as on the mac so I will fix the extension to be more Windows-friendly. However, it seems there is no aforementioned size error as there is on the mac.
  11. Premonition

    Premonition

    Joined:
    Oct 17, 2010
    Messages:
    9
    I'm so very sorry, Google won't let me update the extension :'(
    I guess this means this is the end of Smogon Search, even though 5th Generation stuff is coming out on Smogon. Thanks everyone for using Smogon Search on Google Chrome while it lasted!
  12. Professor Lamb

    Professor Lamb

    Joined:
    Oct 4, 2010
    Messages:
    187
    Aww...oh well, it was useful while it lasted.

    Great job on it though.
  13. locopoke

    locopoke indulges in unsavory behavior
    is a Forum Moderator Alumnusis a Smogon Media Contributor Alumnusis a Battle Server Moderator Alumnus

    Joined:
    Aug 18, 2007
    Messages:
    2,805
    this shit is fucking boss
  14. VKCA

    VKCA (Virtual Circus Kareoky Act)

    Joined:
    Jan 8, 2009
    Messages:
    3,664
    Indeed.
    What do you mean by "I guess this is the end of smogon search"? It still works for me, do you just mean you aren't/can't going to update it?
  15. Fatecrashers

    Fatecrashers acta est fabula
    is a Site Staff Alumnusis an Artist Alumnusis a Super Moderator Alumnusis a Contributor Alumnusis a Smogon Media Contributor Alumnusis a Battle Server Moderator Alumnus

    Joined:
    Sep 24, 2007
    Messages:
    4,997
    I'm also curious as to what the problem is here.
    Are you saying that any new analysis pages that get uploaded won't appear in the search?
    Why would Google not let you update this extension?
    This is a really useful thing you have here, it'd be a shame to see it go to waste.
  16. PK Gaming

    PK Gaming Pursuing My True Self
    is a Site Staff Alumnusis a Forum Moderator Alumnusis a Community Contributor Alumnusis a Tiering Contributor Alumnusis a Contributor Alumnusis a Past SPL Winner

    Joined:
    Aug 18, 2009
    Messages:
    5,153
    Wow this is absolutely brilliant.

    Great job!
  17. Premonition

    Premonition

    Joined:
    Oct 17, 2010
    Messages:
    9
    That's right. I can't seem to be able to update the extension. Google simply won't let me because of some 'server reject' error. So I'm not sure whether I will be able to add the new 5th Generation Pokemon, items, etc when it all comes out on Smogon. I'll keep trying though.

Users Viewing Thread (Users: 0, Guests: 0)