Latest News: (loading..)


  • Content count

  • Joined

  • Last visited

1 Follower

About hubcat

  • Birthday 10/31/1965

Profile Information

  1. Hi There, I've been successfully using additional images v1 with ms2.2 for years now. I just upgraded from ms2.2 to rc2a and from mySQL 4 t5o mySQL 5. I couldn't upgrade to additional images v2 because I've completely restructured the product_info page and I couldn't get it to deconflict. v1 works fine from my customers perspective, but on the admin side, I can no longer upload new additional images. Here's the error messages I get when trying to add a second image (first one through normal OSC interface works fine, problem is when using the v1 "add image" button). Has anyone seen this before? I've posted the code snippets corresponding to the error messages at the bottom, but I realize it could actually be somewhere else. Any/all replys are appreciated - I've been working on this for many hours now, but my php and sql skills are both very limited. Thanks in advance! Adrienne Warning: array_merge() [function.array-merge]: Argument #2 is not an array in /home/mysite/admin/categories.php on line 440 Warning: reset() [function.reset]: Passed variable is not an array or object in /home/mysite/admin/includes/functions/database.php on line 55 Warning: Variable passed to each() is not an array or object in /home/mysite/admin/includes/functions/database.php on line 58 Warning: reset() [function.reset]: Passed variable is not an array or object in /home/mysite/admin/includes/functions/database.php on line 62 Warning: Variable passed to each() is not an array or object in /home/mysite/admin/includes/functions/database.php on line 63 1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ') values)' at line 1 insert into additional_images) values) categories.php line 440 code: case 'add_images': $products_id = $HTTP_GET_VARS['pID']; $add_images_error = true; if ($popup_images = new upload('popup_images', DIR_FS_CATALOG_IMAGES)) { $add_images_error = false; $sql_data_array = array('products_id' => tep_db_prepare_input($products_id), 'images_description' => tep_db_prepare_input($HTTP_POST_VARS['images_description']), 'popup_images' => tep_db_prepare_input($popup_images->filename)); $sql_data_array = array_merge($sql_data_array, $add_data_array); } if ($add_images_error == false) { tep_db_perform(TABLE_ADDITIONAL_IMAGES, $sql_data_array); } else { $messageStack->add_session(ERROR_ADDITIONAL_IMAGE_IS_EMPTY, 'error'); } tep_redirect(tep_href_link(FILENAME_CATEGORIES, 'cPath=' . $cPath . '&pID=' . $products_id)); break; database.php code: function tep_db_perform($table, $data, $action = 'insert', $parameters = '', $link = 'db_link') { reset($data); if ($action == 'insert') { $query = 'insert into ' . $table . ' ('; while (list($columns, ) = each($data)) { $query .= $columns . ', '; } $query = substr($query, 0, -2) . ') values ('; reset($data); while (list(, $value) = each($data)) { switch ((string)$value) { case 'now()': $query .= 'now(), '; break; case 'null': $query .= 'null, '; break; default: $query .= '\'' . tep_db_input($value) . '\', '; break; }
  2. Hi, I'm just now upgrading from 2.2 MS2 to 2.2 RC2a. I currently have QBI 2_10 working on MS2 with all the appropriate database adds. Do you happen to know if QBI 2_10 will still work on RC2a? What features this new version has over the old QBI? And most important, if I upgrade to this will it conflict at all with the years of data that has already been imported into QB? Any clarification so I can make a good choice going forward would be greatly appreciated. Thanks, Adrienne
  3. This was posted a year ago and I'm wondering if you ever got it fixed. This is what my hosts tech guys had to say: "It appears that the script you are calling (cron_update_bestsellers.php) is querying the systems default php settings rather than the php.ini within the same account/directory. I was able to run this by altering the system default for your VPS, however depending on the nature of any of your other scripts, this may cause them to behave in a manner not intended. Ideally, the script should be reading from the php.ini or the .htaccess file located in the same location, however I was not able to coax it to do so." So now I know what the problem is, but I have no idea how to fix it. This year-old post is the only one I could find on this topic. Thanks, Adrienne
  4. Greetings! :-) Like everyone else, I'm trying to do something specific. I need to continue to use multiple_dropdowns not sequenced drop downs, but I'm having issues with customers forgetting to set their preferences, so they buy whatever is the first item in the list and then return it - doubling my shipping costs. So... I'd like to add the "Please Select Option" tag line to the beginning of the multiple drop down boxes. I was able to hack in a change that mostly works and looks like this: ORIGINAL: $out.='<tr><td align="right" class=main><b>'.$attributes[$o]['oname'].":</b></td><td class=main>".tep_draw_pull_down_menu('id['.$attributes[$o]['oid'].']',array_values($attributes[$o]['ovals']),$attributes[$o]['default'], "onchange=\"stkmsg(this.form);\"")."</td></tr>\n"; CHANGE: $out.='<tr><td align="right" class=main><b>'.$attributes[$o]['oname'].":</b></td><td class=main>".tep_draw_pull_down_menu('id['.$attributes[$o]['oid'].']',array_merge(array(array('id'=>0, 'text'=>'Please Select a '.$attributes[$o]['oname'])), $attributes[$o]['ovals']),$attributes[$o]['default'], "onchange=\"stkmsg(this.form);\"")."</td></tr>\n"; Unfortunately, now the default first line creates an Out of Stock message, so that it looks like the entire product is out of stock. Here is the full code for the menu creation: string: HTML to display dropdown lists for attributes that stock is tracked for */ function _draw_stocked_attributes() { global $languages_id; $out=''; $attributes = $this->_build_attributes_array(true, false); if (sizeof($attributes)>0) { for($o=0; $o<sizeof($attributes); $o++) { $s=sizeof($attributes[$o]['ovals']); for ($a=0; $a<$s; $a++) { $attribute_stock_query = tep_db_query("select products_stock_quantity from " . TABLE_PRODUCTS_STOCK . " where products_id = '" . (int)$this->products_id . "' AND products_stock_attributes REGEXP '(^|,)" . (int)$attributes[$o]['oid'] . "-" . (int)$attributes[$o]['ovals'][$a]['id'] . "(,|$)' AND products_stock_quantity > 0"); $out_of_stock=(tep_db_num_rows($attribute_stock_query)==0); if ($out_of_stock && ($this->show_out_of_stock == 'True')) { switch ($this->mark_out_of_stock) { case 'Left': $attributes[$o]['ovals'][$a]['text']=TEXT_OUT_OF_STOCK.' - '.$attributes[$o]['ovals'][$a]['text']; break; case 'Right': $attributes[$o]['ovals'][$a]['text'].=' - '.TEXT_OUT_OF_STOCK; break; } } elseif ($out_of_stock && ($this->show_out_of_stock != 'True')) { unset($attributes[$o]['ovals'][$a]); } } $out.='<tr><td align="right" class=main><b>'.$attributes[$o]['oname'].":</b></td><td class=main>".tep_draw_pull_down_menu('id['.$attributes[$o]['oid'].']',array_values($attributes[$o]['ovals']),$attributes[$o]['default'], "onchange=\"stkmsg(this.form);\"")."</td></tr>\n"; } $out.=$this->_draw_out_of_stock_message_js($attributes); return $out; } } So... I think I need to wrap some sort of if statement around that last line. In pseudo code: if (a product has been selected and not the text line) $out.=$this->_draw_out_of_stock_message_js($attributes); I could provide the draw_out_of_stock_message_js code if needed. It could probably be done there as well, but this post is already so long...
  5. I'm working with OSC2.2ms2. I have almost 20 contributions added and had to pay someone to fix some bugs that I couldn't workout myself. The entire checkout system is custom for my specific needs, and not even a contribution. So... my store is completely stable at the moment, is there a compelling reason to upgrade to OSC3.0? In truth, I can't think of one, but I'm open to opinions. Thanks, Adrienne
  6. PLEASE HELP I've been using 4.2 for nearly 2 years. It has had the same error ever since I installed it. If someone purchases 3 different items, the first one is deducted from stock and the second two are not. Always just the first one is deducted, never any past the first. I tried to fix this way back when but couldn't get any help and never got it working. But the store was only getting 1 or 2 orders a week, so I would adjust manually. Now the store gets about 15 orders a week, and I just don't have time to adjust manually. I've gotten bitten a few times as well. So, I just upgraded to 4.3 hoping it had been fixed in the meantime, and no luck. I have the exact same problem. For my configuration, absolutely nothing changed from 4.2 to 4.3 except the admin reports section. For reference, most of my items have 2 stock-tracked attributes and 1 non-stock attribute. Any suggestions?? I've spent hours on this, and I'm desperate! :'(
  7. Ok, I just deleted that line, and everything worked fine. Go to admin -> includes -> boxes -> reports.php and change: '<a href="' . tep_href_link(FILENAME_STATS_LOW_STOCK_ATTRIB, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_REPORTS_STATS_LOW_STOCK_ATTRIB . '</a><br>'. '<a href="' . tep_href_link(FILENAME_STATS_LOW_STOCK, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_REPORTS_STOCK_LEVEL . '</a>'); to: '<a href="' . tep_href_link(FILENAME_STATS_LOW_STOCK_ATTRIB, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_REPORTS_STATS_LOW_STOCK_ATTRIB . '</a>'); That seemed to work for me. Good luck, Adrienne
  8. Darren, Yes, there's one more thing you should do - go back to your google account and check under the My Account -> My Items -> Bulk Feed (or something similar) setting. It will show you the date of the last bulk upload, so you can verify that it really did upload correctly AND it will tell you if there was a problem. If google likes it, your items will show up automatically on base. If they don't, they will give you a message on that screen. Then you're done. Adrienne PS - Still looking for an answer on how to mod the code to show only the lowest level category for Product_Type. Any suggestions??
  9. By the way, looks like you are using an older version of this contribution. Your filename should be googlefeeder.php, not froogle.php. Google won't accept the old froogle format any more, so you have to install the latest version. Adrienne
  10. It looks like your problem is that you've named the ftp server FROOGLE_FTP_SERVER in the upfront section. If you're trying to post to google, their bulk upload server is named Log on to your google account and it will show you your server name (should be, but maybe they have more than one), your login id and you can check or change your login password. All those variables must be set in the googlefeeder.php file. Adrienne
  11. Hi, This is a fabulous contribution, and it's working perfectly. Many thanks to those involved in making it available. I'm trying to change the category output to show just the lowest level category. So instead of a output like this: Top Category, Sub Category 1, Sub Category 2 Top Category Top Category, Sub Category 1 I just want it to show this: Sub Category 2 Top Category Sub Category 1 In my case, that is much more descriptive of what I'm selling than the full list. The problem is that I'm a total php novice. I can recognize that this is the code that is generating the data, but I can't figure out what to change to output just the last category. Any suggestions? function findCat($curID, $catTempPar, $catTempDes, $catIndex) { if( (isset($catTempPar[$curID])) && ($catTempPar[$curID] != 0) ) { if(isset($catIndex[$catTempPar[$curID]])) { $temp=$catIndex[$catTempPar[$curID]]; } else { $catIndex = findCat($catTempPar[$curID], $catTempPar, $catTempDes, $catIndex); $temp = $catIndex[$catTempPar[$curID]]; } } if( (isset($catTempPar[$curID])) && (isset($catTempDes[$curID])) && ($catTempPar[$curID] == 0) ) { $catIndex[$curID] = $catTempDes[$curID]; } else { $catIndex[$curID] = $temp . ", " . $catTempDes[$curID]; } return $catIndex; } $catIndex = array(); $catTempDes = array(); $catTempPar = array(); $processCat = mysql_query( $catInfo )or die( $FunctionName . ": SQL error " . mysql_error() . "| catInfo = " . htmlentities($catInfo) ); while ( $catRow = mysql_fetch_object( $processCat ) ) { $catKey = $catRow->curCatID; $catName = $catRow->catName; $catParID = $catRow->parentCatID; if($catName != "") { $catTempDes[$catKey]=$catName; $catTempPar[$catKey]=$catParID; } } foreach($catTempDes as $curID=>$des) //don't need the $des { $catIndex = findCat($curID, $catTempPar, $catTempDes, $catIndex); } Thanks a bunch! Adrienne
  12. I am running an older version of QT Pro and it has this problem. I've been adjusting stock manually, but finally got to the point where I'm getting so many orders it's no longer feasible, so came to see if there was a fix. In my case, it tracks stock accurately when someone buys any number of a single item. However, if they buy 2 or 3 different items, only the first one is subtracted from inventory. The rest stay in inventory. For reference, most of my items have 2 stock-tracked attributes and 1 non stock-tracked attribute. I never seem to do well at searching these forums, so if this has been answered already, would someone mind pointing me in the right place, I can't seem to find it. Thanks! Adrienne
  13. Oops, posted twice. Sorry, Adrienne
  14. Hi Mark, Can you explain where (well, how really) the sesskey field should be added to the database? Also, is this a problem with v3.2b if we add the security update? Thanks, Adrienne
  15. Ok, figured out #1 - it was actually sorting by best sellers, but since I hadn't figured out how to manually initiate the cron job, there weren't any bestsellers, and then it went z to a. #2 - Still no idea on this one, any help? Thanks, Adrienne