OsCommerce – SMTP with authentication

OsCommerce – SMTP with authentication

Oscommerce SMTP Authentication with email format, this was the request from one of our clients. Yesterday, I were working on a project with older version of OsCommerce ( I know it is not great solution, but client is already using it for long time and don’t want to change)

The current installation had ‘sendmail’ configured that never worked as it was disabled at server level, oops 🙁

Instead of directly implementing anything, I found this add-on:  “smtp through the authentication smtp server

After installation, I was happy that it worked and I was able to set the smtp details but then starts the pain. All emails were being sent through SMTP, Great, but without formatting. Ok, I thought it could be email format issue. Set it to ‘text’ format, still same. Ok, set it as HTML, still same.

Now, it was time to look into the issue. After sometime of digging, I found an issue in email.php (includes/classes)

I commented few lines and added few in function send:

oscommerce-smtp

WOW, this fixed the problem of emails sent from store front, so same implementation was done in email.php in admin/includes/classes folder.

So Why, I am posting this simple fix; For the benefit of others. I tried to find some place at add-on download page but no place for comment or raise issue hence added it here.

The idea is simple, pay back to community whenever possible. My 2cents of contribution

Code as text:
/*if($body){
$message->setBody($body, 'text/html', CHARSET);
}
if($this->text){
$message->setBody($this->text, 'text/plain', CHARSET);
}
else{
$message->setBody($this->html_text, 'text/html', CHARSET);
} */
if(EMAIL_USE_HTML && $body){
$message->setBody($body, 'text/html', CHARSET);
}elseif( !EMAIL_USE_HTML && $body){
$message->setBody($body, 'text/plain', CHARSET);
}else{
$message->setBody($this->html_text, 'text/html', CHARSET);
}

Automatically Compiling SASS in Eclipse

Automatically Compiling SASS in Eclipse

We have been working SASS for some time and used to compile it using ‘watch’ option. It is not an ideal solution to run a daemon to monitor your sass/scss files. As we are working on Eclipse, why not leverage it to automate without use of the watch 🙂

Please read requirements section below to execute the process succesfully.

Builders in Eclipse

Eclipse has an option called Builders. Right Click on your Project -> Properties

Eclipse-Builder

 

Builder provides mechanism to allow compiling the code whenever required. Now in our case it is SASS and no builder is available for it.

How to solve this?

Simple!! Add a builder for your project.

Right Click Project -> Properties -> Builder -> Click ‘New’

Add-builder

Add External Program and set the settings similar to this (bear in mind this is for Linux, as I use Linux for development)

Sass-builder

Basically it is the command used to compile the SCSS/SASS file to CSS.

sass application/scss/app.scss:css/app.css

Set it to build with other files at various build options from the “Build Options” tab in Builder Configurations popup

Sass-Auto-build-options

That’s It. You are ready to use auto compiling SASS in Eclipse environment without watch.

 

What will happen if there is an error?

Error will flash in the console like in the screenshot below

Sass-error

 

 

Travel Deals – Booking.com

Travel Deals – Booking.com

A unique kind of assignment for us to provide travel deals from booking.com site. We had experience with another site under NDA (Non-Disclosure Agreement) for the integration so were able to do it as per expectations.

This was to generate the deals code for the deals so that it could be included in the Newsletter or other static information site.

getDeals

Screen takes input as city and number of deals to display. Default sort order is by Hotel Name but user can select Star rating, High to Low Percentage discount and Low to High Price.

 

 

 

 

 

deals

Deals for the city are listed with their respective prices and in the order needed. This application was not limited to these screens but has a background process too for staying updated for the hotel information and deals.

 

 

 

 

Feel free to reach us for your booking.com integration.

Beta roll-out of Invoice application

Hello All,

It brings immense pleasure to me to share roll-out of invoice application to facilitate task & invoice management.
Few of our clients have already received access details to the application and can view their respective invoices and statuses.
Others will be getting the access details soon.

Looking forward for feedback of the application and any new feature requests required to improve it further.

Thanks to all our clients to provide us opportunity to work with you!

Hardeep