Opened 13 years ago
Closed 13 years ago
#19267 closed feature request (duplicate)
Add a theme_url() function.
Reported by: | filipekiss | Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | normal | Version: | |
Component: | Themes | Keywords: | |
Focuses: | Cc: |
Description
Wordpress already has a function for returning the plugin URL based on the file you are calling it http://codex.wordpress.org/Function_Reference/plugins_url, so I was thinking we could really use some theme_url() like function. It would be simpler than calling the option 'template_url' every time we wanted to include a file.
So we would just call <img src="<?php theme_url('images/my-image.jpg');?>" /> instead of <img src="<?php bloginfo('template_url');?>/images/my-image.jpg" />;
This is my first ticket, so I'm not sure if I chose the right component
Change History (4)
#2
in reply to:
↑ 1
@
13 years ago
Replying to linuxologos:
It's not actually the same function. He's asking just for a function to return the themes folder url. I want one to retrieve the current theme url and append the wanted file/image/whatever path to it. I stumbled upon that request before posting; :)
#19200