Poll

Which web browser do you use?

Chrome
Firefox
Internet Explorer

Author Topic: Forum Extension - Show Someone's Last Topics |New Poll: Your web browser?|  (Read 9898 times)

I think an smf mod would have to be downloaded and applied to the website, but ya it's pretty much already a part of smf that 's disabled

Tampermonkey

I've run into a bit of a problem. it's difficult to get Node.js to work with chrome extensions, but still trying to find a way to do it.

edit: may have just found a solution with something called Browserify that brings node modules to the browser- https://www.youtube.com/watch?v=gkb_x9ZN0Vo
« Last Edit: September 27, 2014, 01:14:45 PM by Farad »

I've run into a bit of a problem. it's difficult to get Node.js to work with chrome extensions, but still trying to find a way to do it.
probably because node.js needs a server
what do you need it for?

probably because node.js needs a server
what do you need it for?
my webpage scraper uses 2 node modules called 'request' and 'cheerio'

After you create the Chrome Extension, will you try to make it as a Firefox Add-On?

After you create the Chrome Extension, will you try to make it as a Firefox Add-On?
probably not, sorry

Good news - I got the webpage scraper to loop through however many 'show last posts' pages a forum profile has and show titles with links in console. I used it on myself!:



Bad news - I still can't get the scraper to work with chrome extensions, which means the scraping function has to be executed in a local command prompt rather than by clicking a convenient link near the 'Show last posts of this person' link. I'll keep trying though

EDIT: oh wow forgot to say the most important part - the scraper works waaay faster than I thought it did. It can scrape all of my posts (47 pages) in 5 seconds
« Last Edit: September 27, 2014, 06:01:40 PM by Farad »

Unfortunately there's no easy way for me to make this work in a browser due to certain limitations (node modules, 'request' and 'cheerio,' don't have browserify support so they can't run in the context of webpages) - meaning that the 'show last topics' link I made can't execute the function that finds a person's last topics,
BUT,
I'm still going to release it as a simple javascript that you can run from your local command prompt. I'll include instructions on how to use it once it's finished

EDIT: I'm currently looking for ways to execute local javascript (scraping.js) from webpage javascript so it could work with the chrome extension. I kinda need variables from the webpage (like who's profile to show the last topics for and how many pages of 'show last posts' there are), so that is another problem that would only be solved by running with the chrome extension
« Last Edit: September 28, 2014, 01:15:28 PM by Farad »

I'll try make it as convinient as i can and show it off. If you like it, you can include it

I'll try make it as convinient as i can and show it off. If you like it, you can include it
I'm confused. you're doing what? define 'it' for me please lol. are you saying that after I release it, you'll improve it to make it look better?

Sorry. What i meant was, that i'll try to make it as convenient to use as i can. If it turns out good, i'll release it. Wasn't meant to be anything significant.

I decided to trash the node.js scraper because it simply doesn't work in the chrome extension. I found a new method that I just tested and so far it has been much simpler. It's called Cross-Origin XMLHttpRequests

A Chrome Extension?

So, I can't use it on Firefox? My default browser?

A Chrome Extension?
So, I can't use it on Firefox? My default browser?
guess you better start using chrome, huh

A Chrome Extension?

So, I can't use it on Firefox? My default browser?
I'll try to find a browser converter for the extension when it's completed but I can't promise it'll work