• This may be a dumb php newbie question, but how can I get a path to the content. I don’t need the actual content, just the path for a javascript call.

    Any help would be greatly appreciated

Viewing 2 replies - 1 through 2 (of 2 total)
  • There isn’t “a path”. The post content is pulled from the database.

    Thread Starter DPoncy

    (@dponcy)

    Is there a way to fake a path. I have tried to put a wordpress loop in a file called “chapter.php” and then used it like this:


    var bookData = {
    getComponents: function () {
    return [
    "<?php bloginfo('template_url'); ?>/chapter.php"
    ];
    },
    getContents: function () {
    return [
    {
    title: "<?php the_title(); ?>",
    src: "<?php bloginfo('template_url'); ?>/chapter.php"
    }
    ]
    }

    <p>But the php functions aren’t recognized.</p>
    <p>This code wasn’t designed for dynamic data and I am trying to adapt it.`

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘content data path’ is closed to new replies.