Gossamer Forum
Home : Products : Gossamer Links : Discussions :

Entry has no URL, how to disable creating link?

Quote Reply
Entry has no URL, how to disable creating link?
Hi,

some entries I'm going to put into my GLinks don't have a URL. Is there a workaround having links not created?

I thought of creating a new column like "has_url" with a drop-down box to select from "yes" and "no"
and put something like:

Code:
<%if has_url%><a href="<%config.db_cgi_url%>/jump.cgi?ID=<%ID%>">die Webseite des Eintrags besuchen</a><%endif%>


in the detailed template.

As I don't want to mess up something I'm going to ask:

1.
  • I'll create a new colum with name "has_url"
  • Type: "ENUM"
  • Column Index: "Regular"
  • Values "Yes" and "No"
  • Not Null: "Yes"
  • Default: "Yes"
  • Form Display "has_url"
  • Form Type "SELECT"
  • Form Size 0
  • File Save Method "HASHED"
  • Everything else will be empty
2. What's the correct code to hide every url that has been set to "No"?

Greetings,
Sven

Last edited by:

sun112: Jan 4, 2007, 4:27 AM
Quote Reply
Re: [sun112] Entry has no URL, how to disable creating link? In reply to
Blank URLs should have http:// added as default when links are added.

Use the code in the original links.html template and it will not add a link for records with only http:// in the URL

Last edited by:

Alba: Jan 4, 2007, 5:49 AM