Jump to content
Nimmit

AJAX Attribute Manager support

Recommended Posts

It should be a UNIQUE index, rather than a plain INDEX.

 

I believe you have the correct column names in your 2 column index, I'd have to double check and don't have time right now to be 100% sure

 

 

It can`t be a UNIQUE index with options_id and options_values_id fields because i have many products with these the same atribute and the same option, so I think that it must be a Unique with products_id, options_id and options_values_id fields.

 

Ok, i'll try it. It is not the best solution but it's the only one that i have.

 

Thanks dewed

Share this post


Link to post
Share on other sites

Hi,

 

well i installed the contrib and see the "Save Product before adding options" message, when i try to add an article.

 

But when i try to edit an already saved article, nothing happens. Atrribute manager is missing. No errors, nothing. PHP error reporting is enabled.

 

However, in my local xampp installation, i see the attribute bar - everything works fine. But i am getting the

 

Deprecated: Assigning the return value of new by reference is deprecated 

 

error message. Well this message doesn't apper on my product server, too.

 

 

Well i tried to fix it and changed line 55 from:

		$attributeManager =& new attributeManagerAtomic(amGetSessionVariable(AM_SESSION_VAR_NAME));

to

		$clone = attributeManagerAtomic(amGetSessionVariable(AM_SESSION_VAR_NAME));
	$attributeManager = clone $clone;

 

I don't know, if that is the correct way! I tried to replace "=& new" with the "clone-function". It seems to work with line 55. But line

		$attributeManager =& new attributeManagerInstant($_GET['products_id']);

 

isn't so simple?!? "$test = attributeManagerInstant($_GET['products_id']);" for example does not work. I am not really a coder. But i think to disable error reporting isn't even a correct way...

 

 

But at the moment my problem is, that the ajax attribute manager section is blank!

 

greetz Crusher

Share this post


Link to post
Share on other sites

Hi.

 

i use ajax attribute maganer.

 

i have a question.

 

i add attributes in product page, i use an order with option and option value.

 

If i want see same order in product_info.php frontpage?

 

I can use products_attributes_id? right?

 

i try to set order in query, but I could not

 

Someone can help me?

 

Thanks

Share this post


Link to post
Share on other sites

Hi,

 

well i installed the contrib and see the "Save Product before adding options" message, when i try to add an article.

 

But when i try to edit an already saved article, nothing happens. Atrribute manager is missing. No errors, nothing. PHP error reporting is enabled.

 

However, in my local xampp installation, i see the attribute bar - everything works fine. But i am getting the

 

Deprecated: Assigning the return value of new by reference is deprecated 

 

error message. Well this message doesn't apper on my product server, too.

 

 

Well i tried to fix it and changed line 55 from:

		$attributeManager =& new attributeManagerAtomic(amGetSessionVariable(AM_SESSION_VAR_NAME));

to

		$clone = attributeManagerAtomic(amGetSessionVariable(AM_SESSION_VAR_NAME));
	$attributeManager = clone $clone;

 

I don't know, if that is the correct way! I tried to replace "=& new" with the "clone-function". It seems to work with line 55. But line

		$attributeManager =& new attributeManagerInstant($_GET['products_id']);

 

isn't so simple?!? "$test = attributeManagerInstant($_GET['products_id']);" for example does not work. I am not really a coder. But i think to disable error reporting isn't even a correct way...

 

 

But at the moment my problem is, that the ajax attribute manager section is blank!

 

greetz Crusher

 

I got the same errors. :(

Share this post


Link to post
Share on other sites

Hi,

 

well i installed the contrib and see the "Save Product before adding options" message, when i try to add an article.

 

But when i try to edit an already saved article, nothing happens. Atrribute manager is missing. No errors, nothing. PHP error reporting is enabled.

 

However, in my local xampp installation, i see the attribute bar - everything works fine. But i am getting the

 

Deprecated: Assigning the return value of new by reference is deprecated 

 

error message. Well this message doesn't apper on my product server, too.

 

 

Well i tried to fix it and changed line 55 from:

		$attributeManager =& new attributeManagerAtomic(amGetSessionVariable(AM_SESSION_VAR_NAME));

to

		$clone = attributeManagerAtomic(amGetSessionVariable(AM_SESSION_VAR_NAME));
	$attributeManager = clone $clone;

 

I don't know, if that is the correct way! I tried to replace "=& new" with the "clone-function". It seems to work with line 55. But line

		$attributeManager =& new attributeManagerInstant($_GET['products_id']);

 

isn't so simple?!? "$test = attributeManagerInstant($_GET['products_id']);" for example does not work. I am not really a coder. But i think to disable error reporting isn't even a correct way...

 

 

But at the moment my problem is, that the ajax attribute manager section is blank!

 

greetz Crusher

change this

$attributeManager =& new attributeManagerInstant($_GET['products_id'])

to

$attributeManager = new attributeManagerInstant($_GET['products_id'])

just remove the '&'

Share this post


Link to post
Share on other sites

Hi,

 

I have customized an osc rc2.2 with AJAX Attribute Manager v2.8.2 beta.

 

I have changed the admin folder to another folder. With a lower version the addon was working perfectly into the common admin folder.

Following the admin folder migration, I have upgraded to 2.8.2.

 

At the present time, the script allow:

- insert new attribute

- insert new attribute value

- Qt pro works fine

- add weight addon works fine

- attribute can be ordered

- attribute can be deleted

 

The trouble (with defaut setting):

- attribute value cannot be ordered

- attribute value cannot be deleted

- while I insert a new attribute value (ei: demo) a suffixe '1' is added (ei: demo1)

- attribute in foreigner language is not inserted

 

I have though to a bad field field order into the mysql, in fact, I try to find the trouble but I m stick since 3 days.

 

Any suggestion will be precious,

 

Regards

 

Yoan

post-295915-0-11475500-1313535857_thumb.jpg

post-295915-0-27179100-1313535866_thumb.jpg

Share this post


Link to post
Share on other sites

Hi,

 

I have customized an osc rc2.2 with AJAX Attribute Manager v2.8.2 beta.

 

I have changed the admin folder to another folder. With a lower version the addon was working perfectly into the common admin folder.

Following the admin folder migration, I have upgraded to 2.8.2.

 

At the present time, the script allow:

- insert new attribute

- insert new attribute value

- Qt pro works fine

- add weight addon works fine

- attribute can be ordered

- attribute can be deleted

 

The trouble (with defaut setting):

- attribute value cannot be ordered

- attribute value cannot be deleted

- while I insert a new attribute value (ei: demo) a suffixe '1' is added (ei: demo1)

- attribute in foreigner language is not inserted

 

I have though to a bad field field order into the mysql, in fact, I try to find the trouble but I m stick since 3 days.

 

Any suggestion will be precious,

 

Regards

 

Yoan

 

 

I have disable AJAX, the addon works fine

Share this post


Link to post
Share on other sites

Does anyone know if its possible to auto update the product price as options are chosen on the product page?

 

I've tried a couple of methods but none have worked. Just curious to know if anyone has managed to achieve this.

Share this post


Link to post
Share on other sites

Hello!

I tryed install all versions, but nothing. I have 2.3.1.

all time appears this message:

There was an error while retrieving the URL: Not Acceptable

what should i do? this addon is important for me.

My store locatated: MY_SITE/MY_STORE_(CATALOG)/ <--- maybe here is a problem?

Share this post


Link to post
Share on other sites

Just a suggestion..

 

would it be possible to have a text entry box for the sort order as well as the up and down arrows?

 

The reason being: on existing older products which don't have sort orders, when you add a new attribute it creates a sort order which is all out of sync. It is quite easy to spend 20 minutes or so moving options up and down into the correct order. If there was a text entry box and you just popped in the numbers then it would be a bit quicker :)

 

Like I say this is just a suggestion as I'm not clever enough to do it myself :D

 

Dave

Share this post


Link to post
Share on other sites

Hello I am running 2.3.1 and getting these two errors does anyone know anything about them?

 

Deprecated: Assigning the return value of new by reference is deprecated in C:\wamp\www\catalog\admin\attributeManager\includes\attributeManagerGeneralFunctions.inc.php on line 55

 

Deprecated: Assigning the return value of new by reference is deprecated in C:\wamp\www\catalog\admin\attributeManager\includes\attributeManagerGeneralFunctions.inc.php on line 58

 

Thank you

Share this post


Link to post
Share on other sites

Has anyone thought about sending the SQL to create the product along with the request for the new product page. This could potentially forgo the need to reload the saved product in order to add attributes to it.

 

Maybe the sql could be Ajax when a product name is input.

 

Just wondering if there is some unforeseen problems.

Share this post


Link to post
Share on other sites

I found the Deprecated: Assigning the return value of new by reference is deprecated in C:\wamp\www\catalog\admin\attributeManager\includes\attributeManagerGeneralFunctions.inc.php on line 55

problem it has to do with php 5.3.8 not supporting this feature anymore.

Share this post


Link to post
Share on other sites

Hello people. Anyone else having a problem with values?

 

Is there a reason we can add values when adding a new option but then have to go and add them as an option after? I love it that there can be options enabled and disabled like that but kinda seems redundant when creating the option.

 

I am using Sparx admin and noticed if your working and the login session runs out and then you try to do something the login box pops up in the middle of the screen. If you try to log in the browser will try to take you to an ajax attribute page.

 

Thanks for everyone's work. I will try to add something to the project soon.

Share this post


Link to post
Share on other sites

I am lost... I do not know how to run a sql query so I cant implement any of these fixes... I installed AJAX v2.8.9.3 and uploaded the attributeManager folder into the admin folder on my server...

 

I made the edits required in admin/categories and in admin/includes/template)top.php

 

still nothing... now what?

Share this post


Link to post
Share on other sites

why does the install instructions only apply to the one file? what about the template_top.?

 

Instructions copied below:

 

"Open admin/categories.php Find (Around line 243 on a fresh ms2)

tep_db_perform(TABLE_PRODUCTS, $sql_data_array, 'update', "products_id = '" . (int)$products_id . "'");

}

Below add

/** AJAX Attribute Manager **/

require_once('attributeManager/includes/attributeManagerUpdateAtomic.inc.php');

/** AJAX Attribute Manager end **/

 

 

Find (Around line 341 on a fresh ms2)

<script language="javascript" src="includes/general.js"></script>

Below add

<!-- AJAX Attribute Manager -->

<?php require_once( 'attributeManager/includes/attributeManagerHeader.inc.php' )?>

<!-- AJAX Attribute Manager end -->

 

 

Find (Around line 346 on a fresh ms2)

onload="SetFocus();"

Replace With

onload="goOnLoad();"

 

 

Find (around line 530 on a fresh ms2)

<td class="main"><?php echo tep_draw_separator('pixel_trans.gif', '24', '15') . ' ' . tep_draw_input_field('products_price_gross', $pInfo->products_price, 'OnKeyUp="updateNet()"'); ?></td>

</tr>

Below add

<!-- AJAX Attribute Manager -->

<tr>

<td colspan="2"><?php require_once( 'attributeManager/includes/attributeManagerPlaceHolder.inc.php' )?></td>

</tr>

<!-- AJAX Attribute Manager end -->

Share this post


Link to post
Share on other sites

The code in "product_info.php" has a minor error, but that error was piss me off for a little time.

 

After the copy/paste, search into your code a "pod" word, just modify it by "pov" and voilà:

 

Bad code :

//<!-- AJAX Attribute Manager -->
	$products_options_query = tep_db_query("select pov.products_options_values_id, pov.products_options_values_name, pa.options_values_price, pa.price_prefix from " . TABLE_PRODUCTS_ATTRIBUTES . " pa, " . TABLE_PRODUCTS_OPTIONS_VALUES . " pod where pa.products_id = '" . (int)$HTTP_GET_VARS['products_id'] . "' and pa.options_id = '" . (int)$products_options_name['products_options_id'] . "' and pa.options_values_id = pov.products_options_values_id and pov.language_id = '" . (int)$languages_id . "' order by pa.products_options_sort_order");
//<!-- AJAX Attribute Manager end -->

 

Good code:

//<!-- AJAX Attribute Manager -->
	$products_options_query = tep_db_query("select pov.products_options_values_id, pov.products_options_values_name, pa.options_values_price, pa.price_prefix from " . TABLE_PRODUCTS_ATTRIBUTES . " pa, " . TABLE_PRODUCTS_OPTIONS_VALUES . " pov where pa.products_id = '" . (int)$HTTP_GET_VARS['products_id'] . "' and pa.options_id = '" . (int)$products_options_name['products_options_id'] . "' and pa.options_values_id = pov.products_options_values_id and pov.language_id = '" . (int)$languages_id . "' order by pa.products_options_sort_order");
//<!-- AJAX Attribute Manager end -->

Edited by Huroman

Share this post


Link to post
Share on other sites

Ok I installed the Add-on and made the code changes as per the instructions. When I went to add a new product to use the add-on I get the following message:

 

Fatal error: Call to undefined function amsessionisregistered() in /home/totalw8/public_html/clippityclipcoupons.com/admin/attributeManager/classes/attributeManagerConfig.class.php on line 141

I believe the add-on has conflict issues with the Sort Order plug-in and the QT Pro plug-in. However, I have never installed either add-on, but the AJAX assumes that I did.

 

If you view the file attached html.gif install-osc-2.3.1.htm (13.14K) and scroll to Additonal Notes for other contribution compatability you will note a series of instructions that state only if you have these plug-ins installed which I have not installed but it appears by viewing the attributeManager/classes/attributeManagerConfig.class.php file that they are assumed to be automatically installed.

 

As such, do I need to make the code changes as if I have the add-ons or do I need to install them.

 

Any help would be appreciated.

 

Ed

Share this post


Link to post
Share on other sites

Just a suggestion..

 

would it be possible to have a text entry box for the sort order as well as the up and down arrows?

 

The reason being: on existing older products which don't have sort orders, when you add a new attribute it creates a sort order which is all out of sync. It is quite easy to spend 20 minutes or so moving options up and down into the correct order. If there was a text entry box and you just popped in the numbers then it would be a bit quicker smile.png

 

Like I say this is just a suggestion as I'm not clever enough to do it myself biggrin.png

 

Dave

 

 

around line 244

 

if(AM_USE_SORT_ORDER) {

?>

<?php echo tep_draw_input_field("sortOrder_$optionValueId",$optionValueInfo['sortOrder'],' style="margin:3px 0px 3px 0px;" id="sortOrder_'.$optionValueId.'" size="4" onChange="return amUpdate(\''.$optionId.'\',\''.$optionValueId.'\');"'); ?>

<?php

}

?>

 

remove the //

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×