Why is this subheader not rendering the mongo object is on the client


#1

The publish statement works Subheader.findOne(); returns the appropriate subheader. But I have been up to long and can’t figure out what I am doing wrong. the end result is just empty <p></p>. please help thanks.

<template name="subheader"> <p>{{texth}}</p> </template>

Router.route('/', { name: 'home', controller: MissionstatementpostController, waitOn:function () { return Meteor.subscribe('subheader', 'home'); } });


#2

Without seeing more code is hard to debug. I would double check your subscription, I’m not sure what the second (‘home’) argument is doing. Normally you would publish all or a specific set of documents from your collection, and subscribe to it. So if your collection was called subheader it would look like this return Meteor.subscribe('subheader') http://docs.meteor.com/#/full/meteor_subscribe


#3

the second home gets passed to the server for selecting documents that part works the correct mongodb doc is on the client it just is not rendering.


#4

please take a look at this i added all the code thanks