I am looking into the simplest way to integrate Wikipedia into a node.js app.
The requirements are to be able to search for entries and find entities in each entry.
Any known existing libs/methods for that?
Thanks
There's a newly available open source parser for wiki text (http://sweble.org/) that might be useful to you if you roll your own solution. Of course that would require you downloading the wikipedia data dump, parsing, and storing entities in a db.
You could also look at dbpedia (http://dbpedia.org/About), though that would require integrating the rdf stack into your app (either running a local rdf repository or communicating with the often flaky online version via sparql).
One easy approach is to use a search engine api and restrict to site:wikipedia.org - e.g:
http://www.google.com/search?q=node.js+site%3Awikipedia.org
I've found that can work really well.
Spider for scraping using jquery is fantastic:
https://github.com/mikeal/spider
Mikeal is the man
Presumably you'd be using this for a side (personal) project though. Not sure how kosher it is to run wild on wikipedia with a scraper.
Related
I am prototyping a Shopware App right now, where I want to extend the search with our search API. We already have a working plugin in the store for that.
I found those two references for hooks:
https://developer.shopware.com/docs/resources/references/app-reference/webhook-events-reference
https://developer.shopware.com/docs/resources/references/app-reference/script-reference/script-hooks-reference
Seems like there is no webhook for the search at all and just a script-hook for a finished search. In the plugin, we could just extend the ProductSearchRoute and be completely flexible.
Are search extension not planned right now?
Cheers,
Tobias
I assume you want to alter the criteria for fetching the products. As of today this is not yet possible with non-self-hosted apps. You could use the app scripts to enrich or replace the contents of an already loaded page as you already mentioned. Obviously that comes with some drawbacks regarding performance. The capabilities of apps are being enhanced continuously though so there's chance search manipulation might become possible rather soon.
I have a requirement where i have a config file which has a bunch of properties. The user has to download the property file from the server using a browser. Some of these properties have to be changed based on the user's input and then the file has to be downloaded. This basically fits the perfect description of having templates and then at run time generating a file by replacing the properties provided by the user. How can i achieve this using node js. Any pointer will be deeply appreciated. Please pardon my limited knowledge of MEAN stack.
Template engines are a common thing and it's quite easy to use one with express.
I suggest you start with the docs on using template engines with express. They also have a wiki entry with a list of available engines.
Most template engines are meant to generate HTML, if you want to output something else (even plaintext) it can be a bit tricky sometimes.
Otherwise the choice mainly depends on what your familiar with. I can recommend Mozilla Nunjucks.
My freind and I want to setup a collaborative project where we both work on a HTML file (and do PHP) at the same time (bit like Google Docs share feature). I want to be able to work with him to teach him certain things in PHP and HTML while I also code at the same time. Any suggestions? I have a VPS I thought we could use for it so nothings really going to get in our way. Maybe something like GIT or something?
Sounds like what you need is a real-time collaborative text editor. Here's an extensive list from wikipedia.
I use Google Docs personally but Microsoft has added this type of functionality into Office and there are a slew of desktop and online tools on that link. I had looked into Etherpad before but i don't remember enough to suggest one or the other. All of the links are on the wikipedia article so I won't repeat here.
Background: My idea is to create a primarily content-heavy website (think news articles or blog posts) written entirely in nodejs. Since creating content on Google Drive (Google Docs) in particular is very simple, what I would like to do is have Nodejs retrieve the website's content from Google Docs.
Challenge: As far as I can tell, the correct way to do this according to Google is to create a Service Account so that the application can access the files stored on Google Drive without requiring user-intervention in the form of a confirmation. Google provides three libraries--java, python, and php--for server-to-server requests. Does anyone know of anything similar already written by the Node community? I am aware of node-oauth but I've searched through it's source and haven't found anything referencing private keys, which are required for server-to-server interaction, which I'm taking to mean it's not supported. Writing one is also an option, but I'd like to avoid that if at all possible. Looking at the Google-written Java Oauth2 client library makes it pretty clear that it's not an easy task.
Thanks in advance!
This is one library I've found that looks pretty thorough and complete for creating JSON Web Tokens: JWCrypto
I know this thread is old, but in the event others arrive here looking for an answer:
Google is working on an official module to access all of their API's. Its alpha so be careful but it looks very nice- github repository
Does anyone know where Databasic originates from, and any resources that could help me learn this language?
I'm assuming it's Basic but looking at some sample code there are database-specific features.
I recommend looking at the official documentation: http://download.northgate-is.com/reality/V14%20Manuals/help.htm
The company's web page also might have some useful information: http://www.northgate-reality.com/products.php
There is also DataBASIC that was developed by Metso Automation. It is a Basic variant that includes Database access commands, and has been used in Metso and Telvent products. I've been unable to find any Web resources on it, and depend on the documentation that comes with my Telvent product.