This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <form action="<?php echo esc_url( admin_url('admin-post.php') ); ?>" method="post" enctype="multipart/form-data"> | |
| <!-- Security field --> | |
| <?php wp_nonce_field( 'media_upload', 'media_upload_nonce' ); ?> | |
| <label for="file_upload">Select File:</label> | |
| <input type="file" name="file_upload" id="file_upload" required /> | |
| <input type="hidden" name="action" value="frontend_media_upload"> | |
| <input type="submit" name="submit" value="Upload Media" /> | |
| </form> | |
| <?php |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Source - https://stackoverflow.com/a | |
| // Posted by James | |
| // Retrieved 2026-01-14, License - CC BY-SA 3.0 | |
| function getDistance() | |
| { | |
| //Find the distance | |
| var distanceService = new google.maps.DistanceMatrixService(); | |
| distanceService.getDistanceMatrix({ | |
| origins: [$("#autocompleteDeparture").val()], |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!DOCTYPE html> | |
| <html lang="en"> | |
| <head> | |
| <meta charset="UTF-8"> | |
| <meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
| <title>PHP File Upload</title> | |
| <link rel="stylesheet" href="index.css"> | |
| </head> | |
| <body> | |
| <div class="container"> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| add_action( 'um_registration_set_extra_data', 'my_custom_after_registration_action', 10, 2 ); | |
| function my_custom_after_registration_action( $user_id, $args ) { | |
| if ( empty( $user_id ) || is_wp_error( $user_id ) ) { | |
| return; | |
| } | |
| // Check if the specific radio button field value exists in the submitted data |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| function add_custom_item_to_menu( $items, $args ) { | |
| if ( $args->theme_location == 'primary-menu' ) { | |
| $user = wp_get_current_user(); | |
| $user_meta = get_userdata($user->ID); | |
| $user_role = $user_meta->roles[0]; | |
| if($user_role == 'um_employeur' || $user_role == 'administrator'){ | |
| $items .= "<li id='main-menu'><a href='https://monemploi.net/ajouter-un-emploi/'>Ajouter un emploi</a></li>"; | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| $execstring='ps -f -u www-data 2>&1'; | |
| $output=""; | |
| exec($execstring, $output); | |
| print_r($output); | |
| ?> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| function my_get_current_user_roles() { | |
| if( is_user_logged_in() ) { | |
| $user = wp_get_current_user(); | |
| $roles = ( array ) $user->roles; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #Cloudflare ip addresses | |
| # - IPv4 | |
| set_real_ip_from 173.245.48.0/20; | |
| set_real_ip_from 103.21.244.0/22; | |
| set_real_ip_from 103.22.200.0/22; | |
| set_real_ip_from 103.31.4.0/22; | |
| set_real_ip_from 141.101.64.0/18; | |
| set_real_ip_from 108.162.192.0/18; | |
| set_real_ip_from 190.93.240.0/20; |
NewerOlder