×

Notice

The forum is in read only mode.
Welcome, Guest
Username: Password: Remember me
  • Page:
  • 1
  • 2

TOPIC: Incorrect URLS

Incorrect URLS 15 years 2 months ago #6521

  • JonusC
  • JonusC's Avatar
  • Offline
  • Platinum Boarder
  • Platinum Boarder
  • Posts: 785
  • Thank you received: 48
I've never tried the manual moderation system before so bear with me. Which URL is incorrect? After you approve the comment in the backend, the user who made the comment gets a 'Comment approved' E-Mail - correct? And in this E-Mail, there is text such as "Your comment has been approved by the administrators and is now published - click here to see {link}" < and that is the link that's incorrect...?

What makes you think it's sh404SEF...? It probably is haha but i'm curious as to what the "incorrect link" looks like - and what it should look like.

I'll do some tests and see if I can track it down. Could you also answer a couple of things for me -

1) Which version of sh404SEF do you have installed?
2) Which version of JoomlaComment installed?
3) Do you have the 'livesite' variable set in Joomla?
4) Are you using mod_rewrite and .htaccess mode of SEO-address generation? Are you using a modified .htaccess file?

Thanks tomas :)

EDIT:
5) Is your site installed on localhost (not online yet)? Or in a top-level domain root (website.com) or is Joomla installed in a subfolder (website.com/myblog)

Incorrect URLS 15 years 2 months ago #6555

  • tomas
  • tomas's Avatar Topic Author
  • Offline
  • Fresh Boarder
  • Fresh Boarder
  • Posts: 12
  • Thank you received: 0
Hi Jonus,

thank you for your reply an interest to help. Here are the answers to your questions:
> Which URL is incorrect?
When a comment is aprroved via admin back-end, !joomlacomment sends an email to the original writer of the comments and this URL is incorrect.
The URL looks like this: index.php?option=com_content&view=article&id=0&Itemid=51&joscclean=1&comment_id=6#josc6

since I'm using sh404SEF ( SEF LINKS ) it does no get translated into proper SEF URL.

However, the URL which I receive ( as an admin ) about new comment posted and to be approved is correct and it looks like this ( example ) :
codeweavers-releases-crossover-games-80-for-mac-and-linux-adds-support-for-snow-leopard-os?comment_id=6&joscclean=1#josc6

>What makes you think it's sh404SEF...?
Well that is just my first guess because I believe that if I turn off sh404SEF and got with natural joomla URLs the link:
index.php?option=com_content&view=article&id=0&Itemid=51&joscclean=1&comment_id=6#josc6
would be rendered as valid. It seems to me that to link between sh404SEF and joomlacomment is missing.


1) Which version of sh404SEF do you have installed?
1.0.19_Beta - build_232 - Joomla 1.5.x -
2) Which version of JoomlaComment installed?
!JoComment 4.0 beta1 by Compojoom.com
3) Do you have the 'livesite' variable set in Joomla?
yes I do and I'm sure that it is correct
4) Are you using mod_rewrite and .htaccess mode of SEO-address generation?
SEO Settings
Search Engine Friendly URLs No
Use Apache mod_rewrite Yes
Add suffix to URLs No
Are you using a modified .htaccess file? it's original I have just add couple permanent redirects but it has no affect on the above described behavior of joomlacomment
5) Is your site installed on localhost (not online yet)? Or in a top-level domain root (website.com) or is Joomla installed in a subfolder (website.com/myblog)
www.linuxconfig.org/

hopefully I have answered your questions. If not please do not hesitate to ask again.

thank you

lubos

Incorrect URLS 15 years 2 months ago #6556

  • JonusC
  • JonusC's Avatar
  • Offline
  • Platinum Boarder
  • Platinum Boarder
  • Posts: 785
  • Thank you received: 48
Hey thanks for answering all my questions there :)

I think it must be a bug in JoomlaComment - we have to make that last 'Comment approved' notification aware of SEF like the other E-Mails are.

It might have been updated in beta 2, i'm not sure. Is there a reason why you havn't installed the newest JoomlaComment?

Lastly, is there a reason you also have livesite set? The default is to be blank, which should work for 99% of standard Joomla installs that are not in a subdirectory on the webhost. I remember reading a thread sometime back that having livesite assigned can cause problems but i'm not sure. If you can afford to test that it might be worth a try :)

I will try and replicate your problem to confirm the bug and post here with code changes to make youself.

Incorrect URLS 15 years 2 months ago #6581

  • tomas
  • tomas's Avatar Topic Author
  • Offline
  • Fresh Boarder
  • Fresh Boarder
  • Posts: 12
  • Thank you received: 0
Hi Jonus,

>It might have been updated in beta 2, i'm not sure. Is there a >reason why you havn't installed the newest JoomlaComment?
NO, I have updated to beta2 but it did not fix the problem

>Lastly, is there a reason you also have livesite set?
I must have add it there at the beginning. I have set that variable to blank but it did not help to fix this problem.

>I will try and replicate your problem to confirm the bug and post >here with code changes to make youself.

thanks

lubos

Incorrect URLS 15 years 2 months ago #6878

  • tomas
  • tomas's Avatar Topic Author
  • Offline
  • Fresh Boarder
  • Fresh Boarder
  • Posts: 12
  • Thank you received: 0
Hi,

I'm just wondering if I can help more to solve this problem. Or there is nothing that can be done?

thanks

Incorrect URLS 15 years 1 month ago #6952

  • JonusC
  • JonusC's Avatar
  • Offline
  • Platinum Boarder
  • Platinum Boarder
  • Posts: 785
  • Thank you received: 48
Hi Tomas,

Sorry, no updates yet. Daniel has been working hard on some major code changes lately and i've been away from home, but we won't forget :)

Incorrect URLS 15 years 1 week ago #7834

  • tomas
  • tomas's Avatar Topic Author
  • Offline
  • Fresh Boarder
  • Fresh Boarder
  • Posts: 12
  • Thank you received: 0
hi guys,

any updates yet? It is really getting annoying as always wrong URL is being sent. Could you at least point me where the problem is, perhaps I would be able to fix it my self

thank you

Incorrect URLS 14 years 11 months ago #8186

  • JonusC
  • JonusC's Avatar
  • Offline
  • Platinum Boarder
  • Platinum Boarder
  • Posts: 785
  • Thank you received: 48
Not as far as I know, I've been away for a while... maybe you can test out the new Alpha to see if it's fixed?

Incorrect URLS 14 years 8 months ago #9112

  • tomas
  • tomas's Avatar Topic Author
  • Offline
  • Fresh Boarder
  • Fresh Boarder
  • Posts: 12
  • Thank you received: 0
Hi JonusC,

I have updated to a new joomlacomment4.0.0RC1 version and here are some problems which occurred:
1. Incorrect URLS
The URL sent as a notification was in format:
index.php?option=com_content&view=article&id=0&Itemid=51&joscclean=1#josc137

NOTE: id=0 !! not sure why? the proper URL should be:

index.php?option=com_content&view=article&id=391&joscclean=1&comment_id=137#josc137

as this URL works when clicked from joomla administration back-end.

2. All comments lost its formating. I looks likethat the new version does not take new line characters into the consideration so everything is in one single bloch which is one line.

3. Even I have disable notification the new version of !JoomlaComment did not removed the drop down menu. Drop down menu is there and it is empty. Not a major bug but I thought I will mention it.

Due to this problems I was forced to downgrade to previous version...

Let me know your thoughts..!! Do not hesitate to contact me if more info is required...!

thanks

Incorrect URLS 14 years 8 months ago #9122

  • Daniel Dimitrov
  • Daniel Dimitrov's Avatar
  • Offline
  • Administrator
  • Administrator
  • Posts: 9618
  • Karma: 155
  • Thank you received: 1081
tomas which joomlacomment template are you using? Do you have ubbcode turned on?

The only available template with RC1 is the modern one and everyone should use it for the moment.

Incorrect URLS 14 years 8 months ago #9137

  • tomas
  • tomas's Avatar Topic Author
  • Offline
  • Fresh Boarder
  • Fresh Boarder
  • Posts: 12
  • Thank you received: 0
Hi Daniel,

with the formating I had to turn on ubbcode to make it work.

I have again tested notification and ti still does not work:

Comment URL which appears in the joomla administration back-end is:

index.php?option=com_content&view=article&id=413&joscclean=1#josc143

The actual URL of the comment on my website is:
my-sef-links-in-use?joscclean=1#josc143

both of this links works ! However the link which is sent as a notification when clicked on publish button in the administration mode is in format:

index.php?option=com_content&view=article&id=0&Itemid=51&joscclean=1#josc143

and it does not work...!! NOTE id=0 in the body of the link?!?

I had to disable notification and the new version of !JoomlaComment did not removed the drop down menu for notifications. Drop down menu is there and it is empty. Not a major bug but I thought I will mention it again.

Incorrect URLS 14 years 8 months ago #9138

  • Daniel Dimitrov
  • Daniel Dimitrov's Avatar
  • Offline
  • Administrator
  • Administrator
  • Posts: 9618
  • Karma: 155
  • Thank you received: 1081
Notifications sent through the backend have a wrong id???

The notifications from frontend look right?

Did I understand this correct?

Incorrect URLS 14 years 8 months ago #9155

  • tomas
  • tomas's Avatar Topic Author
  • Offline
  • Fresh Boarder
  • Fresh Boarder
  • Posts: 12
  • Thank you received: 0
Hi,

when I receive an email that I need to approve some comment the URL is correct. When I approve the command from a Joomla administration backend and email is sent to the the person however the URL is wrong.

so:

Notifications sent through the backend have a wrong id???
YES
The notifications from frontend look right?
YES

Incorrect URLS 14 years 8 months ago #9164

  • Daniel Dimitrov
  • Daniel Dimitrov's Avatar
  • Offline
  • Administrator
  • Administrator
  • Posts: 9618
  • Karma: 155
  • Thank you received: 1081
cool, now I understand what you mean. I will have to test it first to confirm.

Up until then you can use the checkbox and the publish button from the pane. It won't send a notification to the user.

Incorrect URLS 14 years 8 months ago #9179

  • tomas
  • tomas's Avatar Topic Author
  • Offline
  • Fresh Boarder
  • Fresh Boarder
  • Posts: 12
  • Thank you received: 0
OK, let me know if you need more info...

In regards to:
The notifications from frontend look right?
YES
the notification I'm talking about is the one which I receive when someone posts a comment and I need to approve it. Jus to make it clear that we are on the same page...

Incorrect URLS 14 years 8 months ago #9205

  • tomas
  • tomas's Avatar Topic Author
  • Offline
  • Fresh Boarder
  • Fresh Boarder
  • Posts: 12
  • Thank you received: 0
Update:

when Published (notify-writer) button ( administration back-end ) is clicked on certain comment the "PublishedComment" email is sent with link which includes id=0. When this link is clicked the user is redirected to a main page.

Incorrect URLS 14 years 7 months ago #9470

  • tomas
  • tomas's Avatar Topic Author
  • Offline
  • Fresh Boarder
  • Fresh Boarder
  • Posts: 12
  • Thank you received: 0
hi guys,

it is already 7 months since a posted my problem here an yet is is still not resolved. I'm keen to collaborate to resolve this problem. I'm just wondering if it is sensible to wait or rather switch as at the moment this is taking a direction where patience is not good enough.

thank you

Incorrect URLS 14 years 7 months ago #9472

  • Daniel Dimitrov
  • Daniel Dimitrov's Avatar
  • Offline
  • Administrator
  • Administrator
  • Posts: 9618
  • Karma: 155
  • Thank you received: 1081
I'll check it this afternoon, I promise!

Incorrect URLS 14 years 7 months ago #9475

  • Daniel Dimitrov
  • Daniel Dimitrov's Avatar
  • Offline
  • Administrator
  • Administrator
  • Posts: 9618
  • Karma: 155
  • Thank you received: 1081
Damn it. This was more complicated than expected.
I think that I made a fix - at least the links are pointing to the right comment, but they are not SEF. I use the jroute function, but it is not generating friendly urls from the backend. Perhaps 404sef will fix this.

open
administrator/components/com_comment/plugin/com_content/josc_com_content.class.php
go to the setRowDatas function and change it with this version:
	public function setRowDatas(&$row) {
		/* when sending e-mails the urls are not sef encoded
		 * this is why we need this query
		*/
		if (!$row) {
			$db = JFactory::getDBO();
			$cid = JRequest::getVar('cid', array(), 'post', 'array');
			$where = '';
 
			if(JRequest::getInt('content_id')) {
				$where = ' a.id = ' . JRequest::getInt('content_id');
			}
 
			if(count($cid)){
				if(count(($cid))) {
					$query = 'SELECT contentid FROM jos_comment WHERE id = ' . $cid[0];
					$db->setQuery($query);
					$contentID = $db->loadObject();
					$where = ' a.id =' . $contentID->contentid;
				}
			}
			$query = 'SELECT a.*,
                        CASE
                            WHEN CHAR_LENGTH(a.alias)
                            THEN CONCAT_WS(":", a.id, a.alias)
                            ELSE a.id END as slug,
                        CASE WHEN CHAR_LENGTH(cc.alias) THEN CONCAT_WS(":", cc.id, cc.alias)
                            ELSE cc.id END as catslug FROM jos_content AS a
                        LEFT JOIN jos_categories AS cc ON cc.id = a.catid
                        LEFT JOIN jos_sections AS s ON s.id = cc.section AND s.scope = "content"
                        LEFT JOIN jos_users AS u ON u.id = a.created_by
                        WHERE '. $where;	
			$db->setQuery($query);
			$row = $db->loadObject();
		}
		$this->_route_sectionid 	= isset($row->sectionid) ? $row->sectionid : 0;
		$this->_route_catid 		= isset($row->catslug) ? $row->catslug : (isset($row->catid) ? $row->catid : 0) ;
		$this->_route_slug			= isset($row->slug) ? $row->slug  : (isset($row->id) ? $row->id : 0);
		$this->_title           = isset($row->title) ? $row->title : 0;  // Part of Feature #79
	}
 

of course make a backup of the function before this.

Incorrect URLS 14 years 7 months ago #9548

  • tomas
  • tomas's Avatar Topic Author
  • Offline
  • Fresh Boarder
  • Fresh Boarder
  • Posts: 12
  • Thank you received: 0
HI Daniel,

Great it seems to be working :-)) I did couple tests and no problem. Will test it for couple more weeks and see if there are any issues after applying this fix and if anything I will let you know.

The links which are generated are not SEF but at least they are accessible and are pointing to the right direction.

BTW is there any ption to make "notify" option default as oppose to "Do not Notify".

thank you very much...
  • Page:
  • 1
  • 2
Time to create page: 0.154 seconds