• okiewardoyo

    (@okiewardoyo)


    i try to make a new function on functions.php of my current theme.
    Yes, just create a new function, but my wordpress always error with stupid blank white page.
    i’m desperated with white blank page error. ;'(
    it just show blank page, no more information there.

    i have set up wp-config.php:
    error_reporting(E_ALL); ini_set(‘display_errors’, 1);
    define(‘WP_DEBUG’, true);

    but still display no error information, just blank white page, can somebody help me??


    actually, i created a new function from my current theme

    if( ! function_exists( 'generate_layananpro_form' ) ) {
    	function generate_layananpro_form($post_id){
    		//
    		$arr_layananpro = array('top_listing', 'top_agen');
    		//
    		foreach($arr_layananpro as $a){
    
    			$arr_pre = array();
    			$arr_pre = get_layananpro_status_form_db($post_id, $a);
    			$arr_pre = array_filter($arr_pre);
    
    			//print_html_r($arr_pre, $a);
    
    			/*
    			based on print_html_r function, $arr_pre will result:
    			for top_listing it will show below
    			Array
    				(
    				[status] => pending
    				[length] => 30
    				)
    
    			for top_agen it will show below
    			Array
    				(
    				[status] => approved
    				[length] => 20
    				)
    			*/
    
    			if (!empty($arr_pre)) {
    				if($arr_pre['status'] == 'pending'){
    					echo "$a -> status pending, please wait<br/>";
    				}
    
    				elseif($arr_pre['status'] == 'approved'){
    					echo "$a -> status aproved, you can use it now<br/>"
    				} 
    
    			}
    			else{
    				echo "your layanan pro $a is empty <br/>";
    			}
    
    		}
    
    	}
    }

    when i run it, it show blank page.

    BUT, when i delete this below line, it work well,

    elseif($arr_pre['status'] == 'approved'){
    					echo "$a -> status aproved, you can use it now<br/>"
    				}

Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
  • The topic ‘How to make white blank page error more informatif’ is closed to new replies.