Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

[Contribution] Links Manager for osC v1.00


VJ

Recommended Posts

hmmm, never mind about upgrading - I am lost in step one concerning the database - I rarely use myphpadmin and am not comfy enough to be doing all that work in it. *sighs* crappies.

Link to comment
Share on other sites

  • Replies 1.1k
  • Created
  • Last Reply

Top Posters In This Topic

I installed Ultimate SEO Friendly URLs v2.2 in order to show the directory links SEO frindly. Now when I click on a catogory link it gives me a 404 Not Fond page in this format:

The requested URL /catalog/personal-links-5.html was not found on this server.

.

 

Do I have to adjust some settings in Admin so as to have the page load properly? If not, where do I check to se if I've installed the script right?

Link to comment
Share on other sites

hmmm, never mind about upgrading - I am lost in step one concerning the database - I rarely use myphpadmin and am not comfy enough to be doing all that work in it. *sighs* crappies.
The next version will have a script that elimiates a lot of the steps needed in the database update so try back in a week or so.

 

Jack

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

All of My Addons

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

I installed Ultimate SEO Friendly URLs v2.2 in order to show the directory links SEO frindly. Now when I click on a catogory link it gives me a 404 Not Fond page in this format:
The requested URL /catalog/personal-links-5.html was not found on this server.

.

 

Do I have to adjust some settings in Admin so as to have the page load properly? If not, where do I check to se if I've installed the script right?

It should work if both are installed correctly.

 

Jack

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

All of My Addons

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

It should work if both are installed correctly.

 

Jack

 

It works now. I followed the install instruction by Nventa that says

 

Options +FollowSymLinks

RewriteEngine On

RewriteBase /directory/

 

RewriteRule ^(.*)-p-(.*).html$ product_info.php?products_id=$2&%{QUERY_STRING}

RewriteRule ^(.*)-c-(.*).html$ index.php?cPath=$2&%{QUERY_STRING}

RewriteRule ^(.*)-m-(.*).html$ index.php?manufacturers_id=$2&%{QUERY_STRING}

RewriteRule ^(.*)-pi-(.*).html$ popup_image.php?pID=$2&%{QUERY_STRING}

RewriteRule ^(.*)-t-(.*).html$ articles.php?tPath=$2&%{QUERY_STRING}

RewriteRule ^(.*)-a-(.*).html$ article_info.php?articles_id=$2&%{QUERY_STRING}

RewriteRule ^(.*)-pr-(.*).html$ product_reviews.php?products_id=$2&%{QUERY_STRING}

RewriteRule ^(.*)-pri-(.*).html$ product_reviews_info.php?products_id=$2&%{QUERY_STRING}

RewriteRule ^(.*)-i-(.*).html$ information.php?info_id=$2&%{QUERY_STRING}

 

This line of code was missing in the instruction that aim for us who have the shop in a directory hence my SEO category links didn't work

RewriteRule ^(.*)-links-(.*).html$ links.php?lPath=$2&%{QUERY_STRING}

Link to comment
Share on other sites

A new version has been uploaded. Here is what was changed:

 

- Fixed mistake in the update_changes_v_1.10_to_1.13.txt file.

- Added the links_db_update.php file. This will remove all of the settings in the configuration table and replace them with a new set. This will allow for quicker and easier updates. The downside is that you will need to go through the settings and set them the way you want. It won't cause the loss of any links though so it is safe to run.

- Added the Link Satus to the Links Status display window

- Added code to the curl script, links_check.php, so that it emails the site owner if their link cannot be found. It also marks their link as Disabled.

- Changed code in admin/links_featured.php to be compatible with previous versions of mysql.

- Changed code in admin/links_status.php to make url a clickable link.

 

The big improvement with this update is that it manages the links for you through the cron job. If the links are not found, a message is sent to the contact email address for that link. There might be a problem with this though. If the site is down, possibly a server failure, the link will be marked as disabled. If you think this will be a problem for you, you need to disable the code in the admin/link_check.php file so that it doesn't change the link status. I'm working on the best way to handle this situation - suggestions are weloome. :)

 

Jack

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

All of My Addons

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

Thanks for the new version! :)

 

There is one more thing... In catalog/includes/languages/english/links.php there is this line:

 

define('TEXT_MAIN_LINKS', 'Below is our list of links for the %s category.');

 

The %s shows in one language (English) only. Could you please help me to make it multi-language supported as well.

 

It emanates from around line 420 in catalog/links.php:

 

<?php echo sprintf(TEXT_MAIN_LINKS, $link_categories_value['link_categories_name']); ?>

 

TIA

/kbking

Link to comment
Share on other sites

If you want it to work in a different language, you have to duplicate the links files in the english directory and copy them to some other language directory.

 

Jack

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

All of My Addons

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

Thanks for the new version! :)

 

There is one more thing... In catalog/includes/languages/english/links.php there is this line:

 

define('TEXT_MAIN_LINKS', 'Below is our list of links for the %s category.');

 

The %s shows in one language (English) only. Could you please help me to make it multi-language supported as well.

 

It emanates from around line 420 in catalog/links.php:

 

<?php echo sprintf(TEXT_MAIN_LINKS, $link_categories_value['link_categories_name']); ?>

 

TIA

/kbking

 

If you want it to work in a different language, you have to duplicate the links files in the english directory and copy them to some other language directory.

 

Jack

 

I'm really sorry, usually I'm able sort things out with the guidance of various help files and forum threads, but here I can't figure out how. The links files concerned here are 3 links.php files in the languages directories, one for English, one for Swedish and one for Norwegian. I have had them in place from the beginning and every word translates correct in each language except for the word category name, which word, in the code corresponds with %s.

 

The sentence in links.php in the english directory reads:

 

Below is our list of links for the %s category.

 

The sentence in links.php in the swedish directory reads:

 

Nedan ?r v?r l?nklista f?r %s kategorin.

 

Every word translates nicely except for the %s (=category name), which is being printed out in English in all three languages that I use.

 

I do not have this dilemma in the catalog/links_submit.php file where the category names are printed out correct in all three languages. Therefor I belive that a corresponding code like the one in catalog/links_submit.php (a dropdown list for the category names) is necessary in the catalog/links.php aswell, in order to print out the category name in English, Swedish and in Norwegian.

 

Thanks for Your patience!

Link to comment
Share on other sites

Oh, I see what you mean now. Find this code in links.php

$link_categories_query = tep_db_query("select link_categories_name from " . TABLE_LINK_CATEGORIES_DESCRIPTION . " where link_categories_id = '" . (int)$lPath . "'");

and change it to

$link_categories_query = tep_db_query("select link_categories_name from " . TABLE_LINK_CATEGORIES_DESCRIPTION . " where link_categories_id = '" . (int)$lPath . "' AND language_id = '" . (int)$languages_id . "'");

Please let me know if that works so I can change it in the next version.

 

Jack

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

All of My Addons

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

I just downloaded and installed the latest version of your contribution and while making some changes noticed that when the data was loaded to the configuration_group table the ID used was 17 but the configuration_group_id attribute in the configuration table was a 0. I manually went in and updated the configuration_group_id in the configuration table to be the 17 (29 rows updated) and that fixed my problems. The admin screen under the links option in the configuration section now shows the link manager properties.

Link to comment
Share on other sites

Oh, I see what you mean now. Find this code in links.php
$link_categories_query = tep_db_query("select link_categories_name from " . TABLE_LINK_CATEGORIES_DESCRIPTION . " where link_categories_id = '" . (int)$lPath . "'");

and change it to

$link_categories_query = tep_db_query("select link_categories_name from " . TABLE_LINK_CATEGORIES_DESCRIPTION . " where link_categories_id = '" . (int)$lPath . "' AND language_id = '" . (int)$languages_id . "'");

Please let me know if that works so I can change it in the next version.

 

Jack

 

Yes now it works in all languages! :)

 

Thank You!

Link to comment
Share on other sites

I just downloaded and installed the latest version of your contribution and while making some changes noticed that when the data was loaded to the configuration_group table the ID used was 17 but the configuration_group_id attribute in the configuration table was a 0. I manually went in and updated the configuration_group_id in the configuration table to be the 17 (29 rows updated) and that fixed my problems. The admin screen under the links option in the configuration section now shows the link manager properties.
Did you do an update or a new install? If an update, you would have had to had been at version 1.13 for it to work. Also, you could just use the links_db_update.php file instead of changing all of those manually.

 

Jack

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

All of My Addons

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

Did you do an update or a new install? If an update, you would have had to had been at version 1.13 for it to work. Also, you could just use the links_db_update.php file instead of changing all of those manually.

 

Jack

 

new install and not an upgrade.

Link to comment
Share on other sites

Hi, I just installed v1.14... when I ran the links_setup.php file, I received:

 

0 -

 

select c.categories_id, cd.categories_name, c.parent_id from faqdesk_categories c, faqdesk_categories_description cd where c.catagory_status = '1' and c.parent_id = 'INSERT INTO configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, date_added) VALUES ('Check for Duplicate Links', 'LINKS_CHECK_DUPLICATE', 'True', 'Check if the submitted link is already on file.', '6135', '29', 'tep_cfg_select_option(array(\'True\', \'False\'), ', now())' and c.categories_id = cd.categories_id and cd.language_id='1' order by sort_order, cd.categories_name

 

[TEP STOP]

 

Is this what is supposed to happen?

 

Then, in admin section, under Links Manager>Links>New Link, I receive:

 

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /home/hazardpr/public_html/admin/links.php on line 235

 

Warning: array_merge() [function.array-merge]: Argument #2 is not an array in /home/hazardpr/public_html/admin/links.php on line 235

 

Warning: reset() [function.reset]: Passed variable is not an array or object in /home/hazardpr/public_html/admin/includes/classes/object_info.php on line 17

 

Warning: Variable passed to each() is not an array or object in /home/hazardpr/public_html/admin/includes/classes/object_info.php on line 18

 

I receive other errors as well, but I figured I would start here.

 

Thanks in advance for any assistance.

Link to comment
Share on other sites

Hi, I just installed v1.14... when I ran the links_setup.php file, I received:

 

0 -

 

select c.categories_id, cd.categories_name, c.parent_id from faqdesk_categories c, faqdesk_categories_description cd where c.catagory_status = '1' and c.parent_id = 'INSERT INTO configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, date_added) VALUES ('Check for Duplicate Links', 'LINKS_CHECK_DUPLICATE', 'True', 'Check if the submitted link is already on file.', '6135', '29', 'tep_cfg_select_option(array(\'True\', \'False\'), ', now())' and c.categories_id = cd.categories_id and cd.language_id='1' order by sort_order, cd.categories_name

 

[TEP STOP]

Are you sure you are seeing that error when you run the links_setup.php file? The reason I ask is becuase that file doesn't have any mention of faqdesk in it but your error does. You should either get a failed, passed o ralready installed message when you run that script but nothing like the above.

 

Jack

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

All of My Addons

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

Are you sure you are seeing that error when you run the links_setup.php file? The reason I ask is becuase that file doesn't have any mention of faqdesk in it but your error does. You should either get a failed, passed o ralready installed message when you run that script but nothing like the above.

 

Jack

 

Hi, I have the FAQDESK contrib installed.

 

Maybe the Links Manager is conflicting with FAQDESK.

 

I don't know.

Link to comment
Share on other sites

No, you miss my point. When you run the links_setup.php file, all it does is update the database. It doesn't load anything in the page and if it had an error, it wouldn't contain faqdesk in it - it couldn't. So I think you are confused as to how you are getting that error. Until that problem is sorted out, you can't move forward.

 

Jack

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

All of My Addons

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

No, you miss my point. When you run the links_setup.php file, all it does is update the database. It doesn't load anything in the page and if it had an error, it wouldn't contain faqdesk in it - it couldn't. So I think you are confused as to how you are getting that error. Until that problem is sorted out, you can't move forward.

 

Jack

 

No, I didn't miss your point. I followed the instructions to the letter. When I ran links_setup.php, I received the errors.

 

I even removed the Links Manager contrib, twice now, and reinstalled it. Both times, same errors.

 

Now, I tested the theory that Links Manager conflicts with FaqDesk by installing the contrib on a site that does not have FaqDesk installed - tottally clean oSC 2.2 Ms2 install. On the site that does not have FaqDesk installed, the Links Manager installation and setup performed flawlessly BUT in the admin section under Links Manager>New Link, I still receive the exact same following error:

 

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /home/hazardpr/public_html/wholesale/admin/links.php on line 235

 

Warning: array_merge() [function.array-merge]: Argument #2 is not an array in /home/hazardpr/public_html/wholesale/admin/links.php on line 235

 

Warning: reset() [function.reset]: Passed variable is not an array or object in /home/hazardpr/public_html/wholesale/admin/includes/classes/object_info.php on line 17

 

Warning: Variable passed to each() is not an array or object in /home/hazardpr/public_html/wholesale/admin/includes/classes/object_info.php on line 18

 

The Links Manager (links_setup.php) conflicts with the FaqDesk contrib.

 

Both sites (one with faqdesk and the other a clean oSC install) receive the same errors in the admin section when trying to add new links.

Link to comment
Share on other sites

Hi

 

I have set up a few categories and tried adding a link in admin, when you go to my links page it shows 1 link in this category but then when you click on the category it says there are no links!

 

What have i missed? i have the link as approved

 

Thanks

 

Chris

What version are you using? Is it an update?

 

Jack

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

All of My Addons

Get the latest versions of my addons

Recommended SEO Addons

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...