Tuesday, June 29, 2010

Spring Framework AspectJ Annotations

For defining aspects, Spring leverages the set of annotations
provided by AspectJ.


Annotation
Use
Description

@Aspect Type Declares a class to be an aspect.

@After Method Declares a method to be called after a
pointcut completes.


@AfterReturning
Method Declares a method to be called after a
pointcut returns successfully.


@AfterThrowing
Method Declares a method to be called after a
pointcut throws an exception.



@Around Method Declares a method that will wrap the
pointcut.



@Before
Method Declares a method to be called before
proceeding to the pointcut.

@DeclareParents Static Field Declares that matching types should be
given new parents—that is, it introduces new
functionality into matching types.


@Pointcut Method Declares an empty method as a pointcut
placeholder method.

Sunday, June 27, 2010

Installing MySQL on a Mac

You can download the the latest version of mysql on following site :
http://dev.mysql.com/downloads/

Download the "mysql-standard-ver­sion-osxversion-platform.dmg".

Double-click the disk image to mount it, double-click the installer,
and get installing!

After the installation done, we need to start the mysql server mannually.
For that open the terminal window and enter following command :

$ sudo /usr/local/bin/mysqld_safe5

Once MySQL is running, you can tell it to run in the background by hitting Ctrl-
Z, then entering this command:

$ bg


Now you can close the terminal window, if you want to check whether mysql server
is up and running please have following command :

$ ps -ax | grep mysql

This command should return a few processes that relate to MySQL.

Finally we need to connect MySQL database, please have following command :

$ mysql5

Hiding Files In an Image

 

Step 1

Create a folder on your hard drive, eg. C:\Test and put in all of the files that you want to hide into that folder. Also, place the image that you will be using to hide the files in.

Step1PNG

Step 2

Now select all of the files that you want to hide, right-click on them, and choose the option to add them to a compressed ZIP or RAR file. Only select the files you want to hide, not the picture. Name it whatever you want, eg. “nexus.rar”.

Step2

Now you should have a folder that looks something like this with files, a JPG image, and a compressed archive:

After Step2PNG

Step 3

Now here’s the fun part! Click on Start, and then click on Run. Type in “CMD” without the quotes and press Enter. You should now see the command prompt window open. Type in “CD \” to get to the root directory. Then type CD and the directory name that you created, i.e. “CD Test“.

Now type in the following line: copy /b <image file name> + <archive file name> <image file name>” and press Enter. You should get a response like below:

Step3

And that’s it! The picture file will have been updated with the compressed archive inside! You can actually check the file size of the picture and see that it has increased by the same amount as the size of the archive.

After Step3

Extracting

You can access your hidden file in two ways. Firstly, simply change the extension to .RAR and open the file using WinRAR. Secondly, you can just right-click on the JPG image and choose Open With and then scroll down to WinRAR. Either way, you’ll see your hidden files show up that you can then extract out.

Step4

AfterExtractingPNG

That’s it! That is all it takes to hide files inside JPG picture files! It’s a great way simply because not many people know it’s possible and no one even thinks about a picture as having to the ability to “hide” files. Cheers!

Wednesday, June 23, 2010

What is WAP?

What is WAP?
WAP is a standard to show internet contents on wireless clients, like mobile phones.
WAP is for handheld devices such as mobile phones
WAP is a protocol designed for micro browsers
WAP enables the creating of web applications for mobile devices.
WAP uses the mark-up language WML (not HTML)
WML is defined as an XML 1.0 application


WAP Micro Browsers

To fit into a small wireless terminal, WAP uses a Micro Browser.

A Micro Browser is a small piece of software that makes minimal demands on hardware, memory and CPU. It can display information written in a restricted mark-up language called WML.

What is WML?

WML stands for Wireless Markup Language. It is a mark-up language inherited from HTML, but WML is based on XML, so it is much stricter than HTML.

WML is used to create pages that can be displayed in a WAP browser. Pages in WML are called DECKS. Decks are constructed as a set of CARDS.

Example WML document:

"http://www.wapforum.org/DTD/wml_1.1.xml">



Our HTML Tutorial is an award winning
tutorial from W3Schools.





In a WAP browser screen only one card is displayed at a time.

WMLScript can apply for client side scripting like JavaScript for HTML and for styling WCSS is used.

Monday, June 21, 2010

Google Chrome 5 Vs Apple Safari 5

Testbed

-Intel Core2Duo T5800 2.00Ghz

-4GB DDR2 Ram 800mhz

-Intel Graphic Accelerator 4500MHD

-Windows 7 Ultimate 64bit

-RAM Usage 1.37 GB before test

SunSpider JavaScript Test

image

V8 Benchmark Suite - version 5

  • Richards
    OS kernel simulation benchmark, originally written in BCPL by Martin Richards (539 lines).
  • DeltaBlue
    One-way constraint solver, originally written in Smalltalk by John Maloney and Mario Wolczko (880 lines).
  • Crypto
    Encryption and decryption benchmark based on code by Tom Wu (1698 lines).
  • RayTrace
    Ray tracer benchmark based on code by Adam Burmister (935 lines).
  • EarleyBoyer
    Classic Scheme benchmarks, translated to JavaScript by Florian Loitsch's Scheme2Js compiler (4685 lines).
  • RegExp
    Regular expression benchmark generated by extracting regular expression operations from 50 of the most popular web pages (1614 lines).
  • Splay
    Data manipulation benchmark that deals with splay trees and exercises the automatic memory management subsystem (378 lines).
  image image

PeaceKeeper Browser Benchmark

image

 

image

Installing RubyGems on a Mac

What is RubyGems ?

RubyGems is a utility for managing the additions to the Ruby programming language that other people have developed and made available as free downloads.

Try following commands to install rubygems :

$ curl -L \

http://rubyforge.org/frs/download.php/11289/rubygems-0.9.0.tgz \

| tar xz

$ cd rubygems-0.9.0

$ sudo ruby setup.rb

$ cd ..

===================================================================

Now we have installed rubygems to check whether it is working, have
following command :

$ gem -v

The output should identify the version of RubyGems that you installed.

~ Good luck ~

Ruby - OOP

Ruby is a 100% object oriented programming language. When i make this statement you may question me "Your now saying the Ruby is a 100% oop language, but you haven't create a even single object in your hello world demo? ". Here is the answer.

puts "Hello World";

When you run the above code a default main object is created on the memory and puts method is invoked with "Hello World" argument.

Now i briefly explain how to create your own class, method and object.

class MyClass
def saysomething
puts("Hello")
end
end

my_class = MyClass.new
puts my_class.class
my_class.saysomething

Not on the code
-----------------
* class declaration started by class MyClass and ends with end.
* methods are declared using def keyword following method name, ends with end.
* Object is created by invoking the new method of the class. new method is inherited from top most parent class.

Sunday, June 20, 2010

How to install a plugin in Joomla 1.5?

The installation of additional plugins in Joomla 1.5 is quite easy.

Download the plugins from following url

http://www.joomlaport.com/

  • All you have to do after downloading the component you wish to install is go to your Joomla admin area > Extensions > Install/Uninstall.

  • In the Upload Package File section click Browse and locate the archive of the plugin you wish to install.

  • Then click Upload File & Install to upload the file and complete the installation.

You can install components this way: Go to Administrator site in your Joomla! 1.5 site, then select Extensions - Install/Uninstall - Upload Package File - Upload File & Install.

Hope this will get helpful..

Learn Ruby - String Manipulation

Converting to upper case
puts 'Hello, World'.upcase

Getting command line input
print 'Enter your name : '
name = gets
puts "Hello #{name}"

Calculation and Print
# This is a comment
#{This is a comment}
puts("\n\t#{(1+2)*3}")

Installing Ruby on a Mac

On Mac, Ruby depeds another library called Readline.
Here the steps for installing ruby on mac :
============================================================================


curl ftp://ftp.gnu.org/gnu/readline/readline-5.1.tar.gz | tar xz

cd readline-5.1

./configure --prefix=/usr/local

make

sudo make install

cd ..

============================================================================

now we can install ruby without any problem...

try following commands to install ruby :

============================================================================

curl -O ftp://ftp.ruby-lang.org/pub/ruby/1.8/ruby-1.8.6.tar.gz \

| tar xz

$ cd ruby-1.8.6

$ ./configure --prefix=/usr/local --enable-pthread \

--with-readline-dir=/usr/local

$ make

$ sudo make install

$ sudo make install-doc

$ cd ..

===================================================================

Now we are done. try to have "ruby -v" on terminal.

$ ruby -v


~ good luck ~

Why I don’t like the new 4G iPhone

 

Article-teaser-4G-iPhone-mockup-Designed-by-Item-front

So you guys heard? The new iPhone is here. It’s Called 4G iPhone. Definitely it is an very good improvement over the last iPhone (iPhone 3GS) that came out. Since the launch, apple – iPhone is at the tip0 of their tounges. But wait? Why doesn’t Steve Jobs skip past the negatives or provide kiddy answers to some questions?

Launch failure !

At first let’s start off with the launch. A mega event with thousands of people.

Steve Jobs presenting 4G iPhone :Is he serious?

The event was well covered by the press so naturally there were huge number of Wi-Fi stations. When the iPhone couldn’t connect to any W-Fi access points because there were so many Steve Jobs asked the audience to switch off their notebooks and shutdown Wi-Fi base stations. But lets get this scenario, where you want to use your shiny 4G iPhone in an airport where there is more interference than 572 Wi-Fi base stations. My question to Apple is whether you guys have tested that kind of scenarios. The second incident is when iPhone refused to connect to the service provider. So it means that when there is a lot of interference iPhone is a sitting duck.

About FaceTime

facetime

Apple FaceTime is the 4G iPhone’s new video calling software. Yeah it does bring loved ones to your home. But what’s the point if it only operates on Wi-Fi. Maybe Apple has designed the phone for a futuristic movie. I mean seriously when is the last time you got a Wi-Fi signal when you were in a bus. Even the “FaeTime” froze in the demo launch. The new FaceTime feature could only be used in limited places (where there’s an access point).

The “Beautiful” glass covering

iphone-4-glass-shattered

Yes yes that could have been your 4G iPhone. The iPhone is a beautiful phone without a doubt. But that’s what could happen and the beauty becomes a useless beast. The iPhone’s glass is covered by Alumino Silicate glass which is the type in high speed trains and said to be 30times tougher than plastic. But after 3 drops at 3.5 feet above is the result. By no means I wouldn’t question Apple’s design decision; but it’s up to the consumer to decide whether he could protect a phone from ever dropping in it’s life time.  The result looks just like a damaged windscreen. The replacement screen from Apple would burn a hole in your pocket. If there was minor damage we could have used the phone; but here in this case it is frankly unusable.

Flash is non-existent

iphone_flash

Those of you buying an 4G iPhone surely would visit web sites with Flash. But sadly iPhone not only it doesn’t support Flash it constrains developers to come up with an alternative too. Flash is still going strong. And let’s say there is a Youtube client, but that’s only 40% of the web’s videos. Hulu is designed in Flash in mind.Just because iPhone doesn’t use Flash content can’t change to apple’s format. Apple’s  alternative to Flash is HTML5. But let me ask you a question? What is more easy to draw a square for Web 2.0 media content.

Drawing it visually in Adobe Flash Suite

or

function draw_b() {
var b_canvas = document.getElementById("b");
var b_context = b_canvas.getContext("2d");
b_context.fillRect(50, 25, 150, 100);
}


That’s what you get when you view Flash content in all iPhones.



So there now you would think twice before buying a 4G iPhone. Just because it’s shiny and Steve Jobs tell fairy tales of it you shouldn’t buy it.




http://techxer.wordpress.com

Spring Framework Context Configuration Annotations

These annotations are used by Spring to guide creation and injection of beans.

Annotation
Use
Description

@Autowired Constructor,Field,Method Declares a constructor, field, setter method,
or configuration method to be autowired by
type. Items annotated with @Autowired do
not have to be public.

@Configurable
Type Used with to
declare types whose properties should be
injected, even if they are not instantiated by
Spring. Typically used to inject the properties
of domain objects.


@Order Type,
Method,Field Defines ordering, as an alternative to
implementing the org.springframework.core.
Ordered interface.

@Qualifier Field,
Parameter, Type,Annotation Type Guides autowiring to be performed
by means other than by type.


@Required Method (setters) Specifies that a particular property must be
injected or else the configuration will fail.


@Scope Type Specifies the scope of a bean, either
singleton, prototype, request, session, or
some custom scope.


Thursday, June 17, 2010

How the linux kernal works

The kernel is a piece of software that, roughly speaking, provides a layer between the hardware and the application programs running on a computer. In a strict, computer-science sense, the term 'Linux' refers only to the kernel - the bit that Linus Torvalds wrote in the early 90s.

All the other pieces you find in a Linux distribution - the Bash shell, the KDE window manager, web browsers, the X server, Tux Racer and everything else - are just applications that happen to run on Linux and are emphatically not part of the operating system itself. To give some sense of scale, a fresh installation of RHEL5 occupies about 2.5GB of disk space (depending, obviously, on what you choose to include). Of this, the kernel, including all of its modules, occupies 47MB, or about 2%.

Wednesday, June 16, 2010

Start learning Ruby- Installation and Introduction

         Ruby is a programming language which were born in Japan and Japanese human language and adopted to English.

Rather than telling about history I'll move to practical stuff now.

Installing Ruby

If your using Windows OS download the setup from http://www.ruby-lang.org/en/downloads/ else if your using Linux OS install using "yum install ruby"
 In Windows you may need to add the RUBY_PATH to classpath enviornment variable.
Once you have installed the rupy you can check it using following command by opening your terminal.
ruby -v

Hello World Program
Here we are going to run our first hello world program
Open your favorite text editor
Here is the butyl, you may remember your first Java/c#/etc Hello World program which having more than 4 lines. See the ruby hello world
Type following code:
puts "Hello World";
Save it as any name you wish(mine is first.rb) with .rb extension.

From your comman prompt/terminal cd to the file location execute using following command,
$> ruby first.rb
This print 'Hello World' on your terminal.
Thats it for the moment in future i'll come up with some more ruby programming.

How install Maven plugin to Eclipse

Debian Linux Kernel Compilation

Power using Skype

 

Starting Simple: Built-In Skype Features you Didn’t Know About

Skype is such a rapidly emerging technology that a lot of brand new users aren’t even aware of all the built-in features that Skype offers standard, not to mention the add-ons and hacks that you can improve it with. In this section we cover some often overlooked standard features of Skype that can dramatically improve your experience.

1 Call Forwarding

    Whether you’ve set your Skype account up on your home or work computer, the fact is, you are occasionally going to get important calls when you aren’t there. Thankfully, you can simply forward those calls to another Skype account or even a cell phone or land line. That way, even if your computer at work is shut down, as soon as a call comes in to your Skype account, the call will immediately ring on your cell phone, your home computer and your home phone line, meaning that no matter where you are you’ll be sure to get it. To forward a call click on the “Tools” menu and select “Options.” From there set the forwarding number in the “Call Forwarding & Voicemail” section.

2 Filtering and Blocking Users

    Skype is a great tool for both business and pleasure, but if you don’t take preventative steps, it can also cause you some serious security problems. VoIP Phishing also known as Vishing  is a new VoIP targeted scam in which cyber-criminals use a VoIP client such as Skype to call people and attempt to trick them into revealing important financial details such as credit card numbers or online passwords. But you can limit these attacks by simply blocking unwanted callers. To block unknown or unwanted callers, simply click on “Tools” and select “Options.” From there, select “Privacy” and choose the level of security that works best for you. When it comes to individual attacks, you can avoid repeat vishing calls by blocking the spammer by clicking on “Manage Blocked Users” in the “Options” dialog.

3 A DIY Home Security System

    Whether you want to keep an eye on your pet goldfish from work or just make sure no one has broken in the house while you are on vacation, Skype can double as an away from home monitoring system. Checking in is simple with Skype’s one and two way video calling. You’ll need two separate Skype accounts, a computer at home with a webcam, and access to the Internet. Using one account, setup the home version of Skype to auto-answer calls and automatically fire up the webcam. Then to check in, just use the second Skype account to call the first, and the webcam video will pop up.

4 Providing Customer Support

    Got a small business online? Want to offer some customer support without spending a fortune on telephony costs? Skype’s graphical click-to-call SkypeMe buttons are ideal for this. Create your SkypeMe button (free account needed) and embed the code in your website, weblog, template, email, or wherever you want it to appear. When someone views your web page (or email message), the button will indicate whether you are online and accepting Skye calls, busy, or offline. If you’re on the go and want to receive calls, just leave your Skype client running and set call forwarding (see above).
Plugins, Addons, and Extras

Think of the off-the-shelf version of Skype as a new car without any optional package. Sure, it will still get you to and from work, but it doesn’t have any of the bells and whistles that make your new toy exciting. Unlike car options, however, these Skype Plugins and Add-ons won’t cost you a fortune, and they’re easy to install to boot.

5 Using Skype to Sell your Services

    You’ve got information that other people can use, and with the Bitwine Skype add-on you’ll be able to leverage that information into an income stream. Whether you’re a lawyer, a mechanic, or a talented collector, there are people willing to pay for the information you have, and using Bitwine makes selling that information easy. Through Bitwine, you set up your hourly rate, then customers approach you about the topic they would like to discuss, you set up a meeting time, and at the end of the meeting Bitwine tallies up the time and will even coordinate payment via PayPal through another add-on, Bitwine extra.

How to Install Maven in Linux

Its really simple


  • You can download a binary release of Maven from http://maven.apache.org/download.html.

  • Exact it and copy it to the /usr/local

  • Use following steps

    • /usr/local % cd /usr/local
    • /usr/local % ln -s apache-maven-2.2.1 maven
    • /usr/local % export M2_HOME=/usr/local/maven
    • /usr/local % export PATH=${M2_HOME}/bin:${PATH}
  • You also need to set the environment variable M2_HOME to the top-level directory you installed (in this example, /usr/local/maven)

  • export M2_HOME=/usr/local/maven
  • export PATH=${M2_HOME}/bin:${PATH} 
Once Maven is installed, you can check the version by running mvn -v from the command-line. If Maven has been installed, you should see something resembling the following output. 
$ mvn -v Apache Maven 2.2.0 (r788681; 2009-06-26 08:04:01-0500) Java version: 1.5.0_19 Java

home: /System/Library/Frameworks/JavaVM.framework/Versions/1.5.0/Home Default locale: en_US,
platform encoding: MacRoman OS name: "mac os x" version: "10.5.7" arch: "i386" Family: "unix"
 

Monday, June 14, 2010

What is HTML 5?

 

There's still a fair amount of time before HTML 5 is regularly seen on the world wide web. But it's worth taking a closer look at some of the changes that are coming, and how they may benefit your ecommerce website.

What New Elements Are In HTML 5?

HTML5-demoPNG

Most of the new elements in HTML 5 are directly related to content structure and information types. The new content structure types include <section>, <article>, <aside>, <hgroup>, <nav>, and <figure>. New information type elements include <video>, <audio>, <meter>, <time>,<details>, and <summary>. There are many others, but these elements are particularly likely to be useful in ecommerce.

When Can I Use HTML 5?

With the separation of structure from presentation as the preferred method to build a website – CSS and HTML, as you may have heard it described – it really doesn't matter in any significant way whether most browsers support these elements, with a few unsurprising exceptions.

For the most part, using HTML 5 elements requires nothing more than declaring some styles for them in your cascading style sheets. The one little exception is that Internet Explorer doesn't acknowledge CSS declarations for any element it doesn't already recognize. As a result, a small amount of JavaScript is required to make Internet Explorer recognize the elements. This article isn't really the place to go into how to provide this ability, or how to style new elements with CSS.

There's nothing in HTML 5 which you can apply today to shoot your website to the top of the marketplace. Anything you do is likely to take years to have sufficient market penetration to make a huge difference. But, as you know already, demand drives development. There are enough benefits to HTML 5 down the road that it's well worth demanding support from your vendors and developers.

Sunday, June 13, 2010

How to add Template to the Joomla

1. Down load free Templates from following links.


www.siteground.com/
joomla-hosting/joomla-templates.htm

www.TemplatesBuzz.net

www.joomla24.com/

joomlatp.com/

2.unzip and copy it to the following location “templates folder” wherever you install Joomla in linux

/var/www/html/Joomla_1.5.17-Stable-Full_Package/templates

3.Go to the Joomla site and select “Extensions”->”Template Manager”->”site”. Now you can see your downloaded template in the “template name” list.

4.Put the tick on it from the list. Press Default button which is appear in top of the right hand side with yellow START. After that you can set your downloaded Template as a Default template to your site.

5.Have a preview using Preview button which is in the top of right hand side.

Why iPhone hates flash?

 

While some version of Flash Lite is available on millions of phones, it’s conspicuously absent on the iPhone.

Many reasons have been floated for why Flash isn’t a good match for the iPhone: it’s slow, it hogs CPU cycles, it drains the battery, it crashes too often, it’s not optimized for Mac OS X and so on. As obvious as these reasons may be, even if all those technical issues could be solved tomorrow, there would still remain a huge divide between Adobe and Apple on the iPhone: who controls the UI?

To put Flash on the iPhone Adobe may:

  • strike a deal to license Apple’s entire iPhone UI controls and interaction patterns and ship them with Flash, Flex and AIR development suites as components, much like its current default set “Halo.” Apple hasn’t yet shown any inkling that it’s willing go along with this.

 

  • decide to duplicate the iPhone UI and ignore a legal threat from seriously irked Apple IP lawyers. (For a company that once sued Macromedia for UI infringement that would be supremely ironic.)

 

  • leave the task of creating iPhone compatible Flash components and skins to third party partners and let them deal with the legal ramifications.

 

  • encourage developers to design and produce separate versions of their Flash apps for the iPhone and other platforms, but that simply defeats the whole purpose of using Flash to deliver seamlessly compliant multi-platform apps.

 

  • develop its own non-infringing multi-touch gesture library for Flash to either compete with Apple on the iPhone, or just ignore the iPhone and try to establish an anti-iPhone multi-touch platform. (In this regard, it may approach Google to make all or parts of its technology available to Android.)

Writing and Compiling C programs on Linux

Assume you have C source code, it needs to be compiled that means turn it in to machine language,
that your cpu can actually read.
There are two ways to do that :
1) using gcc or cc
2) using make but make requires a makefile(tells what to do).

assume you have source code file called "hello.c", once you execute following command
"gcc -o hello hello.c"

That -o option to gcc tells it what you want your program to be called and its generate a file called hello.out that would be the executable file.

//file hello.c
#include
main ()
{
printf("Hello World");
}


to compile :

$ gcc -o hello hello.c

it's generate a file called hello after that you can get output of the program using ./hello

Free and Open Source Online SVN

http://code.google.com/hosting/







http://sourceforge.net/









https://www.bountysource.com/








http://www.xp-dev.com/







http://www.assembla.com/







http://unfuddle.com/








http://www.codespaces.com/

Friday, June 11, 2010

Symfony - What is that?

Are you a php developer? Are you working with pure php without any frameworks?
Here you are, you better know what is Symfony.

I can simply say Symfony is a framework which is very similar to Ruby on Rails, RoR developers simply get the whole idea from this single word, but programmers who do not have ROR experience wont.

Symfony is a Php framework that will give you a rapid web development environment. I'll list down the features of symfony that will gives you a better idea.

Object Orient
Is provides you php oop features. Pre defined classes, methods, etc.

ORM - Object relational mapping
Symfony has default plug-in for ORM. This means that you no need to write SQL query any more while doing php developments.

Auto Generation
This is the very impotent feature that Symfony provides. With using some simple commands you can create a fully functional application, that means you created your,
Relational Model
Write some yml files
execute some commands, which creates
your database with tables and relationship between those tables
model, controllers and views
Now you perform functions like insert,delete,update,view with your application.
Next build your business process from that point

Wednesday, June 9, 2010

What is an Operating System?


An Operating System is a PROGRAM that acts as an interface between a USER of a computer system and the COMPUTER HARDWARE.
OS manages the computer hardware, and provides a basis for application programs. There is no universally accepted definition of OS and what is part of OS and what is not; Is Internet Explorer a part of Windows OS?
Kernel – a program that is running all the time on the computer. Other programs are considered as system/application programs.














User views of OS

  • PC: single user ->OS provides ease of use, less attention to performance, and (almost) none to resource utilization.
  • Mainframe or minicomputer: many users share resources and exchange information -> OS maximizes resource utilization/efficiency, and fairness among users.
  • Workstations: several users with both shared and private resources -> OS to compromise between individual usability and resource utilization.
  • Handheld computers: single user with power and interface limitations -> OS aims for individual usability and performance per battery life.
  • Embedded computers: have little or no user view OS-> runs without user intervention.


System views of OS

  • OS as the resource allocator OS must use the resources efficiently and allocate them fairly among users. Resources: CPU time, memory space, file storage space, I/O devices, etc.
  • OS as the control program Control the execution of user programs OS prevents errors and improper use of the computer.

OS Purposes

1) To provide an environment for a user to execute programs conveniently and efficiently.
2) To simulate features not available on hardware.
OS provides features factually not provided by the hardware.
What features?
3) To control all the computer’s resources and to provide the base upon which the application programs can be written.

Ruby on rails how to send mails using sendmail

By using ActionMailer you can send email using ruby. ActionMailer is a component that send and
receive emails.

Action Mailer - Configuration
1)

if you are using linux os you can use sendmail option to send and receive emails by editing your rails project environement.rb file.

ActionMailer::Base.delivery_method = :sendmail

or else you can use smtp settings

ActionMailer::Base.delivery_method = :smtp
ActionMailer::Base.server_settings = {
:address => "smtp.somesite.com",
:port => 25,
:domain => "somesite.com",
:authentication => :login,
:user_name => "username",
:password => "password",
}
# following line for to use a view for our email format.
ActionMailer::Base.default_content_type = "text/html"


2)
Generate email model by typing :

script/generate mailer Emailer


3) Edit the model

class Emailer < ActionMailer::Base
def contact(recipient, subject, message, sent_at = Time.now)
@subject = subject
@recipients = recipient
@from = 'no-reply@somedomail.com'
@sent_on = sent_at
@body["title"] = 'This is title'
@body["email"] = 'sender@somedomain.com'
@body["message"] = message
@headers = {}
end
end


4)

create a file called app/views/contact.rhtml
add the following. lines

Hi!

You are having one email message from <%= @email %> with a tilte

<%= @title %>
and following is the message:
<%= @message %>

Thanks


5)

now create a controller as follows

script/generate controller Emailer


then edit the EmailController as :

class EmailerController < ApplicationController
def sendmail
recipient = "gayanvirajith@gmail.com"
subject = "new subject"
message = "Hi Email"
Emailer.deliver_contact(recipient, subject, message)
return if request.xhr?
render :text => 'Message sent successfully'
end
end

6) That's it. done. now you can run script/server and go to url :
http://localhost:3000/email/sendmail/

Good luck ~!

OTRS

OTRS is an Open source Ticket Request System (also well known as trouble ticket system) with many features to manage customer telephone calls and e-mails. The system is built to allow your support, sales, pre-sales, billing, internal IT, helpdesk, etc. department to react quickly to inbound inquiries.
It is distributed under the GNU Affero General Public License (AGPL) and tested on Linux, Solaris, AIX, FreeBSD, OpenBSD, Mac OS 10.x and Windows.

You can use OTRS for your own product and customize for your requiarements. OTRS is developed using Perl.

Feature List

Web-Interface:
Agent web interface for viewing and working on all customer requests
Admin web interface for changing system things
Customer web interface for viewing and sending infos to the agents
Webinterface with themes support
Webinterface with Single sign on (e. g. HTTPBasicAuth or LogonTickets)
Multi language support (Brazilian Portuguese, Bulgarian, Czech, Chinese, Dutch, Danish, English, Estonian, Finnish, French, German, Greek, Hungarian, Italian, Norwegian, Polish, Portuguese, Russian, Slovak, Spanish, Turkish and Vietnam)
customize the output templates (dtl) release independently
Webinterface with multi attachment support easy and logical to use

Email-Interface:
MIME support (attachments)
PGP support
SMIME support
dispatching of incoming email via email addess or x-header
autoresponders for customers by incoming emails (per queue)
auto convert of incoming html only emails to text/plain (to get it easier searchable)
email-notification to the agent by new tickets, follow ups or lock timeouts
follow up check based on references and in-reply-to header
Ticket:
custom queue view and queue view of all requests
Ticket locking
Ticket replies (standard responses)
Ticket autoresponders per queue
Ticket history, evolution of ticket status and actions taken on ticket
abaility to add notes (with different note types) to a ticket
Ticket zoom feature
Tickets can be bounced or forwarded to other email addresses
Ticket can be moved to a different queue (this is helpful if emails are for a specific subject)
Ticket priority
Ticket time accounting
Ticket print view (PDF)
Ticket pending feature
Ticket responsible feature
Ticket bulk feature
Ticket hook divider
Ticket event module layer
Generic agent to do automatically actions on tickets (based on scheduled jobs)
content fulltext search
Ticket ACL support
Ticket workflow feature
System:
ASP (activ service providing) support
Calendar / WorkingTime support for time calculations (SLA)
Customer Source can be used from a SQL databases or LDAP (e. g. eDirectory, AD, OpenLDAP)
TicketHook free setable like 'Call#', 'MyTicket#', 'Request#' or 'Ticket#'
Ticket number format free setable
database xml interface (driver for different databases including admin tasks like ALTER, CREATE, DROP, ... of tables)
database layer, support of different SQL databases (e. g. MySQL, PostgeSQL, Oracle, DB2 and MSSQL)
a stats framework
utf-8 support for frontend and backend
OTRS web package manager (to install applications like calendar or filemanager)
agent authentication against database, ldap, httpauth or radius
customer authentication against database, ldap, httpauth or radius
creation and configuration of user accounts, groups and roles
creation of standard responses
creation of sub queue
signature configuration per queue
salutation configuration per queue
email-notification of administrators
email-notification sent to problem reporter (by create, locked, deleted, moved and closed)
submitting update-info (via email or webinterface)
deadlines for trouble tickets
global TimeZone feature
Web config editor
Link support of objects link tickets, faqs, ...
different levels of permissions/access-rights
easy to develope you own addon's (OTRS API)
easy to write different frontends (e. g. X11, console, ...)
a fast and usefull application

Personal View
OTRS is a very complex system and architecture.

Joomla-Site Menu

Site Menu includes following important areas.
  • Control Panel
  • User Manager
  • Media Manager
  • Configuration
  1. Control Panel
Using Control Panel we can switch to various areas of administration either by selecting a menu item or by clicking on the displayed icons. Once you have experience as admin you can use fast access icons to move around the site.

2. User Manager
Users have a special role on your Joomla! site. You can set up as many users as you want and, depending on their rights, they can create their own content and/or view content that has been created for particular users.

3. Media Manager

You can envision the Media Manager work area like a file explorer or like an FTP program in your operating system. You can upload files with bmp, csv, doc, epg, gif, ico, jpg, odg, odp, ods, odt, pdf, png, ppt, swf, txt, xcf, xls, BMP, CSV, DOC, EPG, GIF, ICO, JPG, ODG, ODP, ODS, ODT, PDF, PNG, PPT, SWF, TXT, XCF, and XLS suffixes and administer them in various directories. This manager is especially useful if you don't have FTP access even though you have administration rights.


4.Global Configuration

In the Global Configuration section you can define all the settings that are valid for the entire website. The values of the variables are saved in the configuration.php file.

4.1Site Settings

This setting page provides three things. Under Site Setting we can informe latest changes to the customers,metadata setting and seo setting important with search engines and are written in XHTML.

4.2System Settings

This setting page provides all system settings requirements. Manage System,user,media,cache and session Settings

4.3Server Settings
This setting page provides Server,Locale,FTP,Database and Mail Settings

Tuesday, June 8, 2010

PHP library YAML

YAML Definition : YAML Ain't Markup Language

Why we use ?
YAML is a human friendly data serialization standard for all programming languages.

What is it?

Symfony YAML is a PHP library that parses YAML strings and converts them to PHP arrays. It can also converts PHP arrays to YAML strings.

YAML is a great format for your configuration files. YAML files are as expressive as XML files and as readable as INI files.

Easy to use

Released under the MIT license, you are free to do whatever you want, even in a commercial environment. You are also encouraged to contribute.
Used by popular Projects

Symfony YAML was initially released as part of the symfony framework, one of the most popular PHP web framework. It is also embedded in other popular projects like PHPUnit or Doctrine.

Documented
Symfony YAML is fully documented, with a dedicated online book, and of course a full API documentation.

Fast
One of the goal of Symfony YAML is to find the right balance between speed and features. It supports just the needed feature to handle configuration files.
Unit tested

The library is fully unit-tested. With more than 400 unit tests, the library is stable and is already used in large projects.
Real Parser

It sports a real parser and is able to parse a large subset of the YAML specification, for all your configuration needs. It also means that the parser is pretty robust, easy to understand, and simple enough to extend.
Clear error messages

Whenever you have a syntax problem with your YAML files, the library outputs a helpful message with the filename and the line number where the problem occurred. It eases the debugging a lot.


Dump support
It is also able to dump PHP arrays to YAML with object support, and inline level configuration for pretty outputs.

Types Support
It supports most of the YAML built-in types like dates, integers, octals, booleans, and much more...

Full merge key support
Full support for references, aliases, and full merge key. Don't repeat yourself by referencing common configuration bits.
PHP Embedding

YAML files are dynamic

By embedding PHP code inside a YAML file, you have even more power for your configuration files.

Installing Tortoise SVN

Hi, Today I’m going to install Tortoise SVN, Tortoisesvn  is a SVN client software. You can use it to upload software projects, version controlling.

With this you can have many group members working at home and uploading code in to one common location. In other words, every one can work at home :D

1. first go to google and search for tortoise svn and click on the link.

Capture1

2. Click the download link.

Capture2

3. Select, and click on a link(64 bit or 32 bit).

Capture3

4. Now double click the file.

Capture5

5. press Run.

Capture6

6. Next…

Capture7

7. check accept … press Next

Capture8

8. Keep these default settings and press Next.

Capture9

9. Now click Install.

Capture10

10. Now the installing will start.

Capture11

11. Keep the Show Changelog unchecked and clikc Finish.

Capture12

12. press yes to restart the computer.

Capture13

Now you are done with installing the svn host. so, let think of a good SVN site, there are many sites you can use for this, but I’m going to use the www.xp-dev.com it gives 200MB free.

2 closed source projects.

any number of open source projects.

any number of member for a project.

so here’s how to do that,

13. Now go to site and make an account and log in.

Capture14

14. After you log in, click on projects (if you have created your xp-dev account just now

you wont see Project(2), you will just see Projects.

click on the Projects tab.

Capture15

15. Fill the new project details

Capture16

16. Now click on the Source Control tab and click Enable Source Control link.

Capture17

17. Fill in the details and press save.

Capture18

18. Now after you press save, now copy that link(in my case http://svn.xp-dev.com/svn/SampleProject/ of course yours will differ according to details you entered).

Capture19

19. Now, create a new folder any where you like and give it any name you like. Right click it and press SVN Checkout.

aa

20. Paste the link you copied in URL of repository text box and press OK.

Capture

21. Now you will see these files downloading. press OK after the downloading completes.

cc

Now you are done !!!!

22. If you need to upload some thing, add it to the folder you created, and right click the folder and select “SVN Commit…”

select the file you want to upload and press ok.

Capture

23. Type in user name and password. and press OK.

Capture

24. If every thing goes will you folder will look like this.

1212121

Try it and see it for your self.

cheers.