Grow your CSS skills. Land your dream job.

WordPress .php won’t process direct images?

  • # July 2, 2009 at 8:21 pm

    Hi, just curious if this was something simple and I’m just being dumb, but I can’t seem to get any of the .php files that WP uses to construct the layout to recognize images.

    For instance, if I include an <img> into the header.php, index.php, or footer.php, it just leaves that area blank.

    It works just fine if I run it through a <div>.

    Does WP only use <div>’s? Or am I just failing to see something right in front of me?

    # July 3, 2009 at 12:45 am

    Ok – I found my answer:

    viewtopic.php?f=4&t=1000

    I wasn’t using the correct file paths. But I’ve got a follow up problem that I’m not quite sure about looking at the code.

    What I’m trying to do is add a the SimpleModal on a custom page in wordpress.

    I’ve attempted to call in the jscript to allow the SimpleModal to work in the header.php file that would then get included on the custom page indexpage.php.

    So I’ve referenced them like this:

    Code:


    Problem is, on the custom page, I can see the image and the link is there, but when you click on it, the function isn’t executing. It’s just sitting there. Am I calling in the .js files incorrectly? Or do I need to do anything else for WP to recognize what I’m trying to do?

    the URL is: http://www.citrusbunny.com

    Any feedback would be appreciated.

    # July 3, 2009 at 2:30 am

    You should be linking them like this: (it was the first example I could find, it doesn’t quuuiiiite relate, but you should get the idea)

    # July 3, 2009 at 4:04 am

    Cool thanks Doc.

    What I ended up doing to get the SimpleModal to work was installing the Plugin for it, then just referencing that on the <a> tag on my custom file.

    But I’m really worried about instances where I need to install some custom functions. If I wanted to put in a specific gallery, or other jscript function, I still don’t have any idea how to get it to work without installing the plugin (unless that IS the way to get it to work, but my understanding was you could pull in just about any kind of functionality into WP).

Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.

*May or may not contain any actual "CSS" or "Tricks".