0

using this tutorial Pusher for realtime voting app, based on ionic. Once you click on Submit Vote, it woundn't show any thing.

ionic port : 8100, server port : 4000

Its might cause because of different ports?

Update Just realize its has been blocked by CORS policy.

code

res.header('Access-Control-Allow-Origin', '*');
  res.header(
    'Access-Control-Allow-Headers',
    'Origin, X-Requested-With, Content-Type, Accept'
  );

enter image description here

faisaljanjua
  • 886
  • 2
  • 13
  • 28
  • Please add some more details, like sharing some code or what you have tried so far etc. – HasilT Jan 09 '19 at 12:59
  • @HasilT, I am using the same as based on tutorial. but once I click on submit vote, it not sow any data, I am wondering what I missed. I have doubt of port, even try 'Repo' and run as per instruction, but its not working – faisaljanjua Jan 09 '19 at 13:04
  • check whether the data is being received at the client side. – HasilT Jan 09 '19 at 13:12
  • @HasilT, I missed the console error. check the update in my question – faisaljanjua Jan 09 '19 at 13:20

0 Answers0