Sunday, November 13, 2022
HomeWordPress Developmenttags - Can I create my very own question in wordpress with...

tags – Can I create my very own question in wordpress with conventional strategies?


I’m new to growing themes with wordpress, so this is my query. Can I create my very own question in wordpress with conventional strategies?

I do know we use the WP question strategies, however what’s the most effective manner, and may I exploit my very own SQL instructions to generate a question for all tags with printed submit? for instance.

I’m utilizing get_the_tags() with wordpress, however it is just offering the tags associated to the submit. I need all tags with printed submit to show. And are available to consider it now, I believe it is not even displaying the tags, simply the submit class, so I should be doing one thing improper.

Under is the code within the features.php file

 operate get_all_tags(){
    $posttags = get_the_tags('');
    if ($posttags) {
        foreach($posttags as $tag) {
            echo '<li><a href="#">'.$tag->title.'</a></li>'; 
        }
    }
}

Within the single.php file, i’m calling on this operate.

<?php $tagsAll = get_all_tags(); echo $tagsAll; ?>

I picked up a few of this from on-line searches, however I’m making an attempt to switch for all tags with little success. Thanks

RELATED ARTICLES

LEAVE A REPLY

Please enter your comment!
Please enter your name here

- Advertisment -
Google search engine

Most Popular

Recent Comments