If your Loop is constructed correctly $post
will be set for each post in the loop in turn. You could also consider using get_the_ID
.
get_post_meta($post->ID, "user_submit_url", true);
by itself won’t do much. You will have to format and echo
the information but that should retrieve your post meta data.
For example, to generate a link (assuming your meta value is an URL and that you’ve save a string and not an array):
$meta = get_post_meta($post->ID,'user_submit_url',true);
echo '<a class="meta" href="'.$meta.'" target="_blank">'.$meta.'</a>';
If your theme has a category.php
and you want this only on category archives put that code in category.php
. archive.php
is used by all archives that do not have a specialized template– tag and author archives, for example. The template hierarchy is explained in the Codex.
Related Posts:
- Sort category page with custom field
- How to get category and archive title?
- Get rid of WordPress category, tag and author archives?
- get_categories for custom post type with a specific custom taxonomy attached
- How To Modify The Loop in archives.php To Have 11 Posts Per Page and CSS Styling
- Order get_terms() By Custom Field
- Decreasing the Memory Consumption of a WordPress Site?
- What’s the URL for a category archive?
- get_field not displaying my custom field value
- Sort posts by tags in category pages
- Add extra fields to Add New Category page
- Display posts links from a category group by year
- Display list of Sub-Categories and the posts they contain, within one main Category
- Need help adding custom field to category
- Custom query with category exclusion and post-meta “whitelist”
- Create a full width responsive header image per page
- How to create tabled index of posts in a certain category
- Root level category, tag, author and archive pages to work
- Category Specific Archive
- How to have Multiple Archives Widgets, one archive widget per category (in a different page)?
- Are Custom Taxonomy Templates Possible?
- “Sticky” posts for each category (archive.php)
- I want exclude the particular category in sidebar
- Remove Archive Headline and Archive Intro Text fields on category and tag archive pages in WordPress Admin with Genesis framework
- Display only posts from referred category on date archive page
- Using widget logic I want to show only a widget on the archive page if there are no posts
- Creating archive pages for children categories
- WordPress categories being called “archives” in google links. How to remove?
- conditional for sub category on archive page
- weekly archive for custom category
- How to remove category titles?
- Show archives by year from just one category
- How to call custom category field data in theme?
- Category index featured image
- Archive.php filtered by pre-determined category
- query in category.php repeats itself
- How do I call posts with a certain tag?
- need to add custom field in more products
- Category being displayed without base parmalink
- Retrieving category’s color with get_term_meta
- How can I define a custom archive for childs of a specific category?
- Get parrent category name
- add_rewrite_endpoint returns 404 on archives
- Multiple category archive page
- Custom archive.php: retrieve right post categories?
- How to “group” (categorize) the Pages together?
- Customize category page for different custom taxonomies
- How to Remove a Title from All Category and Tags Page?
- Do not show sub categories in the loop on archive-product.php
- why get_the_post_thumbnail( the_ID()) echos extra post id
- “Virtual category page” based on a custom field filter
- display category list year wise in wordpress
- How to display post in custom file not in archive file?
- ACF no print data [closed]
- WordPress showing wrong category name
- Media (images, videos, etc.) not showing on Category page
- WordPress monthly archive category specific
- Archive filtering
- Show Secondary Sidebar on Category pages (archive)
- Rebuilding a Site: How to Show Several Category Posts in Woo Framework Theme?
- Add multiple orderby with pre get posts
- Update custom category fields front-end
- What is the best way to add an advanced / intermediate / beginner tag to a post
- How can i add service category here? [duplicate]
- List of post categories only associated to another custom taxonomy
- Show the parent taxonomy by creating shortcode in woocommerce?
- Displaying data from custom fields on a specific category page
- How Can I Display the Category Description in a Theme with no Category.php or Archive.php?
- How to display custom fields as table in Woocommerce
- How to add excerpt and read more button to category archive page
- How to modify custom category field from front end?
- Display all posts from specific category
- Meta Box: display single image on an archive-template
- Make category archives page in menu non-clickable
- Custom Category Archive Pages
- custom browse by
- How to get get_categories()’s ‘hide_empty’ argument to work with global year var in the archive template?
- How to Manage and link certain custom taxonomy?
- get_the_terms_list output last child only
- How to get related category/categories in WordPress archive page
- Category archives
- How to loop through a custom field for each post, & display?
- Create monthly archive for parent category
- $args Orderby The number
- How to count the number of monthly archive?
- Transfering static site to wordpress and retaining category by month paginations
- Conditional statements based on custom meta value in category archives
- 2 loops in archive.php (one for each category)
- Logic for Nearby places with post and categories
- How to structure Multisite sites into categories?
- Category Archives: Show posts categorized in parent category only
- Custom Fields to Category edit page, then displaying them in a template correctly
- How do I add and display a custom image field to a category? [duplicate]
- Converting Categories (with ACF fields) to custom taxonomies
- All post of child category not in top category
- how to implement next/prev within category archive?
- How Do I Add HTML Support to the Additional Category Description Field?
- How to link ACF relationship field to the new Query block in Full Site Editing
- Sorting past events by month
- Add custom text in second paragraph of posts in specific category