Anthony Sidashin

Anthony Sidashin

As a web developer and CTO with over 15 years of experience, I am passionate about building profitable small SaaS products and pursuing Go-to-Market strategy for them. My areas of expertise include high performance, networking technology and APIs, SRE, automation using Puppeteer.js, web scraping, and SQL databases.

Using Ubercart to sell files: ui improvements and creating file feature programmatically

uc_file module that allows selling files in Ubercart is definitely not perfect in terms of API, but it is a nice piece of functionality. We've just finished creating one e-book store which has product-import feature. Each product has multiple formats (pdf, epub, rtf) - some products can have pdf+epub, some can have just pdf, others have all three formats attached. On product page, we wanted to show nice block like this: where pdf and doc are just text for regular users, and download links for

3 min read

Calendar with highlighted dates

In Drupal 7, it's easy to show calendar (ui.datepicker) date selector to user. (it's not hard in Drupal 6, too - but in d6 you need to enable http://drupal.org/project/jquery_ui to get the calendar, I think) You just write several lines of js code, and you get a calendar. But things are quickly getting more complicated when you need to allow visitors to choose from dates that have some nodes "attached" to them only. E.g. if you have news view, and you don't have news for 13 Nov 2011, there is n

3 min read

Writing robust code that uses fields, in Drupal 7

In Drupal 7, the direct access to entity fields (CCK in d6) is different. In Drupal 6 you write: field_yourfield[0]['value']; ?> in Drupal 7 you have to write: field_yourfield[LANGUAGE_NONE][0]['value']; ?> (this is a way suggested by core docs). So, we have different languages here now. I haven't built any d7 multilanguage websites yet, so I don't know if that approach makes it really easy to create language-aware code for i18n webs

4 min read

Commerce Product Constructor

Today I've made another decision to postpone using Commerce in our project where customer needed simple e-shop. I've actually made such decisions several times already, and that makes me feel unhappy. I would like to say that I really enjoy Commerce presentations, (like everyone of you, huh?), and test installations are working great! The idea of Drupal-way, and Rules, and Views-everywhere rocks. But... Commerce is being developed for a long time already, and you still can't show it to your cus

4 min read

Additional CCK powered price for product in Ubercart

I was not updating my blog for a while - it's summer here :) I've just returned back from my business trip to US, Alaska, where I helped guys from shipito.com killer to automate their warehouse and create good user control panel in their website (everything is Drupal-powered here!). I've also spent several days surfing in San Diego. It's so exciting to realize that Drupal knowledge can give you an opportunity to visit such amazing places and meet interesting and smart people all over the world!

2 min read

CSRF: Avoid security holes in your Drupal forms.

While everyone is now aware of SQL injections and 99% of Drupal developers now use placeholders in their db queries, some of other important security aspects are often forgotten. Today I've encountered another example of CSRF (Cross-site request forgery in Wikipedia) in Drupal contributed module. It's so easy to create a CSRF security hole while creating a module. Here is the short description of the issue. Some module manipulates the list of custom items, say, user can create lots of 'fruit'

2 min read