HexEgg
Forum Replies Created
-
Indeed, missed that last update. Now everything’s back to normal.
Well this is just to redirect a user during login to the Portal page from where the user is redirected to his/her private page. But the Portal page itself by default redirects user to ENG only version of the private page (or whatever language is set as main for the site). By the way we’re using different domains for each language (mysite.com and mysite.fr).
I need the Portal to do the following:
1. Check what site language is currently being used.
2. Redirect to the according user’s private-page (if a user came from .fr domain, then redirect him/her to the “mysite.fr/private-page/username”, else redirect to “mysite.com/private-page/username”).I found this snippet on the WPML support forum. I put it into my functions.php file on in child theme:
//**** WPML post auto duplication ****/ add_action( 'wp_insert_post', 'my_duplicate_on_publishh' ); function my_duplicate_on_publishh( $post_id ) { $post = get_post( $post_id ); //don't save for autosave if ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) { return $post_id; } //dont save for revisions if ( isset( $post->post_type ) && $post->post_type == 'revision' ) { return $post_id; } //we need this to avoid recursion see add_action at the end remove_action( 'wp_insert_post', 'my_duplicate_on_publishh' ); //make duplicates if the post being saved //#1. itself is not a duplicate of another or //#2. does not already have translations $is_translated = apply_filters( 'wpml_element_has_translations', '', $post_id, $post->post_type ); if ( !$is_translated ) { do_action( 'wpml_admin_make_post_duplicates', $post_id ); } //must hook again - see remove_action further up add_action( 'wp_insert_post', 'my_duplicate_on_publishh' ); }
Though it duplicates not just private pages, but any new created page.
Im using your profile builder.
Forum: Plugins
In reply to: [User Role Editor] Problems with WPMLYeah, I somehow lost all the wpml_manage_.. capabilities. Added them back for Administrator and all is good again. Thank you!
looks like it does delete user’s page on user deletion, but with WPML plugin it only deletes one language page (my site has two languages). How to make it delete pages in all languages?
Oh ok then, thank you for reply anyway!
Forum: Fixing WordPress
In reply to: Edit html fileYou need to install a plugin that allows to add scripts to you site’s header or footer. Search for Header and Footer Script on wordpress plugin page. Then copy my script and insert in in header (via settings page of the plugin you installed).
Here is the script again:
<script type=”text/javascript”>
jQuery(document).ready(function() {
jQuery(“input[placeholder=’search’]”).attr(“placeholder”, “any text”);
}
</script>Assuming you’re changing a placeholder named “search” with “any text”.
Forum: Fixing WordPress
In reply to: Edit html fileYou can always do such things with JavaScript (or even better with jQuery)!
<script type=”text/javascript”>
jQuery(document).ready(function() {
jQuery(“input[placeholder=’search’]”).attr(“placeholder”, “Your Text”);
}
</script>Put this scrip either at the bottom of the page where you have this search field.
Or, if this field is on every page, place it in header, or footer.
Cheers!Thank you! I’ll be waiting for a solution. Right now this is the only problem I have with your plugin, all other issues were resolved. ??
Wow, didn’t think it was under my nose! Just tried it and it works! Thank you!
Hi, I solved this problem!
This might be useful to someone else:
1. On my template page made with VC I switched to classic view to display the template as shortcodes.
2. Copied all the shortcodes.
3. Pasted it all to ‘Default Page Content’ field on Client Portal Settings page.Now every time I create a new user, it automatically creates a new private page with all the shortcodes. And in my VC settings I sat ‘Backend Editor’ option to ‘Enabled and Default’ thus when I go to the new private page from the Users list page, it shows my VC template instead of a bunch of shortcodes.
Thank you for the great plugin!
Forum: Plugins
In reply to: Yoast SEO Open Graph not working correctlyGo here: https://optimwise.com/wordpress-posts-social-media-open-graph/
Scroll down to this section: “Troubleshooting How Posts Appear On Social” and follow the instructions (go to the FB link, click “Fetch new scrape” a couple of times).