Nothing To Lose

If you don’t have it, how can you lose it!
Subscribe

PLUG at CMDA IT Expo 2009

December 16, 2009 By: Dexter Category: Foss, Linux, Review

CMDA IT Expo Pune is a yearly event which has been happening for almost 10 years now. The event is organized by CMDA (Computer Media Dealers Association Pune).
The event showcases latest software and hardware and other computers stuff. Many a times you get a good bargain on these devices.
A nice expo which runs for 4 days.

What does PLUG do in the expo?

PLUG has been participating in the expo for almost 8 years now. Through this expo we try to create more awareness about FOSS (Free/Open Source Software) among the ‘Aam Janta’. For last few years due to increased awareness amongst people we have been providing CD’s/DVD’s of Latest Linux Distros on the stall for nominal charges.
The expos is visited by thousands of people over the 4 days, which includes students, professionals, home makers etc.
We face have face very very interesting questions, remarks, confusions etc during the expos…
here are few of the overheard remarks, direct comments etc.

Some of them are here!!
(Q = Question, R = Remark, C = Comment, O = Overheard)

Q. What is Linux ?

Q. It is free, right, then why are you selling it?

Q. What is PLUG?

Q/R. Are you people crazy?/!

O. Lets go.. we will download in the college. (some college students)

O. Chal chal mere pass sab hai.. copy kar ke deta hoo!! (I have all of the distros i will copy it for you)

R/C. Hey PLUG stall, nice to see you people, great work, keep it up.

O. Windows is better. (lol)

R/C. I have used all of them (distros) none of those worked.

R/C. Wow you have DVD.. give me… only Rs.100/- nice whose gonna download.

Q. Where can I meet you people later.

Over all there has been a huge change in attitude of people looking toward FOSS over last few years.

I remember managing the PLUG stall for the first time somewhere in 2002, it was me, Manas, Sudhanwa, Vijay Deval, Zoyd..

We had absolutely no idea what to do with the stall and we had put up three computers, one was from Manas i think a PII, one from Sudhanwa with a 21 inch philips monitor and one was a 386/486 from Vijay.

People were really confused when they visited our stall, question we faced were.

Q.What are you selling here?
A. Nothing (think of a confused look on the persons face)

Q. Then?
A. Promoting Linux.

And went the series of generic questions.
since we were not providing CD at that time and many people wanted CD, the person next to our stall was selling Chip magazine which contained the 2 CD of mandriva/mandrake, we redirected people to his stall, and when he came to know that the first CD was in the previous issues he got all the old stock and sold it.

One very interesting question was about Sudhanwa’s 21 inch monitor. even the stall next to us was a philips stall and the max size of monitor they had was a 15inch.

Q.What is the price of this monitor
A.We are not selling monitor. (Again huge question mark)

Over the last so many years we have seen nice change and comments from people and increased awareness about FOSS and Linux.

from the first expo participation to this one here is the series of changes in attitude and comments that has taken place

Q. What are you selling (noting)?????????????
Q. What is PLUG/Linux?

Changes in comments over next few years?

Hmmm Linux…
Oh PLUG
I want CD/DVD

And recent years…

Wow PLUG people… I am a member online
Do you have xyz distro i need it now.
when is you next meeting…

Over all a nice fun experience.
Friends please add your experience which have missed in the comments.

Share This Article
  • Digg
  • del.icio.us
  • Facebook
  • Mixx
  • Google
  • blogmarks
  • description
  • E-mail this story to a friend!
  • LinkedIn
  • MySpace
  • Reddit
  • Slashdot
  • StumbleUpon
  • Technorati
  • TwitThis

Getting page and subpage and parent(s) name in title bar with wordpress.

August 20, 2009 By: Dexter Category: Blog, PHP, Tutorial, Web Development, Wordpress

Had been working with wordpress (2.8.1) lately for some web development work. Now there were some section of the site which are sub pages of some parent page again which are sub pages of some category.

lets say you have we have a scenario like this
Products is the main category. Then it has two sub categories say Laptops and Desktops
And Laptops has sub categories 14 inches, 17 inches
Desktops have sub categories Home, Office, Game Station.

When the user browses to a page say Game Station you want to display on the title bar:

Website Name » Products
Website Name » Products » Desktops
Website Name » Products » Desktops » Game Station
or
Website Name » Products » Laptops
etc
I will assume that you already know how to have pages arranged in categories and subcategories in wordpress.

What we need is to do is use few available inbuilt functions of wordpress

1. get_post_ancestors() Read more..

this one get the ancestor of the given page/post id

2. the_ID() Read More..

this get you the current post id

3. get_post() Read More

gets the info of a given post id. Returns an object.

4. the_title()

returns the name of current page.

So here is the code.

Open the header.php (from the selected theme)

and add the following between the <title> and </title>

<title> Website Name: &raquo
<?php
$postsarray = (get_post_ancestors(the_ID()));
krsort($postsarray);
foreach($postsarray as $key=>$postid)
{
$post_ids = get_post($postid);
$title = $post_ids->post_title;
echo “$title &raquo “;
}
the_title();
?>
</title>

This will generate the title with the page and parent categories automatically.

Here is what is happening.

You can directly write you website name i.e hard code it, line

$postsarray = (get_post_ancestors(the_ID()));

get_post_ancestors() returns an indexed array containing the list of all the parent categories. Say if the current page is ‘Game Station’ then my array $postarray will be link (0=>’127′, 1=>’140′). We have used the function the_ID() inside the get_post_ancestors() so that the page id is automatically given accordingly to the current page. Note that the array contains the post id and not the name.

krsort($postsarray);

Since the array is from top category to lower we reverse sort it on the keys.

foreach($postsarray as $postid)
{
$post_ids = get_post($postid);
$title = $post_ids->post_title;
echo “$title &raquo “;
}

The foreach loop picks every post id which we give to a function get_post(), which returns a object. Here the object is in $post_ids. The object contains loads of info about the post, but we are only interested in the title. So $post_ids->post_title; returns the name of the currently created objects. We store this in $tilte;

echo “$title &raquo “;

This line get the categories displayed. Of course parent first.

the_title();

It is used here since the above functionality only returns the ancestors, so to display the name of the current page we use the_title() function.

If you want to display the name of you blog name instead of you website. replace ‘Website Name’ with <?php bloginfo(’name’) ?>
Well that is it for now.

Share This Article
  • Digg
  • del.icio.us
  • Facebook
  • Mixx
  • Google
  • blogmarks
  • description
  • E-mail this story to a friend!
  • LinkedIn
  • MySpace
  • Reddit
  • Slashdot
  • StumbleUpon
  • Technorati
  • TwitThis

Rubber Stamp Effect Using GIMP

August 13, 2009 By: Dexter Category: GIMP, Tutorial, Web Graphics

It has been a long time since I have posted a GIMP tutorial. So here is one more Which provide a Old rubber stamp effect in some very simple steps. So here we go.

Start with a blank canvas with white background. Write some text which you want to work as your ’stamp’ Use some font which is bold. Also select the text color which will act as your ink color.

Stamp Text

Stamp Text

Add a transparency layer above the text layer. Press Ctrl+L to invoke the layer dialog box, and add a layer using transparency option.
Draw a selection around the text you have just written.

rectangular selection on the transparent layer

rectangular selection on the transparent layer

Goto edit stroke selection — use a line thickness around 5 to 6 px.

stamp text with rectangular boundary

stamp text with rectangular boundary

Working on the same layer use the contiguous selection tool and click the rectangle to select that area only.

Selected outer border

Selected outer border

Goto Filter — noise — pick. In its dialog box increase the randomize to around 25% and repeat to around 40.

outer boundry has be distorted

Now switch to the layer the stamp text (press ctrl+l and then click on the text layer), select the text using contiguous selection (with shift selected) click on all the alphabets of you stamp text. Alternatively you can use select by color tool also.

text selected

repeat the pick filter as above, but decrease the randomize to 10% and repeat to only 20.
merge the layers if required.

finaly Old stamp

finally Old stamp

Rotate the image if required. I have kept a white background, if you want to use this image to be superimposed on other pages etc.. make sure you work on two transparency layers for text and box, and then remove the the white background layer.

Final old stamp.. Stamped

Final old stamp.. Stamped

Adding Vinay’s suggestion here, idea is to show that the stamp was pressed unevenly.
To do that same, take the final image, select Gradient Fill tool, set the options: Opacity to around 50%, Mode to color erase, Gradient Foreground to Transparent, Shape to Linear.
Then just click and drag the effect from one of the corners to other end (diagonally). This will cover the image with some white, giving some side of the ink to be faded. The effect looks like the ink is unevenly placed.

Stamp with uneven ink effect

Stamp with uneven ink effect

Share This Article
  • Digg
  • del.icio.us
  • Facebook
  • Mixx
  • Google
  • blogmarks
  • description
  • E-mail this story to a friend!
  • LinkedIn
  • MySpace
  • Reddit
  • Slashdot
  • StumbleUpon
  • Technorati
  • TwitThis

Missing template option in WordPress

August 02, 2009 By: Dexter Category: Web Development, Wordpress

Had been working on WordPress 2.8.1 for a friends website. Had created some different templates for pages. It was working fine for quite some time. Added a new page and suddenly noticed that the template option was missing… zoop… woosh….  vanised…

Searched on the net, could not find and proper reason for the same, This page gives you some idea what ways it can be resolved. http://wordpress.org/support/topic/190138?replies=18

I just went to themes section and (re)activated the same theme again, and magically the  template option was available again.

I still do not have a clue what was wrong. But it worked.

whatever….

there is nothing to lose.

Share This Article
  • Digg
  • del.icio.us
  • Facebook
  • Mixx
  • Google
  • blogmarks
  • description
  • E-mail this story to a friend!
  • LinkedIn
  • MySpace
  • Reddit
  • Slashdot
  • StumbleUpon
  • Technorati
  • TwitThis