Strange behavior on redirecting news addon

Post

Posted
Rating:
#3214 (In Topic #597)
Avatar
Site staff
enelson is in the usergroup ‘Super-moderators’
Yesterday I set up the following redirect to "move" the news addon to an "articles" zone:
articles:home ->welcome:news transparent
welcome:news -> articles:home not transparent.
I created a news entry and the redirect was working. However, after adding a new author and another article, the redirect is not working anymore. Am getting urls like http://example.com/articles/news/view/category/news-title which returns a 404 error.

If I manually enter what is supposed to be the correct address for E.g http://example.com/articles/home/view/category/news-title An error message is displayed-

Code

An error has occurred

A field that was supposed to be an integer (for our purposes, a whole number between -2147483648 and 2147483647) was not

I am thinking of removing the redirects and then setting the up again but just thought I should post this here first.

Last edit: by enelson

Online now: No Back to the top

Post

Posted
Rating:
#3217
Avatar
Site director
Chris Graham is in the usergroup ‘Administrators’
Can you please confirm this 'articles' zone is working correctly for normal pages?
(I assume it is 'articles', although you said 'article' once in your post).

You appear to be using a URL scheme, which adds extra complexity.

Also please confirm you are not using custom URL monikers on any of the news posts.


Become a fan of Composr on Facebook or add me as a friend. Add me on on Mastodon. Follow me on Minds (where I am most active). Support me on Patreon

Was I helpful?
  • If not, please let us know how we can do better (please try and propose any bigger ideas in such a way that they are fundable and scalable).
  • If so, please let others know about Composr whenever you see the opportunity or support me on Patreon.
  • If my reply is too Vulcan or expressed too much in business-strategy terms, and not particularly personal, I apologise. As a company & project maintainer, time is very limited to me, so usually when I write a reply I try and make it generic advice to all readers. I'm also naturally a joined-up thinker, so I always express my thoughts in combined business and technical terms. I recognise not everyone likes that, don't let my Vulcan-thinking stop you enjoying Composr on fun personal projects.
  • If my response can inspire a community tutorial, that's a great way of giving back to the project as a user.
Online now: No Back to the top

Post

Posted
Rating:
#3218
Avatar
Site staff
enelson is in the usergroup ‘Super-moderators’
The zone works correctly for normal comecode pages and even the landing page "home".
I've disabled the url scheme, reset it to raw PHP url, no changes.

Am not using any url moniker.

I've also noticed if the news article is accessed from the cms zone after editing the article by clicking on the view this article link the redirect works, only that the article name is replaced by the article id and the news category is removed so that -
http://example.com/articles/home/view/category/news-title
Becomes
http://example.com/articles/home/view/5
Online now: No Back to the top

Post

Posted
Rating:
#3219
Avatar
Site director
Chris Graham is in the usergroup ‘Administrators’
Hi,

If you want to drop me an email, chris@ocproducts.com, with admin access to the site, I'll make sure it is working for you. If I already have been given some kind of access please remind me (I recognise your name, so I think I may have done - sorry I get a bit blurry, I help on a lot of people's sites).


Become a fan of Composr on Facebook or add me as a friend. Add me on on Mastodon. Follow me on Minds (where I am most active). Support me on Patreon

Was I helpful?
  • If not, please let us know how we can do better (please try and propose any bigger ideas in such a way that they are fundable and scalable).
  • If so, please let others know about Composr whenever you see the opportunity or support me on Patreon.
  • If my reply is too Vulcan or expressed too much in business-strategy terms, and not particularly personal, I apologise. As a company & project maintainer, time is very limited to me, so usually when I write a reply I try and make it generic advice to all readers. I'm also naturally a joined-up thinker, so I always express my thoughts in combined business and technical terms. I recognise not everyone likes that, don't let my Vulcan-thinking stop you enjoying Composr on fun personal projects.
  • If my response can inspire a community tutorial, that's a great way of giving back to the project as a user.
Online now: No Back to the top

Post

Posted
Rating:
#3222
Avatar
Site director
Chris Graham is in the usergroup ‘Administrators’
Hi,

I just took another look.

I was able to fix it, you need to upload these changes files:
https://raw.githubusercontent.com/ocproducts/composr/master/sources/site.php (sources/site.php)
https://raw.githubusercontent.com/ocproducts/composr/master/site/pages/modules/news.php (site/pages/modules/news.php)

Please take backups before you overwrite them, in case of any compatibility issues.

We're not going to be able to support renaming for all modules, and there may be further issues that I can't provide a solution to (code changes would be needed). For example, the main_news block will still try and link to the 'news' module. While we search to find what zone a module is in when linking to one with consideration for redirects, we do not search to see if a module has been renamed. So for main_news right now I believe it would link to the welcome zone's news module which would then do a visible redirect (at least we're not stupid enough to link to the news module in the redirected zone but still use the old module name).
This could be changed by editing the code to link to the renamed module name explicitly, e.g. sources/blocks/main_news.php.


Become a fan of Composr on Facebook or add me as a friend. Add me on on Mastodon. Follow me on Minds (where I am most active). Support me on Patreon

Was I helpful?
  • If not, please let us know how we can do better (please try and propose any bigger ideas in such a way that they are fundable and scalable).
  • If so, please let others know about Composr whenever you see the opportunity or support me on Patreon.
  • If my reply is too Vulcan or expressed too much in business-strategy terms, and not particularly personal, I apologise. As a company & project maintainer, time is very limited to me, so usually when I write a reply I try and make it generic advice to all readers. I'm also naturally a joined-up thinker, so I always express my thoughts in combined business and technical terms. I recognise not everyone likes that, don't let my Vulcan-thinking stop you enjoying Composr on fun personal projects.
  • If my response can inspire a community tutorial, that's a great way of giving back to the project as a user.
Online now: No Back to the top

Post

Posted
Rating:
#3223
Avatar
Site director
Chris Graham is in the usergroup ‘Administrators’
I added a tracker issue for this, which I'd consider a new feature:
0003339: Support automatic correct linking for renamed modules - Composr CMS feature tracker


Become a fan of Composr on Facebook or add me as a friend. Add me on on Mastodon. Follow me on Minds (where I am most active). Support me on Patreon

Was I helpful?
  • If not, please let us know how we can do better (please try and propose any bigger ideas in such a way that they are fundable and scalable).
  • If so, please let others know about Composr whenever you see the opportunity or support me on Patreon.
  • If my reply is too Vulcan or expressed too much in business-strategy terms, and not particularly personal, I apologise. As a company & project maintainer, time is very limited to me, so usually when I write a reply I try and make it generic advice to all readers. I'm also naturally a joined-up thinker, so I always express my thoughts in combined business and technical terms. I recognise not everyone likes that, don't let my Vulcan-thinking stop you enjoying Composr on fun personal projects.
  • If my response can inspire a community tutorial, that's a great way of giving back to the project as a user.
Online now: No Back to the top

Post

Posted
Rating:
#3224
Avatar
Site staff
enelson is in the usergroup ‘Super-moderators’
Hi Chris thanks for the response.
I uploaded the files to /sources_custom and ../modules_custom directories.
Unfortunately it's isn't working as the module still tries to find a "news" page in the articles zone (am wondering what will happen if I creat a "news" page and redirect the module here). However there's an improvement: If I manually input what is supposed to be the correct redirected URL the article is displayed as supposed to outputting an error as it did before.

I can remove the redirects and use the default schemes if it's a bother, although I've sent you access details for the site if you could have a look.
Online now: No Back to the top

Post

Posted
Rating:
#3229
Avatar
Site director
Chris Graham is in the usergroup ‘Administrators’
Ok, basically I forgot to send a changed main_news.php too.
All these fixes will be in the next patch release.


Become a fan of Composr on Facebook or add me as a friend. Add me on on Mastodon. Follow me on Minds (where I am most active). Support me on Patreon

Was I helpful?
  • If not, please let us know how we can do better (please try and propose any bigger ideas in such a way that they are fundable and scalable).
  • If so, please let others know about Composr whenever you see the opportunity or support me on Patreon.
  • If my reply is too Vulcan or expressed too much in business-strategy terms, and not particularly personal, I apologise. As a company & project maintainer, time is very limited to me, so usually when I write a reply I try and make it generic advice to all readers. I'm also naturally a joined-up thinker, so I always express my thoughts in combined business and technical terms. I recognise not everyone likes that, don't let my Vulcan-thinking stop you enjoying Composr on fun personal projects.
  • If my response can inspire a community tutorial, that's a great way of giving back to the project as a user.
Online now: No Back to the top

Post

Posted
Rating:
#3644
Avatar
Site staff
enelson is in the usergroup ‘Super-moderators’

Hi Chris, am trying to implement the redirect on another installation and am having this issue:
The news category listing in a news entry screen and the news category page try to view the posts for their specified category in a posts/news
 page. The zone am using for the redirect is "posts" with a default page  "post".
Apart from this, everything else is okay, eg. the news category screen redirects properly when clicking on links from the new_category block.

I supposed the bugfixes (via the files you'd uploaded where implemented in future version releases, so I didn't upload those files.

Last edit: by enelson

Online now: No Back to the top

Post

Posted
Rating:
#3653
Avatar
Site staff
enelson is in the usergroup ‘Super-moderators’

.
Online now: No Back to the top

Post

Posted
Rating:
#3655
Avatar
Site director
Chris Graham is in the usergroup ‘Administrators’
I have about 8 topics on my reply-list at the moment, including this - I should get to it this week.


Become a fan of Composr on Facebook or add me as a friend. Add me on on Mastodon. Follow me on Minds (where I am most active). Support me on Patreon

Was I helpful?
  • If not, please let us know how we can do better (please try and propose any bigger ideas in such a way that they are fundable and scalable).
  • If so, please let others know about Composr whenever you see the opportunity or support me on Patreon.
  • If my reply is too Vulcan or expressed too much in business-strategy terms, and not particularly personal, I apologise. As a company & project maintainer, time is very limited to me, so usually when I write a reply I try and make it generic advice to all readers. I'm also naturally a joined-up thinker, so I always express my thoughts in combined business and technical terms. I recognise not everyone likes that, don't let my Vulcan-thinking stop you enjoying Composr on fun personal projects.
  • If my response can inspire a community tutorial, that's a great way of giving back to the project as a user.
Online now: No Back to the top

Post

Posted
Rating:
#3684
Avatar
Site director
Chris Graham is in the usergroup ‘Administrators’


Become a fan of Composr on Facebook or add me as a friend. Add me on on Mastodon. Follow me on Minds (where I am most active). Support me on Patreon

Was I helpful?
  • If not, please let us know how we can do better (please try and propose any bigger ideas in such a way that they are fundable and scalable).
  • If so, please let others know about Composr whenever you see the opportunity or support me on Patreon.
  • If my reply is too Vulcan or expressed too much in business-strategy terms, and not particularly personal, I apologise. As a company & project maintainer, time is very limited to me, so usually when I write a reply I try and make it generic advice to all readers. I'm also naturally a joined-up thinker, so I always express my thoughts in combined business and technical terms. I recognise not everyone likes that, don't let my Vulcan-thinking stop you enjoying Composr on fun personal projects.
  • If my response can inspire a community tutorial, that's a great way of giving back to the project as a user.
Online now: No Back to the top

Post

Posted
Rating:
#3692
Avatar
Site staff
enelson is in the usergroup ‘Super-moderators’
The fix did the job!
Thank you.
Online now: No Back to the top
1 guest and 0 members have just viewed this.

Statistics

Forum statistics:
  • 2,052 topics, 7,195 posts, 10,830 members
  • Our newest member is Customcollective
Back to Top