Gossamer Forum
Home : Products : Links 2.0 : Discussions :

Removing Hyperlink

Quote Reply
Removing Hyperlink
Hi,
Does anyone know if you can disable the hyperlink function for some links, but have it work for others?

I am creating a local directory, and some of the businesses signing up do not have websites, but I still want to include them in our directory without disabling the hyperlinks for those that do have websites.

Also, my Links system was installed for me by my former web host, who is now no longer. Does anyone know where I can get the readme file, and or any other information about this script.

Thanks,
RJ
Quote Reply
Re: [RJLee] Removing Hyperlink In reply to
The readme does not have much in it, there is more info available through the admin page. For the link switch mod, you can try the one attached. (It's a text file.)


Leonard
aka PerlFlunkie
Quote Reply
Re: [PerlFlunkie] Removing Hyperlink In reply to
You could set up one html page with something like "Website Not Available" on it. You could then use the URL to that page as a default for any buisnesses that don't have a site.
Quote Reply
Re: [PerlFlunkie] Removing Hyperlink In reply to
Hi PerlFlunkie,
Tried to make changes as descibed in the rtf file, but wouldn't work. It appears additional modifications are needed in the admin.cgi file?

Got these errors,

Error including libraries: syntax error at /home/site/cgi-bin/local/admin/links.def line 87, near "isLinked"
Compilation failed in require at /home/site/cgi-bin/local/jump.cgi line 36.

Make sure they exist, permissions are set properly, and paths are set correctly.Content-type: text/plain

Error: No link specified!

And

Error Message : fatal error: syntax error at /home/site/cgi-bin/local/admin/links.def line 87, near "isLinked"
Compilation failed in require at /home/site/cgi-bin/local/admin/admin.cgi line 55.

RJ

Quote Reply
Re: [MJB] Removing Hyperlink In reply to
Hi MJB,
I already have it set up to show a default apge, although that looks a bit funky.

RJ
Quote Reply
Re: [RJLee] Removing Hyperlink In reply to
In the instructions, did you take care of the comma?


Priority => [18, 'alpha', 0, 5, 1, 'No', 'No|Yes']
,
isLinked => [
19, 'alpha', 0, 5, 1, 'No', 'No|Yes']

);


Also you will notice that the last entry does not have a comma after it so be sure to add one to the previous one as shown in red above.



Leonard
aka PerlFlunkie
Quote Reply
Re: [PerlFlunkie] Removing Hyperlink In reply to
Yes, I did include the comma,

Priority => [18, 'alpha', 0, 5, 1, 'No', 'No|Yes'],
isLinked => [17
, 'alpha', 0, 5, 1, 'No', 'No|Yes']

);


Also made sure to change all the 19's to 17. I even resorted to opening up the permissions to 777 just in case that was the problem.

I added an additional | to the data base file as well, ||||||.
Quote Reply
Re: [RJLee] Removing Hyperlink In reply to
That number should be the next one in sequence, I think that would be 14 for a stock Links install. Also , you will need to add a new field space to the links.db file by adding a pipe delimiter '|'. If you are not sure about this, do a search for 'adding new fields' and you whould find some threads with more detail.


Leonard
aka PerlFlunkie
Quote Reply
Re: [PerlFlunkie] Removing Hyperlink In reply to
First off Leonard, thanks for taking the time to help me deal with this.

This script was altered before,

links.def

# Definition of your database file.
%db_def = (
ID => [0, 'numer', 5, 8, 1, '', ''],
Title => [1, 'alpha', 40, 75, 1, '', ''],
URL => [2, 'alpha', 40, 75, 1, 'http://', '^http|news|mailto|ftp'],
Date => [3, 'date', 15, 15, 1, \&get_date, ''],
Category => [4, 'alpha', 0, 150, 1, '', ''],
Description => [5, 'alpha', '40x3', 400, 0, '', ''],
'Contact Name' => [6, 'alpha', 40, 75, 1, '', ''],
'Contact Email' => [7, 'alpha', 40, 75, 1, '', '.+@.+\..+'],
Hits => [8, 'numer', 10, 10, 1, '0', '\d+'],
isNew => [9, 'alpha', 0, 5, 0, 'No', ''],
isPopular => [10, 'alpha', 0, 5, 0, 'No', ''],
Rating => [11, 'numer', 10, 10, 1, 0, '^[\d\.]+$'],
Votes => [12, 'numer', 10, 10, 1, 0, '^\d+$'],
ReceiveMail => [13, 'alpha', 10, 10, 1, 'Yes', 'No|Yes'],
Telephone => [14, 'numer', 15, 25, 0, '', ''],
Street => [15, 'alpha', 40, 40, 0, '', ''],
City => [16, 'alpha', 45, 45, 0, '', ''],
isLinked => [17, 'alpha', 0, 5, 1, 'No', 'No|Yes']

);
___________________________

# where the first field equals 0.
$db_category = 4; $db_modified = 3; $db_url = 2;
$db_hits = 8; $db_isnew = 9; $db_ispop = 10;
$db_contact_name = 6; $db_contact_email = 7; $db_title = 1;
$db_votes = 12; $db_rating = 11; $db_mail = 13;
$db_islinked = 17;
___________________________________

%db_select_fields = (
isNew => 'Yes,No',
isPopular => 'Yes,No',
ReceiveMail => 'Yes,No',

isLinked => 'Yes,No'

);
___________________________________



I added a new pipe delimiter '|' to make it '||||||' in the links.db
Quote Reply
Re: [RJLee] Removing Hyperlink In reply to
Try removing the no|yes:

isLinked => [17, 'alpha', 0, 5, 1, 'No', '']

Also, having that 'No' there makes the default not hyperlinked.




Leonard
aka PerlFlunkie
Quote Reply
Re: [PerlFlunkie] Removing Hyperlink In reply to
The instructions for this functional mod are here:

http://www.gossamer-threads.com/...i?post=274662#274662


Leonard
aka PerlFlunkie