help to better help you:
Please: add always Joomla / JEM version and details to your posts, so we can try to reproduce your issue!
deactivated event and status code
deactivated event and status code
6 years 11 months ago
Hi everyone
When I deactivate or delete an event and then visit the (former) link to the detailed view I get an error message "Error. You are not authorised to view this resource." BUT I still get the satus code 200 OK in the response header.
I would like to get an 404 error header (Otherwise the links to the old events stay in the earch engines).
How can I do that?
thanks and greetings
When I deactivate or delete an event and then visit the (former) link to the detailed view I get an error message "Error. You are not authorised to view this resource." BUT I still get the satus code 200 OK in the response header.
I would like to get an 404 error header (Otherwise the links to the old events stay in the earch engines).
How can I do that?
thanks and greetings
Happy with the support?
Consider a donation: www.joomlaeventmanager.net/project/donate
– We are all volounteers, investing time and money to keep JEM runnung and evolving, With your donation we cover our expenses –
Thank you.
Consider a donation: www.joomlaeventmanager.net/project/donate
– We are all volounteers, investing time and money to keep JEM runnung and evolving, With your donation we cover our expenses –
Thank you.
Please Log in or Create an account to join the conversation.
Re: deactivated event and status code
6 years 10 months ago
OK, I found the line where it is generated:
in /components/com_jem/views/event/view.html.php on line 141 I found:
Even if there seems that the output should to be an 403 error, I still geht the status "200 OK" in the response header.
When I add a line
under line 141
then I get the correkt response header (403).
So why doesn't it work with the line JError::raiseError(403, JText::_('JERROR_ALERTNOAUTHOR'));?
(or is it a general joomla issue?)
in /components/com_jem/views/event/view.html.php on line 141 I found:
Code:
JError::raiseError(403, JText::_('JERROR_ALERTNOAUTHOR'));
When I add a line
Code:
header("HTTP/1.1 403 Forbidden");
then I get the correkt response header (403).
So why doesn't it work with the line JError::raiseError(403, JText::_('JERROR_ALERTNOAUTHOR'));?
(or is it a general joomla issue?)
Happy with the support?
Consider a donation: www.joomlaeventmanager.net/project/donate
– We are all volounteers, investing time and money to keep JEM runnung and evolving, With your donation we cover our expenses –
Thank you.
Consider a donation: www.joomlaeventmanager.net/project/donate
– We are all volounteers, investing time and money to keep JEM runnung and evolving, With your donation we cover our expenses –
Thank you.
Please Log in or Create an account to join the conversation.
Re: deactivated event and status code
6 years 10 months ago
Hey,
I am sorry, I can not answer to your question.
But I think its not important to think about JError, because it does not exist in Joomla 4 anymore, so sooner or later we need to replace JError messages anyway.
I am sorry, I can not answer to your question.
But I think its not important to think about JError, because it does not exist in Joomla 4 anymore, so sooner or later we need to replace JError messages anyway.
The following user(s) said Thank You: hekla
Please Log in or Create an account to join the conversation.
Re: deactivated event and status code
6 years 10 months ago
Ok, thank you.
I posted it also in the Joomla Forum at joomla.org with the question "general joomla issue or not?"
I posted it also in the Joomla Forum at joomla.org with the question "general joomla issue or not?"
Happy with the support?
Consider a donation: www.joomlaeventmanager.net/project/donate
– We are all volounteers, investing time and money to keep JEM runnung and evolving, With your donation we cover our expenses –
Thank you.
Consider a donation: www.joomlaeventmanager.net/project/donate
– We are all volounteers, investing time and money to keep JEM runnung and evolving, With your donation we cover our expenses –
Thank you.
Please Log in or Create an account to join the conversation.
Time to create page: 0.839 seconds