Posts

Showing posts with the label PHP

How to Increase PHP Limit for a Wordpress Site ?

 1. Increasing PHP Time Limit via PHP.ini file max_execution_time = 300; 2. Alternative to editing PHP.ini through wp-config.php set_time_limit(300); 4. Modifying the .htaccess file max_execution 300 ============================ Using wp-config.php file define('WP_MEMORY_LIMIT', '256M');

Elementor displays the same shortcode twice (only on editor) Functions.php Two TIme Costom Post

Elementor displays the same shortcode twice. One in the place where the shortcode is placed, and the other right behind the header. The problem only occurs in the editor. On the page, it displays normally. Please help. How can i fix it? I solved the problem :) I used ob_start(); and return ob_get_clean(); function elementor_shorcode_test ( ) { ob_start (); elementor_shorcode_test_output (); return ob_get_clean (); } Example Code: /*Custom Post type start*/ function cw_post_type_events() { $supports = array('title', 'editor', 'author', 'thumbnail', 'excerpt', 'custom-fields', 'comments', 'revisions', 'post-formats', ); $labels = array( 'name' => _x('Events', 'plural'), 'singular_name' => _x('Event Post', 'singular'), 'menu_name' => _x('Event Post', 'admin menu'), 'name_admin_bar' => _x('event', ...

Fatal error: Maximum execution time of 300 seconds exceeded in C:\xampp\phpMyAdmin\libraries\classes\Dbi\DbiMysqli.php on line 199

Image
  Whenever you import file in in database then after some processing time its show you have using Maximum execution time of 300 seconds exceeded will be showing this type of error in your database: First of all stop your Xampp Next step : go to config.default.php Once that’s done get back to finding phpMyadmin config file named something like “config.default.php”. On XAMPP you will find it under “C:\xampp\phpMyAdmin\libraries” folder. Open the file called config.default.php  and set : $cfg['ExecTimeLimit'] = 0; Simply paste here.. Once set, restart your MySQL and Apache and go import your database.   

Custom Carousel using Function.php Custom post type using shortcode [custom-post-type] example.

 /* STUDY ABROAD */ function studyabroads_register() {  $labels = array(   'name' => _x('Studyabroad', 'post type general name'),   'singular_name' => _x('studyabroads', 'post type singular name'),   'add_new' => _x('Add New', 'review'),   'add_new_item' => __('Add New Studyabroads'),   'edit_item' => __('Edit Studyabroads'),   'new_item' => __('New Studyabroads'),   'view_item' => __('View Studyabroads'),   'search_items' => __('Search Studyabroads'),   'not_found' =>  __('Nothing found'),   'not_found_in_trash' => __('Nothing found in Trash'),   'parent_item_colon' => ''  );  $args = array(   'labels' => $labels,   'public' => true,   'publicly_queryable' => true,   'show_ui' => true,   'query_var'...

BACK TO TOP SHORTCODE

  major faults wordpress developer uslu forget <!-- Go Top Back --> <script type="text/javascript"> // create the back to top button $('body').prepend('<a href="#" class="back-to-top">Back to Top</a>'); var amountScrolled = 300; $(window).scroll(function() { if ( $(window).scrollTop() > amountScrolled ) { $('a.back-to-top').fadeIn('slow'); } else { $('a.back-to-top').fadeOut('slow'); } }); $('a.back-to-top, a.simple-back-to-top').click(function() { $('html, body').animate({ scrollTop: 0 }, 700); return false; }); </script> a.back-to-top { display: none; width: 60px; height: 60px; text-indent: -9999px; position: fixed; z-index: 999; right: 20px; bottom: 20px; background: #27AE61 url("../images/up-arrow.png") no-repeat center 43%; -webkit-border-radius: 30px; -moz-border-radius: 30px; border-radius: 30px; } a:hover.back-to-t...

DATE PICKER FOR ANY CODE WORDPRESS PHP ETC

  <link rel="stylesheet" href="http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css" /> <script src="http://code.jquery.com/jquery-1.8.2.js"></script>    <script src="http://code.jquery.com/ui/1.9.1/jquery-ui.js"></script>    <script>    $(function(){        $( ".datepicker" ).datepicker();        $("#icon").click(function() {            $(".datepicker").datepicker( "show" );        })    });    </script> <input type="text" required name="issue_date" size='9' class="datepicker" value="<?php echo $value['issue_date']; ?>"/> <td><input type="text" required name="valid_up" size='9' class="datepicker" value="<?php echo $value['valid_up']; ?>"/></td>