Welcome guest, is this your first visit? Create Account now to join.
Results 1 to 4 of 4

This is a discussion on Stumble-it! within the Chrome Plugins section, part of the Google Chrome category: This is my first extension, Stumble-it! It allows the user to submit the current page to StumbleUpon. Extension: http://download115.mediafire.com/zum...mble-it%21.crx Source ...


  1. #1
    dragonic2020 is offline Junior Member
    Join Date
    May 2009
    Posts
    24

    Default Stumble-it!

    This is my first extension, Stumble-it!
    It allows the user to submit the current page to StumbleUpon.

    Extension:
    http://download115.mediafire.com/zum...mble-it%21.crx
    Source code:
    http://www.mediafire.com/file/2z2yum...tumble-it!.rar

    Now I know its a simple extension to make and all of you more experienced programmers are going to point and laugh and call me a newb. But it's a start, no?

    I did however want to make it a bit more complex as described in the following pseudo-code.
    Code:
    if (not logged-in to StumbleUpon)
      go to StumbleUpon sign-in page
    else
      submit page to StumbleUpon
    However, I'm at a loss at how to do this.


    Enjoy!
    Last edited by dragonic2020; 06-24-2009 at 09:38 PM. Reason: Added details

  2. #2
    Kyrax is offline Senior Member
    Join Date
    Apr 2009
    Location
    Qc, Canada
    Posts
    495

    Default

    Nobody gets pointed at and laughed at here.

    Welcome aboard

    As for your " not logged in " requirement, you could check if you can access login cookies from the browser ( not sure if extensions have access to site specific cookies ),

    Also, there might be a Stumble Upon API that allows you to verify that, not sure though.

  3. #3
    rock_galore is offline Junior Member
    Join Date
    May 2009
    Posts
    23

    Default

    Quote Originally Posted by Kyrax View Post
    Nobody gets pointed at and laughed at here.
    Right.

    Quote Originally Posted by Kyrax View Post
    As for your " not logged in " requirement, you could check if you can access login cookies from the browser ( not sure if extensions have access to site specific cookies ),
    I don`t think so. And i hope you couldn`t because it would be a major security risk, but i`ll give it a try. ;-)

    Quote Originally Posted by Kyrax View Post
    Also, there might be a Stumble Upon API that allows you to verify that, not sure though.
    What about checking the http response-code in an XHR? If your not logged in it should give you a 3xxx code.

    If you want an advice i would definitely port this to a page action, cause it makes more sense than an extension. I don`t use stumbleupon, so i won`t use either of them, but a page action is the better way for things like this.
    You can take a look at page actions here:
    http://dev.chromium.org/developers/d...ge-actions-api

    rock_galore

  4. #4
    Waha's Avatar
    Waha is offline Senior Member
    Join Date
    Apr 2009
    Location
    Oregon
    Posts
    788

    Default

    Quote Originally Posted by Kyrax View Post
    Nobody gets pointed at and laughed at here.

    Welcome aboard

    As for your " not logged in " requirement, you could check if you can access login cookies from the browser ( not sure if extensions have access to site specific cookies ),

    Also, there might be a Stumble Upon API that allows you to verify that, not sure though.
    You have access to non-http only cookies or whatever (I forget if it's "non-" or not, cause I don't really know what it means), but only from a content script, and only while the user is on that site.
    Just use contentWindow.document.cookie
    ~ Projects ~
    Specialized: Carapass Auction Watcher, Kongregate Chat
    Libraries: bliplib
    Tools: manifest syntax highlighting & snippits
    ~ Happy to make extensions for pay too ;D ~
    Portfolio: Search and Share

Similar Threads

  1. Chrome Stumble - Uninstall Help
    By TRAVLNLGT in forum Chrome Plugins
    Replies: 1
    Last Post: 03-01-2009, 06:57 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •