Is there any way to have all the categories a link is in listed on the modify form but not allow the User to select/change any of the categores?
Jul 22, 2002, 4:26 PM
Veteran / Moderator (2577 posts)
Jul 22, 2002, 4:26 PM
Post #2 of 14
Views: 2866
Yes.
You can add a tag which shows which category each link belongs to inside of the modify select loop.
<%loop link_results_loop%>
<%showcat,$ID%> <<<You need to write the global, see below
blah blah
<%endloop%>
In the modify_select.html template you can also use <%ID%> to return the ID of each link as it appears in the select loop.
There is an explaination of how to write a global to return the category for a particular link in the RESOURCE section under GLOBALS.
http://www.iuni.com/...tware/web/index.html
Links Plugins
You can add a tag which shows which category each link belongs to inside of the modify select loop.
<%loop link_results_loop%>
<%showcat,$ID%> <<<You need to write the global, see below
blah blah
<%endloop%>
In the modify_select.html template you can also use <%ID%> to return the ID of each link as it appears in the select loop.
There is an explaination of how to write a global to return the category for a particular link in the RESOURCE section under GLOBALS.
http://www.iuni.com/...tware/web/index.html
Links Plugins
Jul 22, 2002, 7:08 PM
Veteran / Moderator (2577 posts)
Jul 22, 2002, 7:08 PM
Post #4 of 14
Views: 2872
Jul 23, 2002, 7:43 AM
Enthusiast (582 posts)
Jul 23, 2002, 7:43 AM
Post #6 of 14
Views: 2866
I tried this a couple different ways, including putting this into the link.html (I'm trying to see if it'll list all the categories the link is in on the search_results.):
<%if query%>
<a class="mainfontb" target="_blank" href="<%db_cgi_url%>/jump.cgi?ID=<%ID%>"><%Title%></a>
Category: <%link_category_id%>
<%else%>
<%loop link_results_loop%>
<%showcat,$ID%>
<a class="mainfontb" target="_blank" href="<%db_cgi_url%>/jump.cgi?ID=<%ID%>"><%Title%></a>
<%endloop%>
<%endif%>
But all I get is a repeat of the category it originally comes up in. (all that globals seems to do is put the category in the link...I'd like all the categories that link belongs to to be listed)
<%if query%>
<a class="mainfontb" target="_blank" href="<%db_cgi_url%>/jump.cgi?ID=<%ID%>"><%Title%></a>
Category: <%link_category_id%>
<%else%>
<%loop link_results_loop%>
<%showcat,$ID%>
<a class="mainfontb" target="_blank" href="<%db_cgi_url%>/jump.cgi?ID=<%ID%>"><%Title%></a>
<%endloop%>
<%endif%>
But all I get is a repeat of the category it originally comes up in. (all that globals seems to do is put the category in the link...I'd like all the categories that link belongs to to be listed)
Jul 23, 2002, 7:46 AM
Veteran / Moderator (2199 posts)
Jul 23, 2002, 7:46 AM
Post #7 of 14
Views: 2870
If you set "db_gen_category_list" to "No", then this will be automatic.
Ivan
-----
Iyengar Yoga Resources / GT Plugins
Ivan
-----
Iyengar Yoga Resources / GT Plugins
Jul 23, 2002, 8:11 AM
Veteran / Moderator (2199 posts)
Jul 23, 2002, 8:11 AM
Post #9 of 14
Views: 2869
Jul 23, 2002, 8:18 AM
Veteran / Moderator (2199 posts)
Jul 23, 2002, 8:18 AM
Post #11 of 14
Views: 2834
In "Database -> Links -> Add/Modify", you will have to enter the full path name yourself, there will be no select field.
You can still have it by hacking line 478 of Links/Link.pm, just put if (1) instead of if ($CFG->{...}) )
Ivan
-----
Iyengar Yoga Resources / GT Plugins
You can still have it by hacking line 478 of Links/Link.pm, just put if (1) instead of if ($CFG->{...}) )

Ivan
-----
Iyengar Yoga Resources / GT Plugins
Jul 23, 2002, 8:26 AM
Veteran / Moderator (2199 posts)
Jul 23, 2002, 8:26 AM
Post #13 of 14
Views: 2829
OK, I have a modified module Links/User/Modify.pm, which I will send you by PM. It's tested a bit, but if you could test it even more, you're welcome....
Ivan
-----
Iyengar Yoga Resources / GT Plugins
Ivan
-----
Iyengar Yoga Resources / GT Plugins