CVS edit link for sri20198

I plan to make a module contribution -

Reseller Club Domains Name Availability Check: A block module that integrates domain name check form to Reseller Club Supersite.

Reseller Club (http://www.resellerclub.com) is a leading Domain Name Registrar with a reseller business model. They provide each reseller with an integrated control panel that can check domain name availability, get Promo prices (if any), make online payments (through multiple gateways), register domain name, as well as transfer the domain name. This control panel can be completely re-branded (white label) by resellers. The white label sites are called SuperSites.

One of the most used functionalities of the toolset is the domain name availability check. Reseller Club provides a simplified HTML form, that resellers can use in their own website to allow their users to check for the availability of domain names (refer the form code at http://manage.resellerclub.com/kb/servlet/KBServlet/faq1137.html). On submission of this form, the values are submitted to the Reseller's SuperSite that makes a check on the availability of the domain and returns the results along with other suggestions.

With more and more sites adopting the CMS way, a plug-n-play module for Reseller Club domain name availability check takes the pain away. This module creates a block with the domain name check form that the site admin / manager can place in any region of their site. The site admin can configure the SuperSite URL and the list of TLDs that they sell on their SuperSite. The users just need to enter the desired domain name, select the TLD and click on Search button.

See a demo at http://echopx.com/web-hosting (in the right sidebar area).

I had the first taste of Drupal about a year ago and have been hooked since then. I have worked on quite a few client projects involving themeing, module / site configuration, as well as writing custom modules. In a particular case, we have extended the Drupal site to a custom Zend Framework driven application. The clients (for Drupal projects) have ranged from Real Estate Agents, Online Taxation Consultants, Schools to Non-profit organizations.

CommentFileSizeAuthor
#1 resellerclub_domains.zip3.8 KBsri20198

Comments

sri20198’s picture

Status: Postponed (maintainer needs more info) » Needs review
StatusFileSize
new3.8 KB
avpaderno’s picture

Issue tags: +Module review
joachim’s picture

Status: Needs review » Needs work

Module in general looks ok.

Some code style problems and other minor issues though:

- indentation is wrong in a lot of places, as well as opening / closing braces

- don't put a blank line between function doc block and declaration

- all functions should have a doc block

- check coding conventions for if/elseif statements and foreach statements.

- all functions should start with your module name. _trim_value could potentially clash. Though for a one-line function, do you really need array_walk or would a foreach do?

- setting a variable in hook_install() is not really a pattern seen in Drupal. Arguably, it's cleaner DX than hardcoding the default every time you variable_get(). Nonetheless, the latter approach keeps the variable table cleaner :)

- "* installation of schema for domain tlds" -- that comment is only true if you have a hook_schema ;)

- resellerclub_domains_renderform -- unusual function name. the 'render' part is a bit odd. maybe resellerclub_domains_block_form or something like that?

- foreach($tlds as $k => $v) { -- in general we avoid cryptic variable names in Drupal; I'd use something like $value here. Also, you're not using the key here so you could just skip the $k part.

- $form['#action'] = $supersiteurl.$supersite_ext; -- this could use a comment to explain to other developers that the form submission happens off-site. Also, note coding conventions for the . operator.

- '#default_value' => $tld_options_arr[0], -- not sure you need this. check what happens without it ;)

- '#type' => 'hidden', - IIRC hidden is obsolete in D6. However, if you need these for the remote form submission, maybe add a comment to say so?

avpaderno’s picture

Status: Needs work » Closed (won't fix)