Questions tagged [headers]

HTTP headers are what is sent to the browser before the page markup. They often include the page MIME type, charset, status code and encoding. Headers are often overridden to change the page MIME type or redirect the user.

173 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
4
votes
0answers
163 views

Additional Option on Custom Header admin

I would like to extend the Custom Header class to include an animation feature for the header graphics. Essentially, I'd like to add another possible value for the radio button for randomization. The ...
3
votes
0answers
2k views

x-wp-nonce is not allowed by Access-Control-Allow-Headers in preflight response

I would like my dev server on http://localhost:8080 to work with my wordpress install's rest api, of which the api base url is at http://localhost/wptest2/index.php/wp-json/ I am currently getting the ...
3
votes
0answers
42 views

HTTP Header on specific page is application instead of text

Problem: clicking on (WP site that I developed) webejeeping.com/vehicles/ causes the generated php file to be downloaded instead of being rendered in the browser. MIME Type returns as "application/...
2
votes
0answers
60 views

Header Button Chance Polylang Elementor

Currently, I am making a Bilingual website, and I made a button on the header as well, and I want to make the button bilingual as well, but I don't know how could I change its language because it is ...
2
votes
0answers
90 views

send_headers don't work on wordpress multisite

I have written a simple plugin to send some security http headers. I've tested it on various wordpress installations but on a wordpress multisite network it seems that the headers are not sended. The ...
2
votes
0answers
1k views

Change logo based on incoming domain

The agency I work for are trying to get a client's logo to change based upon the incoming URL. Now, we have 4 different URLs, therefore 4 different logos. Currently, we are using an if/else ...
2
votes
1answer
385 views

Custom Post Type Events Archive Grouped By Month

I'm currently trying to get my events listing code to print out headers by Month. So basically this: October event event September event event etc... Right now it just keeps echoing January. I ...
1
vote
1answer
12 views

Remove transparancy in Sydney theme's headerimage

I'm bulimg a Wordpress site on the Sydney theme. On some pages the header image is kind of transparent. Not on the start page, but on all the other sites (example here: https://www.ferienhof-rauchhaus....
1
vote
0answers
331 views

Wordpress Twenty Seventeen header image size not responsive for mobile

I'm currently working on a website in wordpress. I've been struggling with this problem for a while. At the first the header image was too big even for computer. I managed to make it shorter using ...
1
vote
0answers
240 views

Google Tag Manger - no-script Code Not Found

I am having trouble getting the "GTM no-script code not found: either missing or not in " issue resolved. The GTM script is placed after the < head > tag. No issues. However, when using the ...
1
vote
0answers
1k views

“No Access-Control-Allow-Origin header is present” even though it is in the entry file

I'm seeing this in the Chrome browser console after doing a test fetch request: Access to fetch at 'http://localhost/wptest2/wp-json/pluginFolder/1.0/load?limit=10&offset=0' from origin '...
1
vote
0answers
31 views

How can i resolve 301 redirection Issue on my website?

When I scan my website on (https://www.woorank.com/en/www/fusionfirst.com) I already use canonical tag on my header section. Please check and help me :)
1
vote
0answers
50 views

How can I use cached images in an AJAX response?

WP_AJAX includes no-cache headers with its responses. I'm using Ajax to fetch part of a shopping cart, which includes little image thumbnails. On each Ajax request, these are replaced and we can see ...
1
vote
2answers
985 views

Modify wp-admin page header 'viewport' meta data

The 'wp-admin/admin-header.php' file outputs 'viewport' meta data. It seems the value of the viewport is hard coded into the file. (See: https://github.com/WordPress/WordPress/blob/master/wp-admin/...
1
vote
0answers
54 views

How to properly modify WP Vary or any existing headers?

I have a site that currently have a some part of the headers like: Vary: Accept-Encoding, Cookie I want to modify it to be: Vary: Accept-Language I tried the suggestions here using this code ...
1
vote
1answer
168 views

How I can overlap my menu in my header picture

How I can overlap my menu in my header picture. I want the menu can be seen on the header picture. This is the example like I want. Thank you. Example :
1
vote
1answer
54 views

header menu structure: cannot add additional menu items without alignment issues

When I add a new menu item to the header menu there is an alignment issue (please see the image). I'm not exactly sure which part of the header.php file to modify to address this problem. Update - ...
1
vote
0answers
40 views

How to remove main domain header title from after sub domain header title

I have installed WordPress on the main dame in public HTML and have installed all domains in the sub folder. But when we do Google, the title of the main domain comes in the title of all the domains. ...
1
vote
0answers
391 views

Remove all Wordpress HTTP headers (not in-source embeds)

When we do CURL on our domain, there are things added to the header: server: nginx date: Sun, 27 May 2018 01:05:34 GMT content-type: text/html; charset=UTF-8 vary: Accept-Encoding link: <https://...
1
vote
0answers
217 views

WordPress 502 | Header Upstream send too big

In the past one of our clients ran in to the problem of having a certain page(while being logged in) return a 502 error (upstream sent too big header while reading response header from upstream) after ...
1
vote
1answer
2k views

Menu custom link not working for external site

I've got this header menu in my site (made editing a theme), but i've noticed that the custom links pointing at local anchor section (like #section) correctly navigate in the same page to the desired ...
1
vote
2answers
970 views

How to duplicate a page template but make minor changes to the header?

I will apologize in advance, I am very new to this. I have been teaching myself php as a hobby, but now I need it for work! I don't work as a web designer, but to try and save some money, I need to ...
1
vote
0answers
1k views

Creating dynamic header and footer files

I have an external search engine and I need to create a page to add it to my site. The page will sit on an external server, on an external URL. They are copying in the HTML header and footer but ...
1
vote
0answers
58 views

Strange 403 header response

I am receiving a strange 403 header response on the blog part of one of my sites. The site is accessible in the browser and works perfectly but googlebot, Moz and other checkers return a redirect from ...
1
vote
0answers
112 views

Wordpress 4.1 header image problem

I want to use a moving .gif as my header image in wordpress 4.1. In previous versions I could skip the cropping step and leave the image as is, and it would let me pick a moving gif as my header image....
1
vote
0answers
1k views

“imagejpeg” function is not working in wordpress

$image = imagecreatefromjpeg('http://localhost/test/wp-content/uploads/2014/09/city_81.jpg'); // choose a color for the ellipse $ellipseColor = imagecolorallocate($image, 0, 0, 255); // draw the ...
1
vote
0answers
3k views

wp-comments-post.php file returns a blank page

When i post a reply to my blog, it's return a blank page to me. It seems that happens because of this code in wp-comments-post.php if ( 'POST' != $_SERVER['REQUEST_METHOD'] ) { header('Allow: ...
1
vote
0answers
463 views

404 or ugly page on IE, but Firefox, Chrome looks perfect

I have a variation of this issue. Was happening before and after new theme. I was getting 404 in IE, now sometimes get partial page that looks horrible. Contents can vary when I refresh. I have no ...
1
vote
0answers
1k views

How to give a download link to a .csv file from the custom plugin?

I have made a custom plugin, which exports MYSQL table contents into a .csv file which gets saved in to wp uploads directory. Now, I am trying to give a download link for downloading directly a .csv ...
1
vote
1answer
123 views

pull non-wp site into content area of wordpress -or- pull wp header into non wp site?

I am building a site which has a ecommerce nature that is not able to be tied directly into wordpress. What my goal is to have a constant header that is generated by my wordpress header on all pages ...
1
vote
1answer
122 views

How to change header dimensions in Wordpress?

How can I alter the requirements for the header dimensions so that I can take an uncropped image and fill the top section (centring the whole image) instead of having white space at the top? I would ...
1
vote
2answers
3k views

How to remove header image in Twenty Eleven theme?

Please give me details on how to remove the custom header image in the Twenty Eleven theme.
0
votes
0answers
11 views

Design Header meta on single posts wordpress

I want design my header_meta on single posts like this, please help me Thank you,
0
votes
0answers
21 views

We are facing this error in header unable to understand the issue

call_user_func_array() expects parameter 1 to be a valid callback, function 'add_search_form' not found or invalid function name in /home2/zeonu81d/public_html/wp-includes/class-wp-hook.php Please ...
0
votes
0answers
13 views

Header dropdown not working on my custom built page

Hello my header drop down is working perfectly fine if i use it on the pages that i built with wordpress but the ones that i built from root in html php and css and imported the header dropdown is not ...
0
votes
0answers
51 views

Cors headers Ajax

I'm just trying to run a basic jQuery ajax get request on instagram's api. $.ajax({ url:"https://www.instagram.com/page?__a=1", success:function(data){ console.log(data) ...
0
votes
3answers
31 views

How to insert custom text after H1 to all my blog posts?

I'm looking for a way to insert "THIS ARTICLE MAY CONTAIN COMPENSATED LINKS. PLEASE READ DISCLAIMER FOR MORE INFO." after the H1 in all my blog posts (not pages). Is there a way to do it ...
0
votes
0answers
18 views

Including PHP files in header.php

I have multiple header files, which are 90% the same code. It would make editing them easier if common code could be contained and called from a separate file. However, neither "include" nor ...
0
votes
1answer
51 views

How do I modify the <title> tag on my Category Archive page?

I'm using the 2016 template and it uses wp_head() to render the title tag. So for Category pages it displays Articles about: whatever How do I modify this? EDIT: I ended up doing this hack. Which I ...
0
votes
0answers
18 views

Wrong to use echo in wp_footer

I have a feeling that my code is causing the following error: PHP Warning: Cannot modify header information - headers already sent by (output started at /public_html/MY-WEBSITE/wp-content/plugins/...
0
votes
0answers
20 views

How do I stop the Cumulative Layout Shift of a full width canvas animation item in the header.php file? (Google Lighthouse audit)

How do I stop the of Cumulative Layout Shift of this full width canvas animation item in the header.php file? Where is the vertical shift coming from in the code below? <canvas id="myCanvas&...
0
votes
0answers
9 views

Problem with page header when i open a category in my blog

how i can remove the "Category:БЛОГ" header when i open a category of my website i tried with options in appearances but there is no option for removing that and it annoys me a lot
0
votes
0answers
10 views

Logo showing on some page but not on product categories pages

I am using a bought theme, and i have added my logo in my navigation/header in appearence and it works fine on all pages. But not on product categories. It is like it is using some kind of standard ...
0
votes
1answer
10 views

where can i add custom script to stop header video from autoplay

How can I add the custom script from this answer to my site to stop the custom video header from autoplaying? $( document ).ready( function() { $( document ).on( 'wp-custom-header-video-loaded', ...
0
votes
0answers
24 views

Cannot collapse a responsive menu in Wordpress

I am new to website development so I am testing with some responsive menu to see how it works in Wordpress. I have selected this menu and it works perfectly in the demo. Yet, when I apply the code to ...
0
votes
1answer
12 views

Remove a link in the header

I don't know why but in the header I've always have the page name and that thing below '-> page name'. How can I get rid of it? Thank you so much.
0
votes
0answers
18 views

How can I change the header on the pages?

I'm working with Manufacturer theme and I'm trying to have one header image for each page I have but I can't. Does anyone know how to do it? I've found that I can change the header here: but it will ...
0
votes
0answers
99 views

Remove server response header

I'm fairly new to WP/PHP and I'm trying to remove the server response header in functions.php. I've been trying use something like this but it doesn't work: add_filter('wp_headers', function($headers) ...
0
votes
0answers
20 views

How can I pass a variable from a template to header.php of a theme

As of version 5.5.0, WordPress introduced second argument (array $args) to get_header. I am calling get_header in my templates including index.php and I want to pass meta description value from ...
0
votes
0answers
20 views

Sticky Multiple Headers

Good day. I need help with the header of the site I'm recreating. I want these two headers to be sticky with the logo shrink. But I only managed to make the bottom header to work. The first section ...