![]() |
Custom Search Fields |
Post Reply ![]() |
Page 12> |
Author | |
lhuggins ![]() Newbie ![]() Joined: 09-January-2012 Status: Offline Points: 4 |
![]() ![]() ![]() ![]() ![]() Posted: 11-January-2012 at 12:54pm |
Is there a way to assign an item to more than one value in a custom search field?
Example; Search field- Drum type Values- Metal drum Plastic drum I have a product that can be used on metal and/or plastic. If I assign it to metal drum it will not show up on a plastic drum search, if I assign it to plastic drum it will not show up on a metal drum search. I have tried to clone it and assign one to metal and one to plastic but when there is no search on drum type they both show up.
|
|
![]() |
|
Hamish ![]() Admin Group ![]() Joined: 12-October-2006 Location: United Kingdom Status: Offline Points: 56 |
![]() ![]() ![]() ![]() ![]() |
Hi,
Custom Search Fields only support a single value for each product I'm afraid. |
|
![]() |
|
lhuggins ![]() Newbie ![]() Joined: 09-January-2012 Status: Offline Points: 4 |
![]() ![]() ![]() ![]() ![]() |
Any ideas on a work around? I have many products that this effects.
|
|
![]() |
|
p00pstar ![]() Newbie ![]() ![]() Joined: 17-March-2007 Location: Romania Status: Offline Points: 0 |
![]() ![]() ![]() ![]() ![]() |
There is a workaround.
1. From "pcadmin" open file "modifyProductB.asp"; 2. Search for "function AddSF(tmpSFID,tmpSFName,tmpSVID,tmpSValue,tmpSOrder)"; 3. Change the javascript function to this : function AddSF(tmpSFID,tmpSFName,tmpSVID,tmpSValue,tmpSOrder) { if (tmpSValue!="") { var i=0; var found=0; SFCount++; SFID[SFCount]=tmpSFID; SFNAME[SFCount]=tmpSFName; SFVID[SFCount]=tmpSVID; SFVALUE[SFCount]=tmpSValue; SFVORDER[SFCount]=tmpSOrder; CreateTable(); } } Now it will work to add more values to the same custom-field. Otherwise, it will just replace the old value... |
|
www.dotdesignmedia.ro // web application development
|
|
![]() |
|
lhuggins ![]() Newbie ![]() Joined: 09-January-2012 Status: Offline Points: 4 |
![]() ![]() ![]() ![]() ![]() |
Thank you so much for this GREAT information, I really need a work around. One problem, I can not find "function AddSF(tmpSFID,tmpSFName,tmpSVID,tmpSValue,tmpSOrder)" in "modifyProductB.asp".
I am using PC v4.5bcm
|
|
![]() |
|
lhuggins ![]() Newbie ![]() Joined: 09-January-2012 Status: Offline Points: 4 |
![]() ![]() ![]() ![]() ![]() |
I did find it in "modifyProduct.asp" and changed it as you instructed and I can not add more than one value to one custom search field.
|
|
![]() |
|
Hamish ![]() Admin Group ![]() Joined: 12-October-2006 Location: United Kingdom Status: Offline Points: 56 |
![]() ![]() ![]() ![]() ![]() |
Hi, Try in modifyproduct.asp. The code also appears in several other files.
|
|
![]() |
|
p00pstar ![]() Newbie ![]() ![]() Joined: 17-March-2007 Location: Romania Status: Offline Points: 0 |
![]() ![]() ![]() ![]() ![]() |
I'm afraid i can't help you with 4.5, i only have version 4.1 with sp3.
Maybe there are some differences, i don't know...
|
|
www.dotdesignmedia.ro // web application development
|
|
![]() |
|
p00pstar ![]() Newbie ![]() ![]() Joined: 17-March-2007 Location: Romania Status: Offline Points: 0 |
![]() ![]() ![]() ![]() ![]() |
This function just searches for the custom field that you want to modify, and if it exists, it replaces the old value with the new value.
If you comment those lines (or delete them) it will work to add another value to the same custom field...
|
|
www.dotdesignmedia.ro // web application development
|
|
![]() |
|
lhuggins ![]() Newbie ![]() Joined: 09-January-2012 Status: Offline Points: 4 |
![]() ![]() ![]() ![]() ![]() |
Thank you for the help, unfortunately it did not work. I modified "modifyProduct.asp" to;
function AddSF(tmpSFID,tmpSFName,tmpSVID,tmpSValue,tmpSOrder) { if (tmpSValue!="") { var i=0; var found=0; SFCount++; SFID[SFCount]=tmpSFID; SFNAME[SFCount]=tmpSFName; SFVID[SFCount]=tmpSVID; SFVALUE[SFCount]=tmpSValue; SFVORDER[SFCount]=tmpSOrder; } CreateTable(); } } And it still replaces the value in custom fields instead of adding another one.
|
|
![]() |
Post Reply ![]() |
Page 12> |
Tweet
|
Forum Jump | Forum Permissions ![]() You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |