This is the technical support forum for WPML - the multilingual WordPress plugin.

Everyone can read, but only WPML clients can post here. WPML team is replying on the forum 6 days per week, 22 hours per day.

This topic contains 3 replies, has 2 voices.

Last updated by Itamar 1 year, 3 months ago.

Assigned support staff: Itamar.

Author Posts
February 6, 2019 at 8:13 am #3164448

Melanie Grote

I had a custom post type called "Veranstaltungen" and a tranlation from it called "events" and it worked fine. Now the cutomer wants to delete / hide the single post type view.
So I set the settings from the post type 2Veranstaltungen" to:
'public' => false,
'publicly_queryable' => false
using the plug-in "CP UI"
and for the german single post type it worked fine, if I call the url og the single post view in the browser it "redirect" me to the "home" page, that´s great.
But when I call the english url, the translation of the single post type is still referen to the single-page.php. I put a "file not found" page in it, to hide the content immediately.

But I really also want the translated single post type to refer to the "Home" page of the website like the german single post type url. How can I do this. So that the english single post type also ist not public.

Because Google found that single post type pages in the search list and the customer don´t want this to happen and is angry about it, so i need a fast solution. it woulb be so graet if you can help me.

February 6, 2019 at 6:02 pm #3167053


Languages: English (English ) Hebrew (עברית )

Timezone: Asia/Jerusalem (GMT+03:00)

Hi there.

I'm not sure that I fully understand the problem.
Is it one single post that you want to hide or delete or the whole CPT ("Veranstaltungen" / "Events")?
I do not understand why do you use the "CP UI" plugin, and I also do know this plugin.
Why don't you simply delete those CPT posts and their translations?
In WPML ->Settings -> Posts and pages synchronization you have the option 'When deleting a post, delete translations as well'. You can select it and press the save button. Then when you delete a post in the default language, its translation will be deleted as well.

As for the search results in Google, WPML is not responsible for that. And you should also know that the changes on your site do not reflect immediately in Google's search results. What usually needs to be done is to re-submit your site's map to Google Webmaster tool.
You can read more about it at the following link.
hidden link

I hope that this information is useful to you.

If you need more help from me then could you please share your Debug information with me?
You can read the detailed explanation about it here.
The debug info will give me a lot of information about how your site is configured and will help me understand the source of the problem.


February 7, 2019 at 6:57 am #3168655

Melanie Grote

Thank you Itamar for your answer. I can not delete it, because I still use it. it is the list on this page:
hidden link

But I don´t need the single post type page and I don´t want to have the link (url) working, not me the customer:
For example: The german single post type url (page) his is gone and redirect to home:
hidden link
tehre I changed:
'public' => false,
'publicly_queryable' => false
but it does not work for the translation.

The english one still refer to the single post type page where I put the conten "file not found it" for the moment. But I also want the english single post type to behave like the german. :
For example: hidden link

Can you help me, please?
Greetings Melanie

February 7, 2019 at 6:15 pm #3171769


Languages: English (English ) Hebrew (עברית )

Timezone: Asia/Jerusalem (GMT+03:00)


OK, I understand the issue better now. But before we continue with debugging the issue, I would like to ask you to perform the following procedures.

1. I can see that WordPress and WPML + add-ons are not updated to their latest version.
Please update everything and see if the issue persists.

2. By looking at the debug info that you have attached I can see that your server WP Memory Limit is set to 40M.
Our recommendations are to have the following as minimal requirements:
- PHP 5.3 and above (this OK with your installation) with a WP Memory Limit of at least 128MB and more if possible.
- MySQL 5.6 and above (this OK with your installation).
Please follow this link for detailed documentation:
Is it possible for you to change those to the minimum requirement?
You may need to contact your hosting provider for that.
Meeting those baseline requirements is most critical before starting to debug and sometimes solves issues like you experiencing.
Most important is to raise the WP Memory Limit.
Please try to raise it before you contact your hosting company.
You can try and do it from the wp-config.php file in your WordPress installation.
Insert this code in that file.

/** Memory Limit */
define('WP_MEMORY_LIMIT', '256M');
define( 'WP_MAX_MEMORY_LIMIT', '256M' );

Add it before this line:
/* That's all, stop editing! Happy blogging. */

Could you please perform those procedures and see if they help?

If the above does not help, then please let me have more details about this issue.
A. How do you create those events, is it with a plugin or part of your theme?
You wrote:
So I set the settings from the post type 2Veranstaltungen" to:
'public' => false,
'publicly_queryable' => false
B. How do you set those settings? Can you please elaborate on this point?


The topic ‘[Closed] I changed a custom post type to disbable the single view’ is closed to new replies.