Comments (1)
Hi guys,
Good news, I figured out how to do it since there were no response. Here is the guide to add your custom headers.
Go to your file manager (or make these edit before uploading to your Wordpress website). Assuming it is uploaded then make the edit to this file (this guide is applicable to version 1.4.6 only, I think it general work for all version).
\wp-content\plugins\cf7-to-api-basic-auth\includes\class-cf7-api-admin.php
Around lines 561 you should see this code:
if( $record_type == "json" ){
$args['headers']['Content-Type'] = 'application/json';
Now I want to add another custom headers in here, I would change from up to this:
if( $record_type == "json" ){
$args['headers']['Content-Type'] = 'application/json';
$args['headers']['Accept'] = 'application/json';
Save file, do a test and see if it work. For me it did because my server require that "Accept" header.
I close this now since issue is resolve.
from cf7-to-api.
Related Issues (20)
- Handle API errors HOT 6
- Bug Report - API Call not accepting Array Value HOT 5
- How to pass other authentication parameters ? HOT 1
- [feature] Timeout custom HOT 1
- API call not working. HOT 1
- API integration not working after updating CF7 plugin HOT 1
- Double quotation marks in field breaks api call HOT 3
- checkbox: multiple values not parsed HOT 1
- Error with post json HOT 5
- file input to API
- New version not passing short code values
- Doesn't handle 409 response codes correctly HOT 1
- adding "/" each time the form is saved HOT 8
- Form is not saved HOT 13
- File Upload is not working HOT 2
- Changes " with \" HOT 4
- Save error with latest CF7 and feature request HOT 2
- Hardcoded parameters in Called URL & Auth
- Blank parameters
- Cannot redeclare qs_cf7_textdomain()
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from cf7-to-api.