Jump to content


Corporate Sponsors


Latest News: (loading..)

- - - - -

Products Fields Groups


50 replies to this topic

#41 thejudge99

  • Community Member
  • 30 posts
  • Real Name:Julian

Posted 10 April 2012, 08:15

great to hear

#42 ja1nsa

  • Community Member
  • 24 posts
  • Real Name:John Ashcroft

Posted 10 April 2012, 08:42

Jules

Thanks for the reply. I am still non the wiser, however I have come across a rather interesting scenario. If you download the sample template from monster templates (the one for OScommerce), it now comes the a whole host of additional options including NIVO slider (configurable) and a pile of extra configuration stuff. I beleive it would be well worth OScommerce integraing this and making it 2.3.2 as an upgrade. I don't see where we could hit problems in terms of licensing as it was in a free download. It is also easily changed. Please pass onto the powers that be, maybe nobody has seen these improvements as they are either too advanced and focusing on dev OR too new and not sure what they mean. Really, the additional admin is just great!

Anyway, still not figured out my product setup yet, if you have time to assist I bascially have this scenario. Category (brand e.g. Samsung, Nokia), Product (Phone e.g. Galaxy S2). Now when a customer selects the phone I need to give opions i.e. the package. This could be Talk 100, 200, 500 on Network X, Chat 200,300,800 on Network Y. So ideally I would have 2 drop down boxes. One would allow customer to select Network (5 options), other would allow customer to select Tariff (say 20 options). The tariff would ideally be based on what is selected in the network drop down, though I can live with just 1 long list if needs.

Cheers.
J.

Edited by ja1nsa, 10 April 2012, 08:43.


#43 ja1nsa

  • Community Member
  • 24 posts
  • Real Name:John Ashcroft

Posted 10 April 2012, 08:50

Please see below screen shots taken from demo template. The screen shows the Nivo Slider. It is embedded in the OS 2.3.1 code and configuable. Works 100%.

Please pass on...

Attached Files


Edited by ja1nsa, 10 April 2012, 08:51.


#44 thejudge99

  • Community Member
  • 30 posts
  • Real Name:Julian

Posted 10 April 2012, 09:29

Hi ja1nsa

im not 100% sure what u are asking - but it looks like you need some modifications to the options part - whcih my addon does not do - it simply makes use of the options as a means to create extra fields.

Assuming you have the backend part working - ie you are able to create/ add extra fields to products then you can show these extra fields in a variety of ways that are included in the contribution - with a little knowlede of php / html the added code within product_info.php could be changed to fit / meet personal needs based on layout.

#45 ja1nsa

  • Community Member
  • 24 posts
  • Real Name:John Ashcroft

Posted 10 April 2012, 10:06

Julian

OK, I will work it out, getting there, just want to put my site live and then fine tune, but guess I'll have to learn some more first :)

Thanks for replying.

#46 cortezwa

  • Community Member
  • 2 posts
  • Real Name:Wilber

Posted 11 April 2012, 20:06

Hi Julian,

Great contribution!

Do you have any idea why my pfg will not save to the database? Clicking the "save groups" button does not update the groups. I can see the groups in the dropdown menu. I'm guessing I must have missed something in the following code in admin/categories.php:

//start Product Fields groups 1.3
if($products_count > 0 ){
if($HTTP_GET_VARS['action'] !="pfg_change"){
?>

<tr>
<td></td>
<td align="left" style="padding-top:6px;"><? echo tep_draw_button(TEXT_PRODUCTS_FIELDS_GROUPS_CHANGE, 'disk', tep_href_link(FILENAME_CATEGORIES, 'cPath=' . $cPath . (isset($HTTP_GET_VARS['pID']) ? '&pID=' . $HTTP_GET_VARS['pID'] : '') . '&action=pfg_change', 'NONSSL'))?></td>
<td></td>
<td></td>
</tr>
<?
}else{
?>

<tr>
<td align="right" style="padding-top:6px;"><? echo tep_draw_button(IMAGE_BACK, 'triangle-1-w', tep_href_link(FILENAME_CATEGORIES, 'cPath=' . $cPath . (isset($HTTP_GET_VARS['pID']) ? '&pID=' . $HTTP_GET_VARS['pID'] : ''))) ?></td>
<td align="left" valign="bottom"><? echo tep_draw_button(TEXT_PRODUCTS_FIELDS_GROUPS_SAVE, 'disk', null, 'secondary')?></td>
<td></td>
<td></td>
</tr>

<?
echo "</form>";
}
}

//end Product Fields groups 1.3

$cPath_back = '';
if (sizeof($cPath_array) > 0) {
for ($i=0, $n=sizeof($cPath_array)-1; $i<$n; $i++) {
if (empty($cPath_back)) {
$cPath_back .= $cPath_array[$i];
} else {
$cPath_back .= '_' . $cPath_array[$i];
}
}
}

$cPath_back = (tep_not_null($cPath_back)) ? 'cPath=' . $cPath_back . '&' : '';
//start Product Fields groups 1.3
if($HTTP_GET_VARS['action'] !="pfg_change"){
//end Product Fields groups 1.3
?>
<tr>
<td colspan="4"><table border="1" width="100%" cellspacing="0" cellpadding="2">
<tr>
<td class="smallText"><?php echo TEXT_CATEGORIES . '&nbsp;' . $categories_count . '<br />' . TEXT_PRODUCTS . '&nbsp;' . $products_count; ?></td>
<td align="right" class="smallText"><?php if (sizeof($cPath_array) > 0) echo tep_draw_button(IMAGE_BACK, 'triangle-1-w', tep_href_link(FILENAME_CATEGORIES, $cPath_back . 'cID=' . $current_category_id)); if (!isset($HTTP_GET_VARS['search'])) echo tep_draw_button(IMAGE_NEW_CATEGORY, 'plus', tep_href_link(FILENAME_CATEGORIES, 'cPath=' . $cPath . '&action=new_category')) . tep_draw_button(IMAGE_NEW_PRODUCT, 'plus', tep_href_link(FILENAME_CATEGORIES, 'cPath=' . $cPath . '&action=new_product')); ?>&nbsp;</td>
</tr>
</table></td>
</tr>
<?
//start Product Fields groups 1.3
}
//end Product Fields groups 1.3
?>
</table></td>


Any help is greatly appreciated.

Edited by cortezwa, 11 April 2012, 20:07.


#47 thejudge99

  • Community Member
  • 30 posts
  • Real Name:Julian

Posted 11 April 2012, 23:19

Hi cortezwa,

nice catch - seems i missed a step from my 1.3 install instruction - namely the opening form tag

I will update the addon tomorrow but for now.

in admin/categories.php

find

 
$categories_count = 0;
    $rows = 0;
    if (isset($HTTP_GET_VARS['search'])) {

insert ABOVE

 
//start Product Fields groups 1.3
if($HTTP_GET_VARS['action'] =="pfg_change"){
 echo tep_draw_form('products_fields_groups_update', FILENAME_CATEGORIES, 'cPath=' . $cPath . (isset($HTTP_GET_VARS['pID']) ? '&pID=' . $HTTP_GET_VARS['pID'] : '') . '&action=pfg_update', 'post', 'enctype="multipart/form-data"');
}
//end Product Fields groups 1.3

pls let me know if the batch update now works

Jules

#48 cortezwa

  • Community Member
  • 2 posts
  • Real Name:Wilber

Posted 12 April 2012, 05:10

Thank you Julian,

Your solution worked great! I am now able to do a batch update. :)

#49 thejudge99

  • Community Member
  • 30 posts
  • Real Name:Julian

Posted 12 April 2012, 07:56

Hi cortezwa - thnx for the feedback.

Ive updated the addon with this this missing step.

http://addons.oscommerce.com/info/8247

Jules

#50 ilyadgonbad

  • Community Member
  • 2 posts
  • Real Name:Emin

Posted 20 April 2012, 13:43

Thanks for share this addon
I installed last verison but i have problem that my first page and product page give me blank page.
Error of page in source web page is:
 <link rel="[url=""]stylesheet[/url]" type="[url=""]text/css[/url]" href="[url=""]<br />
<b>Fatal error</b>:  Call to undefined function tep_catalog_href_link() in <b>/home/sudmand/public_html/includes/template_top.php</b> on line <b>30</b><br />[/url]

includes/template_top.php at line 30 is:
<!--	start Product Fields group tab  -->
			<link rel="stylesheet" type="text/css" href="<?php echo tep_catalog_href_link('ext/jquery/ui/redmond/jquery-ui-1.8.19.custom.css'); ?>">
		<!--	end Product Fields group tab  -->
file "jquery-ui-1.8.19.custom.css" is aviable at same folder.

please help me.

Edited by ilyadgonbad, 20 April 2012, 13:43.


#51 thejudge99

  • Community Member
  • 30 posts
  • Real Name:Julian

Posted 23 April 2012, 17:42

Hi ilyadgonbad
this addon is written for 2.3.1 - i pressume you're trying it for an older version , one that doesnt have this function.

If that is the only error you have you could try hard coding the complette URL

<!-- start Product Fields group tab -->
<link rel="stylesheet" type="text/css" href="PATH_TO_MY_CSS/ext/jquery/ui/redmond/jquery-ui-1.8.19.custom.css">
<!-- end Product Fields group tab -->

where PATH_TO_MY_CSS is probably "catalog" - having never used an older version cannot say if that is the case.

If you do indeed have other errors then i would suggest upgrading your oscommerce.

Jules

Edited by thejudge99, 23 April 2012, 17:43.