Want to add link to 1 column whilst using sql data
Want to add link to 1 column whilst using sql data
tgcowell
Posts: 2Questions: 0Answers: 0
Currently have a SQL db providing the data for my table. I want to add a link to 1 of the columns which will us the id column within the SQL db to send the user to a new page.
Below is my HTML markup:
[code]
Hospital Name
State
Status
Loading Data
Hospital Name
State
Status
[/code]
Now the Javascript
[code]
$(document).ready(function() {
$('#projects').dataTable( {
"bProcessing": true,
"bServerSide": true,
"sAjaxSource": "includes/server_processing_projects.php"
});
});
[/code]
I want the link on the Hospital Name Column and the link to be like this
[code]Hospital Name[/code]
I'm new to web development and very much learning as I go, I've looked online regarding the mRender and mData which seem to be the solution... But I cannot figure out how it all works.
There was also a post on fnRender which appears to no longer be in use, since upgrading the 1.9?
Appreciate any assistance with this issue!
Thanks
Tim
Below is my HTML markup:
[code]
Hospital Name
State
Status
Loading Data
Hospital Name
State
Status
[/code]
Now the Javascript
[code]
$(document).ready(function() {
$('#projects').dataTable( {
"bProcessing": true,
"bServerSide": true,
"sAjaxSource": "includes/server_processing_projects.php"
});
});
[/code]
I want the link on the Hospital Name Column and the link to be like this
[code]Hospital Name[/code]
I'm new to web development and very much learning as I go, I've looked online regarding the mRender and mData which seem to be the solution... But I cannot figure out how it all works.
There was also a post on fnRender which appears to no longer be in use, since upgrading the 1.9?
Appreciate any assistance with this issue!
Thanks
Tim
This discussion has been closed.
Replies