get current user password on the profile edit page

This cannot be done, it is not possible, and it would be an awful thing to do if it was. Do not attempt or pursue this. Why It Is Not Possible Passwords are ran through a 1 way hashing function before being stored in the database. This allows us to check if a password matches … Read more

Parse error: syntax error, unexpected ‘echo’ (T_ECHO) in C:\xampp\htdocs\AttendanceSystem\resources\php\method.php on line 250 [closed]

You don’t need to echo it. You can just add it to the string since we’re in PHP at that point: ‘<span style=”font-size: 16px;”>’ . esc_html( $student_name ) . ‘</span></span></p>’ You should also escape any variables you’re adding to HTML strings using esc_html() in case the strings contain HTML tags not just plain text.

clickable title of 2 post on mainpage USING functions.php

here is answer 🙂 add_action(‘generate_after_header’, ‘work_only_on_front_page’, 999); function work_only_on_front_page(){ if ( is_front_page() ) { echo ‘ any text with divs’; $args = array( ‘posts_per_page’ => 2, // we need only the latest post, so get that post only ‘cat’ => ‘1’ // Use the category id, can also replace with category_name which uses category slug … Read more

What theme does this website use? [closed]

Looks like WP – BuiltWith shows WordPress and Elementor as of Feb 2020, and Elementor classes are visible via inspector There’s no way to see which theme it is (afaik), but it’s using Elementor, so it probably wouldn’t matter which theme it uses if you’re just looking to emulate its appearance. Also worth noting that … Read more

Auto play audio using WP Maintenance Mode Plugin [closed]

A couple of things: First, this code has some syntax issues – the src attribute isn’t properly closed. Further, as noted by @Rup, autoplay should have a value of on: Broken tag: Fixed Second, I’m not 100% sure that WP Maintenance posts can process shortcodes. I would instead use a standard HTML Audio Tag.

add custom css on all page exept of one

add this to end of functions.php function mmk_enqueue_script(){ if( !is_page(123) ){ wp_enqueue_style(‘responsive-css’, get_stylesheet_directory_uri() . ‘/custom.css’, false); } } add_action( ‘wp_enqueue_scripts’, ‘mmk_enqueue_script’, 999); create a custom.css inside your theme directory. this CSS file will be applied to all pages except the one you specified. update “123” inside if condition with page id where you don’t want … Read more

How to calculate posts number? [closed]

Do you mean like this $result = 10; foreach ( $posts as $post ) { if ( $a = $b ) ) { $result += 1; } else { $result -= 2; } } echo ‘Your result is ‘ . $result; This is the best I can do with the provided information

How can I execute $string = if();? [closed]

You have a few options to assign that value into $string but ill show two First using regular if $string = ”; if (!empty($_GET[‘category’]) { $string = $_GET[‘category’]; } Second using ternary operator $string = !empty($_GET[‘category’]) ? $_GET[‘category’] : ”; When working with data that you receive from outer sources, for example, inputs, url etc… … Read more

Add clickable function in functions.php – parse error [closed]

For clarity’s sake regarding my comments, this is something more akin to what I’m talking about… // plugins/wpse392844/wpse392844.php function wpse392844_enqueue_assets() { wp_enqueue_script( ‘wpse392844-frontend’, plugins_url( ‘assets/js/frontend.js’, __FILE__ ) ); } add_action( ‘wp_enqueue_scripts’, ‘wpse392844_enqueue_assets’ ); // plugins/wpse392844/assets/js/frontend.js function thfull() { document.getElementById(‘thf’).style.maxHeight=”1000px”; } (we’re defining the thfull() function in JavaScript rather than PHP such that the browser will … Read more