Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Links Manager For OSC v0.20 released


VJ

Recommended Posts

This program enables display and management of a categorized list of links to other websites. You can add/edit/delete/enable/disable links and categories from the admin interface.

 

It also includes a link submit form, where users can submit links and request you to add them to your list.

 

http://www.oscommerce.com/community/contributions,1256

 

Please give it a try and send in your comments and suggestions. This is my first ever contribution for OSC. Hope I've done a fair enough job.

 

VJ

 

--

http://www.salehut.com

Link to comment
Share on other sites

  • Replies 125
  • Created
  • Last Reply

Top Posters In This Topic

If it is the link program that is on your site this will be a great addition to many osc stores!

[no external urls in signatures please, kthanks]

Link to comment
Share on other sites

Very good contribution :D

 

I have the German translation ready by tomorrow could post it.

 

Did you ever think about, to allow some banners or buttons? Perhaps for a fee?

 

Once more, well done

 

Cheers

Link to comment
Share on other sites

Looks real nice. Too bad it is not multilingual so we cannot use it :(

 

Heres the sql-plan if you are planning to add this feature:

 

# Links Manager for OSC v0.2



#

# Table structure for table `exchange_links_categories`

#



CREATE TABLE exchange_links_categories (

 link_category_id int(11) NOT NULL auto_increment,

 link_category_contact varchar(96) NOT NULL default '',

 link_category_email varchar(96) NOT NULL default '',

 link_category_rating int(11) default NULL,

 link_category_date datetime NOT NULL default '0000-00-00 00:00:00',

 link_category_status int(1) NOT NULL default '1',

 PRIMARY KEY  (link_category_id)

) TYPE=MyISAM;

# --------------------------------------------------------



#

# Table structure for table `exchange_links_categories_description`

#



CREATE TABLE exchange_links_categories_description (

 link_category_id int(11) NOT NULL auto_increment,

 link_category_name varchar(64) NOT NULL default '',

 language_id int(11) NOT NULL default '0',

 link_category_description text,

 PRIMARY KEY  (link_category_id)

) TYPE=MyISAM;



#

# Table structure for table `exchange_links_links`

#



CREATE TABLE exchange_links_links (

 link_category_id int(11) NOT NULL default '0',

 link_id int(11) NOT NULL auto_increment,

 link_url varchar(255) NOT NULL default '',

 link_contact varchar(96) NOT NULL default '',

 link_email varchar(96) NOT NULL default '',

 link_reciprocal varchar(255) NOT NULL default '',

 link_rating int(11) default NULL,

 link_date datetime NOT NULL default '0000-00-00 00:00:00',

 link_status int(1) NOT NULL default '1',

 PRIMARY KEY  (link_id,link_category_id)

) TYPE=MyISAM;



#

# Table structure for table `exchange_links_links_description `

#



CREATE TABLE exchange_links_links_description (

 language_id int(11) NOT NULL default '0',

 link_id int(11) NOT NULL auto_increment,

 link_title varchar(255) NOT NULL default '',

 link_description text,

 PRIMARY KEY  (link_id,link_category_id)

) TYPE=MyISAM;

"Use no way as way, have no limitation as limitation." - Bruce Lee

Link to comment
Share on other sites

Looks real nice. Too bad it is not multilingual so we cannot use it

 

Thanks for your comments :-)

 

Well, its a shame I didn't give too much thought about making the mod multi-lingual. I might go for it in the next version, though.

 

Meanwhile, why don't you go ahead and give it a shot. That DB plan looks great :-).

 

VJ

 

--

http://www.salehut.com

Link to comment
Share on other sites

Looks real nice. Too bad it is not multilingual so we cannot use it

 

Thanks for your comments :-)

 

Well, its a shame I didn't give too much thought about making the mod multi-lingual. I might go for it in the next version, though.

 

Meanwhile, why don't you go ahead and give it a shot. That DB plan looks great :-).

 

VJ

 

--

http://www.salehut.com

 

Exactly what I was thinking, if someone knows how to change the code, why not go ahead and do it and send it to the author instead of making a negative post.

 

This attitude that contributions, that are made by volunteers, that are free for you to use, need to fit everyone in the world's needs is very discouraging.

 

If you have a suggestion, make it.

 

If you know how to fix it, fix it.

 

If you have a demand, forget it.

[no external urls in signatures please, kthanks]

Link to comment
Share on other sites

Hmm... Maybe I should have used "unfortunately" instead of "too bad". My apologies if it sounded too negative. That was not my intention as this is one of those rare contributions that has potential to be useful to alot of shops.

 

However the missing feature does limit its potential to shops with one language.

 

I would be more than happy to help with the coding as far as I can.

"Use no way as way, have no limitation as limitation." - Bruce Lee

Link to comment
Share on other sites

:) Thanks for clarifying and I apologize for snapping. There is a lot of "demanding" instead of offering and asking going on these days and I made an assumption due to the tone of the note.

 

What a difference a word makes....

[no external urls in signatures please, kthanks]

Link to comment
Share on other sites

Hi VJ,

 

A great script :D I have 2 questions..

 

1. I cannot get it to show the category decriptions, what do I need to change ?

 

2. I have done danish language files, if anyone is interested..

 

Regards Allan

Link to comment
Share on other sites

Thanks for your compliments, Allan. :)

 

As regards display of category description, you can find the code that displays category information in /catalog/exchange_links.php,

 

at around line 95,

 

    echo '                <td align="left" class="smallText" style="width: ' . $width . '" valign="top"><br> » <a href="' . tep_href_link(FILENAME_EXCHANGE_LINKS, 'lPath=' . $link_category_data['link_category_id']) . '" class="subCatLinks">' . $link_category_data['link_category_name'] . '</a> (' . $link_count . ')</td>' . "n";

 

Just add the category description variable $link_category_data['link_category_description'] somewhere in the above code segment.

 

HTH,

VJ

 

--

http://www.salehut.com

Link to comment
Share on other sites

Hi Allan,

 

Can you please post the code segment you've changed and the segment where you get errors. Its kind of hard to speculate without much to look at.

 

VJ

Link to comment
Share on other sites

i keep trying.. promise not to laugh at me, i'm new at this

 

    $width = (int)(100 / MAX_DISPLAY_CATEGORIES_PER_ROW) . '%';

   echo '                <td align="left" class="smallText" style="width: ' . $width . '" valign="top"><br> » <a href="' . tep_href_link(FILENAME_EXCHANGE_LINKS, 'lPath=' . $link_category_data['link_category_id']) . <br> . $link_category_data['link_category_description'].'" class="subCatLinks">' . $link_category_data['link_category_name'] . '</a> (' . $link_count . ')</td>' . "n";

   if ((($rows / MAX_DISPLAY_CATEGORIES_PER_ROW) == floor($rows / MAX_DISPLAY_CATEGORIES_PER_ROW)) && ($rows != tep_db_num_rows($link_category_query))) {

     echo '              </tr>' . "n";

     echo '              <tr>' . "n";

   }

}

?>

Link to comment
Share on other sites

Hi Allan,

 

Trust me, no one's going to laugh at you for trying something.

 

Ah, and here's something you can try,

 

    $width = (int)(100 / MAX_DISPLAY_CATEGORIES_PER_ROW) . '%';

   echo '                <td align="left" class="smallText" style="width: ' . $width . '" valign="top"><br> » <a href="' . tep_href_link(FILENAME_EXCHANGE_LINKS, 'lPath=' . $link_category_data['link_category_id']) . '" class="subCatLinks">' . $link_category_data['link_category_name'] . '</a> (' . $link_count . ')' . '<br>' . $link_category_data['link_category_description'] . '</td>' . "n";

   if ((($rows / MAX_DISPLAY_CATEGORIES_PER_ROW) == floor($rows / MAX_DISPLAY_CATEGORIES_PER_ROW)) && ($rows != tep_db_num_rows($link_category_query))) {

     echo '              </tr>' . "n";

     echo '              <tr>' . "n";

   }

 }

 

 

HTH :),

VJ

Link to comment
Share on other sites

Can anyone help? I have inserted the file in my admin directory and nothing is happing. I dont see anything in my admin control panel that will allow me to control links. Is there something else I need to do. And yes....I am very new to osc and php. Thanks for your help..

 

falconpilot

Link to comment
Share on other sites

Can anyone help? I have inserted the file in my admin directory and nothing is happing. I dont see anything in my admin control panel that will allow me to control links. Is there something else I need to do. And yes....I am very new to osc and php. Thanks for your help..

 

falconpilot

 

i'm new at php also, but it was very easy. just follow the instructions in the readme.txt file. there are some more modifications listed in there.

 

ps: i know pilots don't like to read the instructions :wink: i normally fly for a living too.

 

regards allan

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...