body_start(); $mega_menu_items = Donation::whereIn('id',$ids)->get(); if ($settings['sort_by'] === 'asc'){ $mega_menu_items->sortBy($settings['sort']); }else { $mega_menu_items ->sortByDesc($settings['sort']); } foreach ($mega_menu_items as $post) { $output .= '
'; $output .= '
'; $output .= ''; $output .= '
'; $output .= '

'.$post->title.'

'; $output .= '
'; $output .= '

'.get_static_option('donation_raised_'.$lang.'_text'); if(!empty($post->raised)){ $output .= amount_with_currency_symbol($post->raised); }else{ $output .= amount_with_currency_symbol(0); } $output .='

'; $output .= '

'.get_static_option('donation_goal_'.$lang.'_text').''.amount_with_currency_symbol($post->amount).'

'; $output .= '
'; $output .= ' '.get_static_option('donation_button_'.$lang.'_text').''; $output .= '
'; } $output .= $this->body_end(); // TODO: return all makrup data for render it to frontend return $output; } function category($id) { return ''; } function name() { // TODO: Implement name() method. return 'donation_page_[lang]_name'; } function slug() { // TODO: Implement name() method. return 'donation_page_slug'; } function enable() { // TODO: Implement enable() method. return true; } function query_type() { // TODO: Implement query_type() method. return 'old_lang'; // old_lang|new_lang } function title_param() { // TODO: Implement title_param() method. return 'title'; } }