joejac
Posts: 242
|
| Posted: 10/09/2007, 10:06 AM |
|
Hello,
1.- I have a table for page links with 2 fields:
page_no and page_name
page_no=1 => page_name= No Page
page_no=X => page_name= pageX.php
2.- I have a title field from articles table that has a link that goes to the corresponding page_name for the article. Now the link goes to page_name very well except when page_no=1 ("No Page")
3. Question: How can I filter or condition the link so:
If page_no=1 It do not place the hyperlink on the title because there is no page, and allow the link if page_no= is different than "1", because it will have a page to go.
If requires php code on an event I would appreciated if the code can be provided.
Thanks a lot
joejac
|
 |
 |
aondecker
Posts: 58
|
| Posted: 10/11/2007, 6:47 AM |
|
I would place both a link and an label in the title field and set the link visible property to "Dynamic".
Then in your before show code put
if (page_no ==1)
{
link->show = false;
label1->setvalue("PAGE 1") (or whatever you want it to say)
}
else
{
link->show = true;
link->setlink(destinationpage.php)
link->settext("LInk text")
label1->setvalue = "";
}
|
 |
 |
|