Recent Topics

1 Feb 19, 2016 00:48    

I know this may be simple, but I can't figure out how to redirect a post to a new url. I read the thread at:

http://forums.b2evolution.net/topic-15059

If I put the new url in the Advanced Properties . Link to URL box in the post then mark it as redirected - I get a "Sorry, nothing here to display" message when I bring the page up instead of it being redirected.

I've been using B2Evo for 10 yrs, but this has be scratching my head. On ver 6.6.7. Any help would be appreciated.

2 Feb 19, 2016 01:38

Hi @vapor ,
As you see, the property of "Redirected" is the visiable state of a post which would never be seen in the front-office. So when you set "View blog after publishing" as "View new post" in the back-office, you would get "Sorry, nothing here to display" message.However you can see and edit it in the the back-office.

I know now you get the question : What is the meaning of it?

I guess, it's no sense for the new topic, but get the meaning of old ones which have been referenced by other articles. When the old post has been moved to other site(or other situations), you can edit it as a "Redirected" post, then all the referenced links in other posts would be redirected to the new url.

This is my understanding. You may also would like to check out the manual help : http://b2evolution.net/man/visibility-status

3 Feb 19, 2016 01:48

So I'm trying to simply redirect a post from b2evo to a new url which is a static page elsewhere on my site. How would you do this? The thread I referenced above indicates it can be done, but it doesn't seem to be working for me.

The manual area you referenced I looked at and it states:

> Redirected Posts
This is designed for content that has moved to another place (typically another site). You can enter an URL in the "Link to Url" field in expert mode and then set the status to Redirected.

Front office: trying to access the post (by any user) will redirect (301) to the destination URL

It isn't redirecting as the manual states it should.

Reading more on the forum, I don't seem to have a choice to switch to "expert mode" which might be the problem, But I'm not sure if that's still relevant in v 6.6.7.

4 Feb 19, 2016 02:10

@vapor wrote earlier:

So I'm trying to simply redirect a post from b2evo to a new url which is a static page elsewhere on my site. How would you do this? The thread I referenced above indicates it can be done, but it doesn't seem to be working for me.


Do you want keep the post in the posts list and also be visiable in the front-office, then redirect it to the other url just by clicking the post title?

I don't know how to do that. (Maybe there is no such function now, or could be done by some configuration.But does that make sense?)

However you can make the post as a sidebar link, and list it in the sidebar. (or other striking place by using the Widget)

5 Feb 19, 2016 02:14

I want to be able to have the page redirect to the new page when I load the old url into a web browser. I appreciate your help haharen, but I don't think you understand what I'm asking.

6 Feb 19, 2016 02:24

@vapor wrote earlier:

I want to be able to have the page redirect to the new page when I load the old url into a web browser. I appreciate your help haharen, but I don't think you understand what I'm asking.

Can you give your website, and the old link, then I have a try.

8 Feb 19, 2016 02:28

Does that mean you have not found the place where you would type the URL in?

9 Feb 19, 2016 02:31

Yes, the new url is in there and it's simply showing an error page "Sorry, nothing to display". I added above that I'm using a stub file for this page, so not sure if that could be the issue.

10 Feb 19, 2016 02:37

@vapor
Please find the post in the back-office which you set to "Redirected", then click the permalink, to see if it's working or not.

11 Feb 19, 2016 02:43

Yes, the permalink in the back office IS working as desired.

12 Feb 19, 2016 02:58

@vapor
Now let us take a analysis.
You used the stub file 'http://thek9guy.com/dog_blog/ddn.php' for an page post, but now the post is out of date and should be redirected to another page.So set the page as a 'Redirected' type and also input the new URL, then visit the stub file 'http://thek9guy.com/dog_blog/ddn.php' , it can't work correctly. But when you click the permalink of the old page post, it would be OK.

So, I guess the problem is in the file : 'ddn.php'. I don't know how you take the stub file as the old post page. However you may check it out to find if the old page url is really the permalink of the old page post, or just replace it to the new URL which you want to redirect to.

13 Feb 19, 2016 03:16

It now seems to be working. I only had one post on that blog - once I added a second post it began working properly. Not sure whether this is a bug or not. I had removed the stub file and reconfigured my url settings - had the same issue with or without it. Didn't seem to be a stub file issue.

Thanks for your help.

14 Feb 19, 2016 03:58

@vapor ,
Yes, you're right, the first post of one collection can't be 'Redirected' to the new URL but showing the front page of that collection. Then following posts(second , third...) which set to 'Redirected' would be OK.

I use the b2evolution 6.7.0-alpha for this test. Maybe it's a bug.

15 Feb 20, 2016 07:04

@vapor maybe, a direct 301 redirection rule included into your .htaccess file would be a better idea than using b2evolution's internal redirect mechanisms (zero php processing + no database load on each visit).

However, I can't reproduce what you said, so please let me tell you what I did and correct me if I did not follow your real scenario in order to find out a potential bug, as @haharen said.

  1. Create a new collection (empty).
  2. Add a new post (type=page, visibility=redirected). Actually, it's the same if the post was already created and just changed the visibility to redirected and added the "Link to URL" value.
  3. Add a stub file pointing to the post mentioned above.

I got redirected correctly when I go to http://example.com/stubfile.php.

Am I missing something?

16 Feb 20, 2016 08:29

@mgsolipa
It's really weird that sometimes we can't catch the exception. When I used b2 which no test data installed for testing, everything is OK.
But if I use another b2 which already had test data(the first blog named "BlogA") generated by the installation procedure, then I change the first post: 《Main Intro post》 to the "Redirected" type, the problem occored, as follow:

The first post of one collection can't be 'Redirected' to the new URL but showing the front page of that collection. Then following posts(second , third...) which set to 'Redirected' would be OK.


Form is loading...