osHelpers - Help for your osCommerce store
 
oscommerce Seo
  Seo Pack 2
  SE Friendly URLs
  Session ID Removal
  Title and Meta Tags
  Google Sitemap
Magnum Shopping Cart
  Magnum Light
  Magnum Multi Store
  Magnum MVS Basic
  Magnum MVS Advanced
osCommerce Services
  osc / cre patch
  Data Entry
  Data Extraction
  bugs and fixing
  Site Transfer
  creloaded Transfer
  Design Special
  Hosting
osCommerce Templates
osCommerce Contributions
  Credit Modules
  Features
  Images
  InfoBoxes
  Languages
  Order Total Modules
  Other
  Payment Modules
  Reports
  Shipping Modules
  Templates/Themes
  Zones
osCommerce Articles
osCommerce Tutorials
  Installing osCommerce
  Configuring your store
  Adding categories
  Adding products
  Adding product attributes
  Configuring currency
  Adding payment modules
  Adding shipping modules
  Configuring sales tax
  Editing your home page
  Editing columns
  Editing header and footer
  Creating specials
  Managing customers
  Sending out a newsletter
  Sending out email
  Managing your banners
  Backup database
CRELoaded Tutorials
  Add Administrators
  Add Article Author
  Additional Images
  Create a New Page
  Define Mainpage
  Disable cc Encryption
  Disable Company Field
  Disable Country
  Disable Date of Birth
  Display broken images
  Easypopulate Export
  Email confirmation
  Insert Faq
  Max Package Weight
  Require Terms of Use
  Affiliate Newsletter
  Enable Cache
CB Power Affiliate
Tell A Friend
 

Tell someone you know about this product.

   OSHELPERS | OSCOMMERCE CONTRIBUTIONS | IMAGES | 1029   


oscommerce imagechmodfix
[1029]
 
 
box_bg_l.gif.
"this fix was posted by fmahannah. I had nothing to do with it. however, i don't think anyone posted it as a contribution and let's face it, you have to hunt to find it, so i decided to paste it.

No need to download, cuz here goes.

edit the function tep_copy_uploaded_file in admin/includes/functions/general.php

Find the function tep_copy_uploaded_file and where it now shows:


function tep_copy_uploaded_file($filename, $target) {
if (substr($target, -1) != '/') $target .= '/';

$target .= $filename['name'];

move_uploaded_file($filename['tmp_name'], $target);
}


Change it to:

function tep_copy_uploaded_file($filename, $target) {
if (substr($target, -1) != '/') $target .= '/';

$target .= $filename['name'];

move_uploaded_file($filename['tmp_name'], $target);
// Added by F Mahannah to fix permissions on uploaded files which were being set to 600
chmod($target, 0644);
}


point is, it will change the chmod to something OTHER than 600. which means we'll all be able to back up our images, which we haven't been able to do in the past."

 


For more information, visit the official osCommerce contribution webpage.
box_bg_r.gif.
 

osHelpers

osHelpers