How to select just an array from MongoDB using PHP?
For example, I have data like:
db.articles.insert({name: "topic1", images: ["img1", "img2", "img3"]})
So, how I can select and print it just names of images?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
We know so little of what you want. You are not even using valid PHP syntax.
The question is vague and doesn’t make much sense.
However this should help: