* filmbokep Hello all, i have site http://filmbokeo.mobi
And i already make page 404. But when i delete my post in blog. And i open again that link its not direct to 404.
Please help me. Please someone fix my page 404, because google webmaster say like that.
Thanks
2015-11-26 11:36 · (0)
* Graham * filmbokep If you delete a blog post it will not redirect to 404 at the most it will say "post not found" as the page is still there just not that post
2015-11-26 12:26 · (0)
* filmbokep * Graham How to make it direct to 404 url sir...? Because i already delete so many post. And got message from google webmaster it shoud be direct to 404 url. Thanks
2015-11-26 16:26 · (0)
* Lordeagle * filmbokep If a page is provided by xtgem for non existing post the page may have descriptive caption like 'page not found' it either become the page title or it will be appended to the page title, if my presumption becomes a fact then u set up a javascript to search the caption in the page title and if positive result should redirect the page to 404 page consider the code below
<script> var check=document.title.indexOf("post not found");
if(check!=-1){window.location.replace("/404");}</script>

Copy code
get back to me if my suggestion did not work.
2015-11-26 18:54 · (0)
* Graham * Lordeagle The title is not set for non existing posts so that would not work but you can set it in the blog twig
at the bottom of the twig file is the bit that outputs for non existing entries

{% block no_entry %}
<div class="xt_blog xt_list">No blog entry found</div>
{% endblock %}

You can add the redirect here
{% block no_entry %}
      <script>window.location.replace("/404");</script>
{% endblock %}

Copy code
2015-11-26 19:52 (edited 2015-11-26 19:53 by Graham ) · (0)
* Lordeagle * Graham Better
2015-11-26 21:01 · (0)
* filmbokep * Graham am i put the code in index...? Or in another place....?
2015-11-26 23:14 · (0)
* Graham * filmbokep You need to create _xtgem_templates folder and upload the blogs twig file to it and then edit that
Upload by remote server from https://dl.dropboxusercontent.com/u/2162515/xtgem_blog.twig
and rename it xtblog.twig
2015-11-27 01:55 · (0)
* Graham Just a thought but I think you should redirect to a page that does not exist so that the proper error code is set
for example
<script>window.location.replace("/404");</script> is a redirect to an existing page so 404 is not set
<script>window.location.replace("/404.html");</script> is a redirect to a page that does not exist so xtgems 404 system takes over and sets the correct error code and loads the custom 404 page
2015-11-27 11:01 · (0)
* filmbokep * Graham i got trouble, when i put that script in bottom of xtblog.twig and i open my site (i am just write the domain) its direct to 404 url, and when i am delete again that script is back to normal, but my xtblog look like untidy , the title and the picture not in the center.
sir, i am not to understand about code / script. can u help me just sent the xtblog.twig to me. but that twig file already modification by you to me. i need url 404 working and my xtblog twig looking good already in the center.

for your attention i say thank you very much
2015-11-27 18:19
*
* link.jpg · image/jpeg · 55.97KB
· (0)

Online: Guests: 1