Home News Contact Us Forum About Us Demos Products F.A.Q.
Shopping Cart
You currently have 0 items in your cart.


Recent Events
  • 31/12/2023 New Year SALE

    We are glad to announce New Year SALE. 25% discount for all our extensions. Use NY24 coupon code. Hurry up the discount is valid till 7 January.

  • 21/11/2023 BLACK FRIDAY 23 is coming

    BIG SALE, 35% discount for all our extensions. Use BF23 coupon code. Hurry up the discount is valid till 27 November.


2Checkout.com, Inc. is an authorized retailer of goods and services provided by ARI Soft. 2CheckOut




Follow us on twitter



Welcome, Guest
Please Login or Register.    Lost Password?

create link with non-column data
(1 viewing) (1) Guest
Go to bottomPage: 1
TOPIC: create link with non-column data
#8457
create link with non-column data 13 Years, 5 Months ago Karma: 0
To create a link from a column in my table to a details view of the row, I need to reference the id field of the row - but I don't want to show it as part of the table (since the internal id doesn't mean anything in customer terms).

For example, my table has three columns: title, author, series. From the title I'd like to link to another page that contains a form that shows all the info about the object summarized by the row. To create that link I need to reference the id field in the database for that row. But I definitely don't want to make the id one of the columns.

Is this possible? How would I do it?

Thanks in advance, Peter
The administrator has disabled public write access.
 
#8465
Re:create link with non-column data 13 Years, 5 Months ago Karma: 748
Hello,

You can use the following approach:

1. Create SQL query which will look like:

Code:


SELECT
  title, author, series, row_id
....



2. Use "Columns settings -> Columns settings" parameter and populate it with the following values:

ID=row_id
Alias=Details
Format=<a href="index.php?option=com_mycomponent&row_id={$value}">View</a>

Just place necessary link to component which display rows details in "href" attribute of anchor in "Format" parameter. Use {$value} predefined variable as row ID.

Regards,
ARI Soft
The administrator has disabled public write access.
 
#8478
Re:create link with non-column data 13 Years, 5 Months ago Karma: 0
Thanks for the reply. I may use that idea, but it doesn't generalize. In the future I'll probably want to link from the Book to the details about the Book and from the Author to details about the Author. Having multiple extra columns for the links isn't very elegant. Given how easy it is to use ARI Data Tables (because the SQL gets used to determine the columns), I realize that this is a reasonable limitation in general. It just doesn't cover my specific use case.
The administrator has disabled public write access.
 
#8479
Re:create link with non-column data 13 Years, 5 Months ago Karma: 748
We'll add possibility to set "hidden" status for column(s) in a future release. This ability helps to use hidden fields in "Format" parameter, but these columns will not be shown in table on frontend.

Regards,
ARI Soft
The administrator has disabled public write access.
 
Go to topPage: 1