Hey guys I am just diving into node.js and I set up an express server have 
the code below but I basically need to know how to get the stuff in my 
app.js into the front end.

I just want to pull posts with a certain hashtag and display them on my app.

Eventually I want to have it pull in realtime and then also post on a map 
in relation to where the post was made. But for now I just want to start at 
the bottom and learn along the way.

Sorry if this isn't the right way to use this forum.

Here's the code: 


/**
 * Module dependencies.
 */

var express = require('express');
var routes = require('./routes');
var user = require('./routes/user');
var http = require('http');
var path = require('path');

var app = express();

// all environments
app.set('port', process.env.PORT || 3000);
app.set('views', path.join(__dirname, 'views'));
app.set('view engine', 'jade');
app.use(express.favicon());
app.use(express.logger('dev'));
app.use(express.json());
app.use(express.urlencoded());
app.use(express.methodOverride());
app.use(app.router);
app.use(express.static(path.join(__dirname, 'public')));

// development only
if ('development' == app.get('env')) {
  app.use(express.errorHandler());
}


app.get('/users', user.list);

http.createServer(app).listen(app.get('port'), function(){
  console.log('Express server listening on port ' + app.get('port'));
});

Instagram = require('instagram-node-lib');

Instagram.set('client_id', '70393263f72f44cc9a3ef9786a4d389f');
Instagram.set('client_secret', 'fa2725e2a08a4158bad297f35b5c6bec');
Instagram.set('callback_url', 'http://morning-thicket-8336.herokuapp.com/');

Instagram.tags.info({
  name: 'blue',
  complete: function(data){
    console.log(data);
  }
});

Instagram.subscriptions.subscribe({
  object: 'tag',
  object_id: 'breakfast',
  aspect: 'media',
  callback_url: 'http://morning-thicket-8336.herokuapp.com/',
  type: 'subscription',
  id: '#'
});

app.get('/', function(req, res){
  res.render('index', {
    title: 'Home'
  });
});


-- 
-- 
Job Board: http://jobs.nodejs.org/
Posting guidelines: 
https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines
You received this message because you are subscribed to the Google
Groups "nodejs" group.
To post to this group, send email to nodejs@googlegroups.com
To unsubscribe from this group, send email to
nodejs+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/nodejs?hl=en?hl=en

--- 
You received this message because you are subscribed to the Google Groups 
"nodejs" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to nodejs+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to