Difference between revisions of "Diaplasi User Site"

From CommonsLab
Jump to navigation Jump to search
(Created page with "Wordpress JWT Authentication for WP REST API configure JWT authentication")
 
 
(4 intermediate revisions by the same user not shown)
Line 1: Line 1:
Wordpress
+
The User site or Front-end is http://diaplasi.net.
JWT Authentication for WP REST API
+
It is the site where users register and edit their profile which contains all personal and medical information. It is also the site with which the application verifies a user.
configure JWT authentication
+
 
 +
The site is Wordpress and uses the following plug-ins:
 +
* Allow Multiple Accounts
 +
* Diaplasi
 +
* JWT Authentication for WP-API
 +
* Ultimate Member (do not upgrade, custom changes in files)
 +
* WPML Multilingual CMS [https://github.com/wp-premium/sitepress-multilingual-cms|github]
 +
* WPML String Translation
 +
 
 +
Add and activate Cactus theme
 +
 
 +
Configuration
 +
* configure JWT authentication according to [https://wordpress.org/plugins/jwt-authentication-for-wp-rest-api/#description|here]
 +
 
 +
* add Greek language to WPML
 +
* Create forms (Register & Profile) and then pages for Ultimate member forms.
 +
* add profile.php & w3.css to wp-content/themes/cactus/ultimate-member/templates/
 +
* Custom redirect URL: https://diaplasi.net/login
 +
* edit UM Settings -> "Access" exclude the following URLs
 +
** https://diaplasi.net/el/register-el
 +
** https://diaplasi.net/el/register
 +
** https://diaplasi.net/el/login-el
 +
** https://diaplasi.net/login
 +
** change core/class-fields.php and add
 +
<nowiki>$resArray = explode(', ',$res);
 +
foreach ($resArray as &$r) {
 +
$r = __( $r ,UM_TEXTDOMAIN);
 +
};
 +
unset($r);
 +
$res = implode (', ',$resArray);
 +
</nowiki>
 +
before
 +
<nowiki>
 +
$output .= '<div class="um-field-value">' . $res . '</div>';</nowiki>
 +
** add profile id in um-meta in um-actions-profile.php
 +
<span class="b">•</span>
 +
<?php echo um_profile_id();?>

Latest revision as of 11:26, 26 February 2019

The User site or Front-end is http://diaplasi.net. It is the site where users register and edit their profile which contains all personal and medical information. It is also the site with which the application verifies a user.

The site is Wordpress and uses the following plug-ins:

  • Allow Multiple Accounts
  • Diaplasi
  • JWT Authentication for WP-API
  • Ultimate Member (do not upgrade, custom changes in files)
  • WPML Multilingual CMS [1]
  • WPML String Translation

Add and activate Cactus theme

Configuration

  • configure JWT authentication according to [2]

$resArray = explode(', ',$res); foreach ($resArray as &$r) { $r = __( $r ,UM_TEXTDOMAIN); }; unset($r); $res = implode (', ',$resArray); before $output .= '<div class="um-field-value">' . $res . '</div>';

    • add profile id in um-meta in um-actions-profile.php

<?php echo um_profile_id();?>