<?php _e('Offer help', 'tst'); ?> </a> <br /> <div id="guest-help-message" class="text-center help-block"> <div id="default"><em>(<?php _e('You have not offered your help yet', 'tst'); ?> )</em></div> <div id="login-please" style="display: none;"><em> <?php _e('You must log in to offer help to somebody!', 'tst'); ?> <a href="<?php echo tst_get_login_url(); ?> "><?php _e('Log In'); ?> </a> <?php _e('or', 'tst'); ?> <a href="<?php echo tst_get_register_url(); ?> "><?php _e('Register', 'tst'); ?> </a>. </em></div>
<?php } elseif (empty($_GET['code']) || get_user_meta($user->ID, 'activation_code', true) != $_GET['code']) { ?> <div class="alert alert-danger"><?php _e('Wrong data given.', 'tst'); ?> </div> <?php } else { update_user_meta($user->ID, 'activation_code', ''); global $email_templates; wp_mail($user->user_email, $email_templates['account_activated_notice']['title'], sprintf($email_templates['account_activated_notice']['text'], $user->user_login, home_url('/login/'))); $link = '<a href="' . tst_get_login_url() . '" class="alert-link">' . __('Enter on site', 'tst') . '</a>'; ?> <div class="alert alert-success"><?php printf(__('Your account is active now! Please %s.', 'tst'), $link); ?> </div> <?php } ?> </div> </div> <!-- .col-md-8 --> <div class="col-md-4"> </div>
</div><!-- .col-md-9--> </div><!-- .row --> </div><!-- .col-md-8 --> <div class="col-md-4"> <div class="panel panel-default"><div class="panel-body"> <h4><?php _e('Already have an account?', 'tst'); ?> </h4> <p> <?php $login = tst_get_login_url(); $login = "******" . __('Enter on site', 'tst') . "</a>"; printf(__("Please, %s.", 'tst'), $login); ?> </p> </div></div> </div><!-- .col-md-4 --> </div><!-- .row --> </div> <!-- .page-body --> <?php } // end of the loop. ?>
<li><a href="<?php echo home_url('/member-actions/member-tasks/'); ?> "><?php _e('My tasks', 'tst'); ?> </a></li> <li><a href="<?php echo tst_get_member_url($current_user); ?> "><?php _e('My profile', 'tst'); ?> </a></li> <li><a href="<?php echo wp_logout_url(tst_get_login_url() . '&t=1'); ?> "><?php _e('Log out', 'tst'); ?> </a></li> </ul> </li> <?php } else { ?> <li><a href="<?php echo home_url('login/'); ?> "><?php _e('Log In', 'tst');
<?php /** * Template Name: Task actions * */ $new_task = true; $task_data = array(); $task = new stdClass(); $faction = home_url('task-actions'); if (!is_user_logged_in()) { $login_url = tst_get_login_url(home_url('/task-actions/')); wp_redirect($login_url); die; } if (!empty($_GET['task'])) { $new_task = false; // Read some ID to the editable task from URL, get a task post obj, fill an array with it's params. $_GET['task'] = (int) $_GET['task']; $task = get_post($_GET['task']); if (empty($task) || !current_user_can('edit_post', $task->ID)) { wp_redirect(home_url('/task-actions/')); die; } $faction = add_query_arg('task', $task->ID, $faction); if (function_exists('get_field')) { // check for ACF active $task_data = array('task_id' => $task->ID, 'task_title' => $task->post_title, 'task_descr' => $task->post_content, 'task_status' => $task->post_status, 'expecting' => get_field('field_533bebda0fe8d', $task->ID), 'about_reward' => get_field('field_533bec930fe8e', $task->ID), 'about_author_org' => get_field('field_533beee40fe8f', $task->ID), 'deadline' => get_field('field_533bef200fe90', $task->ID), 'reward_id' => get_field('field_533bef600fe91', $task->ID), 'is_tst_consult_needed' => get_field(ITV_ACF_TASK_is_tst_consult_needed, $task->ID)); } } else { $task_data = array('task_status' => 'draft');