Hello,

I am having a problem creating a custom them for a drupal site. In the html.tpl.php file i have several hard coded images using the $directory variable in the href to point them towards the correct location and this works fine for the front page and a page listing a particular taxonomy term, but when i click through to the node on the taxonomy page they are all lost and replaced by the alt text.

If i code the absolute url starting with http://localhost then it will work but this is no good in the long run.
Also something that i discovered with this is that if the http:// is left of it will not work.

Any ideas?

Here are links to the two different pages, first being the display of all the nodes tagged with a term, the second after you click on an article in the terms.

You can also see $directory printed out and see it references the same location

http://67.23.79.211/Taxonomy%20page.png

http://67.23.79.211/node%20page.png

Comments

Stuart Miller’s picture

Okay, looks like if i start the href of with /drupal/.... "drupal" being the name of the folder my site is in it will work.

so just need to add the return of base_path() to $directory and all should work unless i am doing things in a bad unnecessary way?