0

I have this json array

[ 
{ Company: 
{ id: "19", features_id: null, features: "a:6:{i:1;s:1:"1";i:2;s:1:"2";i:3;s:1:"3";i:4;s:1:"0";i:5;s:1:"0";i:6;s:1:"6";}" }, User: [ ] }, -{ Company: 
{ id: "20", features_id: null, features: "a:6:{i:1;s:1:"1";i:2;s:1:"2";i:3;s:1:"3";i:4;s:1:"4";i:5;s:1:"5";i:6;s:1:"6";}" }, User: 
[ 
{ id: "1", group_id: "1", type: null } ] }]

for somereason I cant get data into my div. Anyhelp will be appreciated. here is the jsfidler

http://jsfiddle.net/4Y9L3/

2
  • 1
    The JSFiddle doesn't help us, sadly, as the URL is relative so we'll never get a response. However, make sure you look up the jQuery AJAX parameters- Include datatype:'json' to ensure it's being parsed as JSON. Commented May 2, 2012 at 4:12
  • hi Dan, thanks. data is like this [{"Company":{"id":"19","name":"xyz","f_id":null,"features":"a:6:{i:1;s:1:\"1\";i:2;s:1:\"2\";i:3;s:1:\"3\";i:4;s:1:\"0\";i:5;s:1:\"0\";i:6;s:1:\"6\";}"},"User":[]}] Commented May 2, 2012 at 4:15

2 Answers 2

4

That JSON is not valid. Also, your template is not going to output anything visible unless you put some bind tags in the repeater like {{Company.Company.id}} for example.

Sign up to request clarification or add additional context in comments.

Comments

1

You are using $.ajax(), so Angular doesn't know about it.

Use $http like this http://jsfiddle.net/4Y9L3/5/.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.