Home › Forums › Legacy Support › Support queries › How-to & Troubleshooting › Change URL for Course directory buttons
Tagged: course directory
- This topic has 11 replies, 2 voices, and was last updated 3 years, 4 months ago by Veronica.
Viewing 12 posts - 1 through 12 (of 12 total)
-
AuthorPosts
-
July 29, 2021 at 6:38 pm #366683DiegoParticipantHi: I have a course directory set as a home page temprarily @ https://inteli-iuris.flywheelsites.com, however we don't want the button under each course to be redirected straight to the cart, but rather to take them to the course layout itself first, same as the image from the course does. I can't edit this via Elementor Course Directory module. Any advise to change this urls for the buttons? ThanksJuly 29, 2021 at 8:45 pm #366686DiegoParticipantI was able to find the editable at VibeBP > Course Card. However, within the elementor module "Course button", there is no such control to customize where the card will be pointing. Is there any way to make it point to the course card instead of redirecting to the cart with the product?July 30, 2021 at 12:27 pm #366736VeronicaModeratorhi means you want to change this course button redirection to the single course page? without checkout and cart page? please confirmJuly 30, 2021 at 1:29 pm #366742DiegoParticipantSomething like that. Sorry if I wasn't clear enough. What we need is for course button from course card in the directory to redirect to the single course page, but then, in the single course page, the "take this course" button does redirect to the cart page with the item added (as it is now). That's why I was wondering if there is no control for the course button behavior to change the link it takes to. Summary: from course card to build directory > single course page. from single course page > shopping cart and checkout. Thanks a lot, Veronica.August 2, 2021 at 8:18 am #366859VeronicaModeratoryes this is possible i need to check the code and then provide here please ping me tomorrow for the sameAugust 3, 2021 at 12:02 am #366943DiegoParticipantHi Veronica: Thanks for the help. Pinging you for the code you told me.August 3, 2021 at 11:23 am #366996VeronicaModeratorhi yes right checking will share within 1 hourAugust 3, 2021 at 12:00 pm #367001VeronicaModeratorhi add this is wplms-customizer.php
add_filter('wplms_take_course_button_html','course_button_redirect',1660,2); function course_button_redirect($html,$course_id){ if(!is_singular('course')){ $extra =' '; $page = get_permalink($course_id); return '<a href="'.$page.'" class="course_button full button">'.apply_filters('wplms_take_this_course_button_label',__('TAKE THIS COURSE','vibe'),$course_id).apply_filters('wplms_course_button_extra',$extra,$course_id).'</a>'; } return $html; }
August 4, 2021 at 12:41 am #367070DiegoParticipantThis reply has been marked as private.August 4, 2021 at 10:21 am #367106VeronicaModeratorooh dear please remove the code from custom CSS section add this in wp-admin>>plugins>>plugins editor select wplms-customizer plugin and in wplms-customizer.php add the above code and then checkAugust 4, 2021 at 3:13 pm #367169DiegoParticipantOhhh! My bad, Veronica. Thought you were talking about theme customizer. I didn't even know of the wplms customizer plugin, found it, installed it and it works fine. Thanks a lot for your patience on this matter. You can close the thread now.August 5, 2021 at 11:23 am #367225VeronicaModeratorHey, We aim to improve the usability of our customer’s web-sites and we are glad to have made a contribution. If you find our information to be helpful & you wouldn’t mind leaving a review, we would really appreciate that! Here: https://themeforest.net/item/wplms-learning-management-system/reviews/6780226 Thanks & Regards -
AuthorPosts
Viewing 12 posts - 1 through 12 (of 12 total)
- The topic ‘Change URL for Course directory buttons’ is closed to new replies.