Hello WordPressers. Quandry for you:
I’m looking to define a new function in functions.php so that I can call it everytime I need to call a specific path to a folder.
So essentially, instead of using ‘template_url’ and then adding text to the relevant folder, I would just call the function.
<?php bloginfo (‘template_url’); ?>/library/media/images/example/sample.jpg
Would become something like:
<?php example_folder_path (); ?>/sample.jpg
Know what I mean? Any ideas? Thanks in advance!
- The topic ‘Custom Path Function’ is closed to new replies.