Hi
for some reason custom fields are not showing in details page, also main fields are showing even though empty, how can I show only filled fields (both main and custom)?
Thanx in advance
Hani
Hi
for some reason custom fields are not showing in details page, also main fields are showing even though empty, how can I show only filled fields (both main and custom)?
Thanx in advance
Hani
For custom field, you need to put the field name in detail_link.html fileTo show only filled fields, for example descriptionCode:<%$field_name%>Code:<%if $description%> <%$description%><%/if%>
Thanx
First part worked great
second part, no, Empty fields still show
By the way, can I have a field with a default value? the link field in particular, lots of added info dont have a website, so I want mine to be the default, so they dont have to enter it if they dont have a site.
Perhaps i'm not understand with your question, but try this:
Code:<%if $description%> <%$description%> <%else%> It's default description <%/if%>
Still, I want the whole field (even field name) not to show if ts empty,
exsample, I have the name, the link and the phone number filled but not the fax nor the email
Detail page should show only name, link and phone number.
I hope it's more clear. Below will show all (but not as you desire)
Below to hide not filled fieldCode:Name: <%$name%> Link: <%$link%> Phone: <%$phone%> Fax: <%$phone%>
I hope you can understand the logical thing how the template work here.Code:<%if $name%>Name: <%$name%><%/if%> <%if $link%>Link: <%$link%><%/if%> <%if $phone%>Phone: <%$phone%><%/if%> <%if $phone%>Fax: <%$phone%><%/if%>
in your code its so plain, in detail_link.html it comes with a tr/td, so I guess your code will hide the field name but will keep the row, while I want to not show the row
I remove unnecessary html codes like <p> or <tables>, i just want to ilustrate how it work. Of course in real, you need to put html codes too.![]()
do you meansomething ike this?
Code:<%if $contact_name%> <tr class=tbl_normal> <td>contact_name</td> <td><%$contact_name%></td> </tr><%/if%>
Last edited by hdraye; 07-16-2006 at 09:46 AM.
Yes.
Code:<%if $contact_name%> <tr class=tbl_normal> <td>Contact Name</td> <td><%$contact_name%></td> </tr><%/if%>
great
Thanx
now, input field when submetting a link, can we have the link optional, if not have a default value?
Thanx again
Hani
You need to hack add.php for required fields and default value. For custom fields, you can manage it in admin panel > database > alter. There you'll find default value, required, and searchable option.
Thanx a million, I am going for the unlimited licence, this is great, only if dmoz can parse arabic, then I'll dance
regards
Hani
If you have dmoz extractor license, you can request us to parse the arabic
Yes I have a DMOZ Ext. license, and infact I have a ticket in this regard