Congratulations and how to contribute?

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
15 years ago
First of all, congratulations on a great project.

Of a number of solutions your project is the best in combining a lot of the common features required in an ecommerce solution but in a way that is easy to understand and develop with.

I installed nopCommerce last night and after a few hours playing had a number of feature requests / suggestions - however, I realise most of these are now going to be included in the next release :D

I'm sure your Developer documentation will explain this when it arrives, but I wonder how we can start contributing to the project. A key thing for me would be to create some new themes for the example site (as I see you are changing to a css based layout in the new version).

Also someone had posted about keeping the image aspect ration when using the PhotoManager method. When resizing an image, rather than explicitly setting the height / width, I always specify just one value, then let the method below work out how to do the resizing (based on the images orientation):

    
private static Size CalculateDimensions(Size oldSize, int targetSize)
    {
        Size newSize = default(Size);
        // portrait
        if ((oldSize.Height > oldSize.Width))
        {
            newSize.Width = (int)(oldSize.Width * (float)(targetSize / (float)oldSize.Height));
            newSize.Height = targetSize;
        }
        else
        {
            newSize.Width = targetSize;
            // landscape
            newSize.Height = (int)(oldSize.Height * (float)(targetSize / (float)oldSize.Width));
        }
        return newSize;
    }


So you can call this function in any method that requires resizing. I think it would be quite good to configure the different image size properties within the admin gui so that the site administrators can easily change the size that images are uploaded to.

I use a similar technique in another project like below:


                                           ResizeImageFile(bytesOriginal, Globals.Settings.Photos.ImageLargePixels),
                                           ResizeImageFile(bytesOriginal, Globals.Settings.Photos.ImageMediumPixels),
                                           ResizeImageFile(bytesOriginal, Globals.Settings.Photos.ImageSmallPixels),


So you could give users the ability to set up a size for Thumbnails, Medium and Large sized images.

Thanks again,

Ben
15 years ago
Thanks!

Now if you want to contribute to the proejct, send new modules/updates/files to am[at]nopCommerce[dot]com
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.