Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Easy Populate Error - Need Help With Some Code


JustinS

Recommended Posts

Instructions as written:

STEP #3 - Add a link in the Admin Panel. Edit file "/catalog/admin/incudes/boxes/catalog.php"

 

Find this code (Around Line 25):

'<a href="' . tep_href_link(FILENAME_PRODUCTS_ATTRIBUTES, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_CATEGORIES_PRODUCTS_ATTRIBUTES . '</a><br>' .

 

Directly AFTER add this:

'<a href="' . tep_href_link(FILENAME_EASYPOPULATE, '', 'NONSSL') . '" class="menuBoxContentLink">' . TEXT_EASYPOPULATE . '</a><br>' .

__________________________________________________________

 

This is some of the instructions provided, however, where it says "Find this code (Around Line 25)" it is not there. I found what looks to be similar to it:

 

 

array(

'code' => FILENAME_PRODUCTS_ATTRIBUTES,

'title' => BOX_CATALOG_CATEGORIES_PRODUCTS_ATTRIBUTES,

'link' => tep_href_link(FILENAME_PRODUCTS_ATTRIBUTES)

)

 

So I added the code they said to add directly after it and this is what it ends up looking like:

 

 

array(

'code' => FILENAME_PRODUCTS_ATTRIBUTES,

'title' => BOX_CATALOG_CATEGORIES_PRODUCTS_ATTRIBUTES,

'link' => tep_href_link(FILENAME_PRODUCTS_ATTRIBUTES)

'<a href="' . tep_href_link(FILENAME_EASYPOPULATE, '', 'NONSSL') . '" class="menuBoxContentLink">' . TEXT_EASYPOPULATE . '</a><br>' .

)

 

Ok. So after going through all the steps, hoping that the code I found was the right one (it's the only one with FILENAME_PRODUCTS_ATTRIBUTES) I went to test it by logging in to my www.mydomain.com/admin/ page.

 

Doing so returned this:

Parse error: syntax error, unexpected T_CONSTANT_ENCAPSED_STRING, expecting ')' in/home/a7852663/public_html/admin/includes/boxes/catalog.php on line 25.

So what exactly do I need to change in the code they asked me to add to make it work with the code that came with my osCommerce?

 

I hope I gave enough information.

Thanks in advance.

Link to comment
Share on other sites

Was I supposed to add:

 

'<a href="' . tep_href_link(FILENAME_EASYPOPULATE, '', 'NONSSL') . '" class="menuBoxContentLink">' . TEXT_EASYPOPULATE . '</a><br>' .

 

After the ) ?

 

 

EDIT:

I tried to do it after the ) and my /admin works now... but the button isn't there where it should be so I can not get to easy populate.

 

I noticed when I did it like this there was a "<" in the admin/catalog/ menu bar, and when I removed the code it removed the <.

 

Anyone know the correct way to fix this?

Link to comment
Share on other sites

Hi Justin

 

There is a contribution of Easy Populate which is specifically written for V2.31, However I just used this

 

  array(
	'code' => 'easypopulate.php',
	'title' => 'Easy Populate',
	'link' => tep_href_link('easypopulate.php')
  ),

 

Hope this helps

 

Ken

Link to comment
Share on other sites

You have a 2.3 shop and are using instructions for a pre-2.3 shop. Have you checked the Easy Populate addon section to see if there is a 2.3 version? Have you checked in the support thread to see if a solution has been posted? All contribution-related questions should be asked in that contributions support thread for best results. Just applying the change to the catalog box won't solve your problems since the easy populate file itself will wrong if you are using the wrong version.

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

@@Ken44

I wrote one and then refreshed this page and seen your response.

 

Mine ended up looking like:

 

array(

'code' => FILENAME_EASYPOPULATE,

'title' => EasyPopulate,

'link' => tep_href_link(FILENAME_EASYPOPULATE)

),

 

And it works.

 

Yours doesn't work for some reason

Link to comment
Share on other sites

  • 5 months later...

Has anyone looked at the 128 files under the easy populate add-on? Its a disaster. I have downloaded at least 5 of the "full installation" files that even suggest that they are for 2.3.X and they are all structured the same. To top it off the documentation still refers to 2.2 code.

 

Is there no moderation? Someone in charge? Or does everyone just get to throw files on the board?

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...