Firstly, do you have DEBUG set to TRUE in wp-config? Not loading further than the header may well mean there’s an error that isn’t displaying. Set it to True to see the error.
Secondly, you are using for in_category on an archive page – which I believe would only apply to the first post on the page. This may not make a difference in your case though.
Third, I would not use the default archive for this at all. I would create a template specifically for this category: category-nytt.php (see template hierarchy). This will both let you dispose of all the in_category
/post_is_in_descendant_category
gubbins entirely, and leave your default archive.php (once restored) to work in the standard way for standard posts.
EDIT:
See the answer here for having subcategories use their parent’s template.
Related Posts:
- Change number of posts to show on Archive page (custom post type)
- Image loading function not working on archive.php template
- Ajax call always returns 0
- plugins_url vs plugin_dir_url
- Get list of years when posts have been published
- Where and how to put inline js in pages
- Is it possible to remove the “standard” post format?
- Do WordPress’ cron’s clean up expired transients?
- How to add first name & last name to default registration form?
- Masking logout URL
- Hourly Routine Not Firing ( wp_schedule_event() )
- Warning/Notice about functions.php
- Is checking whether the blog is installed necessary?
- echo or print_r in an admin function
- Overriding methods in a child theme
- WP disobeys disabling of the posts revision feature
- How do I deactivate a plugin for some roles
- How to display more audio file ID3 tags in WordPress
- Searching for content post
- Running CRON on Server with WP Function
- Using separate .php file for functions – how to run on site?
- wp_trash_post function to only apply to posts, not pages!
- Adding widget to dashboard with wp_dashboard_setup not working
- Add Featured image column into wordpress admin on pages AND posts
- How can I change the do_action function in footer (copyright area)
- Access Plugin data from Functions.php
- Register and load scripts
- Having a Function Inside of the Loop
- how to call a function only in specific pages and exclude it from other pages
- Which action does wp_update_user triggers?
- Use register_setting() in a loop
- Dynamic dropdown from database table
- About cron delete user with meta_key
- Add dynamic links in WordPress custom theme
- WordPress website Rs changed to currency symbol
- Unable to login using username
- How to change the order of Jquery in the footer of my theme?
- Attempt to change jQuery version caused White Screen of Death
- media resize/crop possibilities?
- adding custom script to functions file
- Difference b/w Simple function call & do_action call
- What’s wrong with my use of plugin_url()?
- edit formatting.php in a theme so it wont get overwritten
- Hook into a function without a hook?
- add_action template_redirect not working for home page
- Way to store featured image width and height in two separate variables?
- Insert template-part inside the content
- Filter yoast canonical add_action priority [closed]
- Should I store functions in separate folder?
- How can I modify the element on all pages?
- Add unique id to Preview URL
- the_password_form functions not working together
- Numbering lines of code with the tag?
- Latest Foursquare Checkin function
- PHP 7.1 | Warning: A non-numeric value encountered in
- Way to redirect all Product Sub Category to its Main category Page?
- Fatal error: Call to undefined function is_even()
- Is this an acceptable practice for WordPress theme development?
- How to use parent theme functions in child theme functions.php file?
- search form leads to 404
- How to change a specific admin label
- Custom image sizes showing in Classic Editor only when upladed directly to post
- How to hide WooCommerce product title and short description to non logged in users?
- How to loop while adding data to database?
- How to add extra value to permalink
- Bulk updating a group of WordPress Pages every 10 minutes
- localize_script but data changes dependent on product ID
- remove_filter function to unhook twentysixteen parent theme function
- Can we have conditional CSS styling?
- Change function without filter hook
- How to add javascript code into Divi child theme?
- Using AJAX on frontend: Synchronous XMLHttpRequest deprecation except for admin role
- Override plugin function to show invoices even if not logged in
- How To Display Author Popup on Entry Meta (Genesis Framework)?
- how can I change the read more link destinations and direct all to the same page?
- ACF Filter return value
- How to build two WordPress site using two different themes with same database (No ! I am not taking about multisite network)?
- How can I stop the hook from breaking the login/logout function?
- Replace image attributes for lazyload plugin on image elements with specific class
- Custom shortcode with do_shortcode and substr
- Keep js after reload the page
- Add array of category IDs to global variable?
- Need some Tweak my nextpage Function
- us states dropdown function and echo in theme template files
- Nothing happends on post_update
- Function the_content
- Edit TinyMCE Button Functionality
- Expanding a function to call a plugin or show a link
- Trying to the deduce shortcode from a function
- WordPress Translate Explaination
- functions.php / replacing div’s with new ones?
- How accomplish modification the_content if home/start page?
- Using Output from one Function and calling it into another
- How to add a class and title attribute to the link generated by next/previous post
- “Headers already sent” while trying to add a CSS file to my login page?
- Remove theme, change theme button and WP version on “Right Now” admin dashboard?
- Notice: Use of undefined constant REQUEST_URI – assumed ‘REQUEST_URI’ in ….functions.php on line 73
- Load script only on selected Pages
- Using input_attrs() Multiple Times Within One Customizer Control
- Convert Image to Webp on upload without plugin