Search
 
SCRIPT & CODE EXAMPLE
 

PHP

add custom shortcode in contact form 7

wpcf7_add_shortcode('custom_date', 'wpcf7_custom_date_shortcode_handler', true);

function wpcf7_custom_date_shortcode_handler($tag) {
    if (!is_array($tag)) return '';

    $name = $tag['name'];
    if (empty($name)) return '';

    $next_week = date('Y-m-d', time() + (60*60*24*7)); 
    $html = '<input type="hidden" name="' . $name . '" value="' . $next_week . '" />';
    return $html;
}
Comment

PREVIOUS NEXT
Code Example
Php :: pagination in codeigniter with example 
Php :: Get All dates of a month with laravel carbon 
Php :: how get the size of image in laravel 
Php :: php while loop 
Php :: keep line breaks in textarea 
Php :: laravel set production 
Php :: php docs comments 
Php :: remove square brackets from string php 
Php :: session value not removed php 
Php :: php globals 
Php :: laravel notification 
Php :: in arrray php 
Php :: change verify email template laravel 
Php :: laravel datatable render html 
Php :: use session in laravel 
Php :: Using the PHPExcel library to read an Excel file and transfer the data into a database 
Php :: resource route controller laravel 8 
Php :: call_user_func() 
Php :: the requested url was not found on this server. apache/2.4.46 (win64) openssl/1.1.1h php/8.0.1 server at localhost port 80 
Php :: delay queue laravel 
Php :: unique check two clolumn in laravel validation 
Php :: php function to minify javascript and css 
Php :: laravel save file or picture directory 
Php :: number text short in laravel 
Php :: json decode 
Php :: append single qoute arounf variable in php string 
Php :: php return associative array 
Php :: wp wc archive product page template 
Php :: Use external variable in array_filter 
Php :: adjacent post sort order by post title 
ADD CONTENT
Topic
Content
Source link
Name
4+9 =