• Sam

    (@forbiddenchunk)


    I am trying to run pull through an XML feed that shows the number of images relating to a property

    console.log(type);
    if (type == "buy"){
        var images = '. echo $images->count(); .';
    } else{
        var images = 'No Images';
    }

    However I cannot get it to output right, can anyone help please?

    Hope I’ve explained it right

    I am expecting a number so if there are 5 images it will say 5 and I am currently getting . echo $images->count(); . which is just text, like it’s unable to read it as PHP, when I try other ways I get undefined.

The topic ‘Count images from XML’ is closed to new replies.