Invoke dynamic item page when the item is selected in a table on dynamic category page

I have a dynamic category page which displays items in a table from the connected collection. When I click on an item in the table I want to display the item in the associated dynamic item page. The default Title field is the primary key. The dynamic url of the item page is /ashgr-website-readiness/{Title}. See attached screenshot.

The Title field is a text field with values 01, 02, 03, etc.

There is an onRowSelect handler when a row in the dynamic category table is clicked:
export function tableTasks_rowSelect(event) {
let currItem = event.rowData;
let Title = currItem.title; //field value

	console.log( "Title: "  + Title);  //02 
	wixLocation.to( "/ahsgr-website-readiness/Title" ); 

}

The problem is when I run this I get an 404 page not found error? So, what’s wrong with this URL?
NOTE: if I hard code the URL /ahsgr-website-readiness/02 the dynamic item page displays item 02 just fine.

NOTE: I have also tried the URL //ahsgr-website-readiness/{Title} which provides the same 404 error.

export function tableTasks_rowSelect(event) {
 	let currItem = event.rowData;
	 let Title = currItem.title;  //field value

    	console.log("Title: " + Title);  //02
    	wixLocation.to(currItem['FIELD_KEY_OF_YOUR_DYNAMIC_PAGE']);
}

Assume other parts of your code is correct.


You should see a field like this. The field key for dynamic page of my database is ‘link-o-line-circular-1-title’

wixLocation.to( “/ahsgr-website-readiness/Title” )

This is wrong because the ‘Title’ inside the “” is static. The title won’t replace by your current item title.

Problem solved. This works wixLocation.to( “/ahsgr-website-readiness/” + currItem[ ‘title’ ]);

Thanks for the help!!!