Search
 
SCRIPT & CODE EXAMPLE
 

PHP

allow json uploads in Wordpress

function cc_mime_types($mimes) {
$mimes['json'] = 'application/json'; 
$mimes['svg'] = 'image/svg+xml'; 
return $mimes; 
} 

add_filter('upload_mimes', 'cc_mime_types');
Comment

PREVIOUS NEXT
Code Example
Php :: Modes of file reading php 
Php :: retrieving a cookie in php 
Php :: enable gd php 
Php :: how to get current location latitude and longitude in php 
Php :: how to send data from one website to another in php 
Php :: migrate particular file laravel 
Php :: do while php 
Php :: laravel csrf token off 
Php :: php utc time 
Php :: paginate relationship laravel7 
Php :: validation error laravel 8 with custom massage 
Php :: <a href="<?php echo base_url(); ?"somelink</a 
Php :: laravel 6 get user id 
Php :: php remove html tag 
Php :: php upload file 
Php :: delete file in php 
Php :: Append a text string to WooCommerce single product title 
Php :: php variable in string 
Php :: how to sum in laravel 
Php :: maintaining serial number in laravel pagination table 
Php :: get post php 
Php :: sha256 encryption in php 
Php :: laravel 8 try catch 
Php :: upload_max_filesize in wordpress 
Php :: php calculate hours and minutes between two times 
Php :: php extract last n words of string 
Php :: redirect to attempting url after login laravel 
Php :: array_push 
Php :: send OTP php 
Php :: Get the post category if you have a custom post_type 
ADD CONTENT
Topic
Content
Source link
Name
8+4 =