This site is not supported for Internet Explorer 6. It might look funny or even not function properly if you are using this browser.
You upgrade Flash as soon as they get a new version. Why not get an updated browser?
Try Firefox, Chrome or if you love and breath Microsoft than IE7.

kbasarab's blog

Writing PHP PDO (Prepared Statements)

Since I started doing dynamic PHP development I've been using the trusty mysql_* functions that PHP provides. These have worked great for me throughout the years but I've been on a kick to make my programs a bit more secure. I've long since verified data input but it still didn't seem to be good enough.

O'Brien Family Reunion Photos

Photos from the O'Brien family reunion in Manchester, NH. August, 2010.

Simple redirection of Drupal template files

This is a quick and super easy way to mimic the functionality of a content type in your Drupal install. On the site I'm working on we wanted to replicate functionality for two content types. Now the Drupal way would say to use the same content type and filter them with taxonomy or even a CCK field. In this instance the two content types currently offer the same functionality but there is reason to believe that in the future one will get a lot of changes or even a completely different layout then the other so it was decided to keep them separate.

Filed under:

Providing custom tokens to token module in Drupal 6

Many Drupal modules integrate with the Token module and it is used in almost every Drupal install for defining path aliases and even custom breadcrumbs.  Its so popular that in the upcoming Drupal 7 release token is integrated into core.  

If you're developing your own custom module why not integrate with token and allow your users more flexibility with what they can do with your content? With two simple functions you can easily integrate your module with Token.

Filed under:

Changing views filters programmatically with Views 2 and Drupal 6

In trying to keep the amount of new views created on the site I'm working on I wanted to programmitcally change certain portions of a view to use the same output but different inputs. In background I'm using Drupal 6 with Views 2 API.

Specifically I wanted to change the number of items and node type filter. Though this could be expanded to changing the sort, arguments or fields returned as well.

Recipe Submissions

On the last iteration of kBasarab.com I started working on a recipe system to keep track of various recipes.  I had one working that I liked but I wanted to do more with it.  With learning and becoming a Drupal developer the new kBasarab.com is based on Drupal.  So for a recipe system I logically turned to the Drupal community for a way to organize recipes. Alas I found the recipe module.

New York City Photos 2009

Over the 9/11 weekend I took a trip to New York to visit Lisa who is now living in Hoboken, NJ.  Got in super late Thursday evening and covered all parts of the city I hadn't done before.  Brooklyn Bridge, Chinatown, Little Italy, Upper Westside, etc... Sunday evening we managed to end up right in front of Radio City Music Hall for the 2009 MTV Video Music Awards.  Photos from the trip are now over in the galleries so check them out.

View photos from New York City and the MTV Video Music Awards.

Family Reunion Photos

I finally got around to posting the family reunion photos from when the Byrnes side of the family came down to Florida.  We had a great time hanging out at the pool and enjoying the sunset at Alpine Groves Park.  See the photos in the gallery.

Click here to see the full gallery

 

The math behind iwearyourshirt.com

The last time I talked to Jason Sadler (@iwearyourshirt) I told him about how when he first started iwearyourshirt.com I did a little quick math using PHP to determine how much money he'll be making and how it increases dramatically as you change the numbers.  I also promised him I'd show this to him and totally failed in getting it to him.  Well I remembered about it today after reading the Mashable article about him and his 2010 initiatives of charging $2 per shirt.  Here's how it all breaks down:


Day		$1 per day	$2 per day	$5 per day
1		1		2		5
2		3		6		15
3		6		12		30
4		10		20		50
5		15		30		75
6		21		42		105
7		28		56		140
8		36		72		180
9		45		90		225
10		55		110		275
11		66		132		330
12		78		156		390
13		91		182		455
14		105		210		525
15		120		240		600
16		136		272		680
17		153		306		765
18		171		342		855
19		190		380		950
20		210		420		1,050
21		231		462		1,155
22		253		506		1,265
23		276		552		1,380
24		300		600		1,500
25		325		650		1,625
26		351		702		1,755
27		378		756		1,890
28		406		812		2,030
29		435		870		2,175
30		465		930		2,325
31		496		992		2,480
32		528		1,056		2,640
33		561		1,122		2,805
34		595		1,190		2,975
35		630		1,260		3,150
36		666		1,332		3,330
37		703		1,406		3,515
38		741		1,482		3,705
39		780		1,560		3,900
40		820		1,640		4,100
41		861		1,722		4,305
42		903		1,806		4,515
43		946		1,892		4,730
44		990		1,980		4,950
45		1,035		2,070		5,175
46		1,081		2,162		5,405
47		1,128		2,256		5,640
48		1,176		2,352		5,880
49		1,225		2,450		6,125
50		1,275		2,550		6,375
51		1,326		2,652		6,630
52		1,378		2,756		6,890
53		1,431		2,862		7,155
54		1,485		2,970		7,425
55		1,540		3,080		7,700
56		1,596		3,192		7,980
57		1,653		3,306		8,265
58		1,711		3,422		8,555
59		1,770		3,540		8,850
60		1,830		3,660		9,150
61		1,891		3,782		9,455
62		1,953		3,906		9,765
63		2,016		4,032		10,080
64		2,080		4,160		10,400
65		2,145		4,290		10,725
66		2,211		4,422		11,055
67		2,278		4,556		11,390
68		2,346		4,692		11,730
69		2,415		4,830		12,075
70		2,485		4,970		12,425
71		2,556		5,112		12,780
72		2,628		5,256		13,140
73		2,701		5,402		13,505
74		2,775		5,550		13,875
75		2,850		5,700		14,250
76		2,926		5,852		14,630
77		3,003		6,006		15,015
78		3,081		6,162		15,405
79		3,160		6,320		15,800
80		3,240		6,480		16,200
81		3,321		6,642		16,605
82		3,403		6,806		17,015
83		3,486		6,972		17,430
84		3,570		7,140		17,850
85		3,655		7,310		18,275
86		3,741		7,482		18,705
87		3,828		7,656		19,140
88		3,916		7,832		19,580
89		4,005		8,010		20,025
90		4,095		8,190		20,475
91		4,186		8,372		20,930
92		4,278		8,556		21,390
93		4,371		8,742		21,855
94		4,465		8,930		22,325
95		4,560		9,120		22,800
96		4,656		9,312		23,280
97		4,753		9,506		23,765
98		4,851		9,702		24,255
99		4,950		9,900		24,750
100		5,050		10,100		25,250
101		5,151		10,302		25,755
102		5,253		10,506		26,265
103		5,356		10,712		26,780
104		5,460		10,920		27,300
105		5,565		11,130		27,825
106		5,671		11,342		28,355
107		5,778		11,556		28,890
108		5,886		11,772		29,430
109		5,995		11,990		29,975
110		6,105		12,210		30,525
111		6,216		12,432		31,080
112		6,328		12,656		31,640
113		6,441		12,882		32,205
114		6,555		13,110		32,775
115		6,670		13,340		33,350
116		6,786		13,572		33,930
117		6,903		13,806		34,515
118		7,021		14,042		35,105
119		7,140		14,280		35,700
120		7,260		14,520		36,300
121		7,381		14,762		36,905
122		7,503		15,006		37,515
123		7,626		15,252		38,130
124		7,750		15,500		38,750
125		7,875		15,750		39,375
126		8,001		16,002		40,005
127		8,128		16,256		40,640
128		8,256		16,512		41,280
129		8,385		16,770		41,925
130		8,515		17,030		42,575
131		8,646		17,292		43,230
132		8,778		17,556		43,890
133		8,911		17,822		44,555
134		9,045		18,090		45,225
135		9,180		18,360		45,900
136		9,316		18,632		46,580
137		9,453		18,906		47,265
138		9,591		19,182		47,955
139		9,730		19,460		48,650
140		9,870		19,740		49,350
141		10,011		20,022		50,055
142		10,153		20,306		50,765
143		10,296		20,592		51,480
144		10,440		20,880		52,200
145		10,585		21,170		52,925
146		10,731		21,462		53,655
147		10,878		21,756		54,390
148		11,026		22,052		55,130
149		11,175		22,350		55,875
150		11,325		22,650		56,625
151		11,476		22,952		57,380
152		11,628		23,256		58,140
153		11,781		23,562		58,905
154		11,935		23,870		59,675
155		12,090		24,180		60,450
156		12,246		24,492		61,230
157		12,403		24,806		62,015
158		12,561		25,122		62,805
159		12,720		25,440		63,600
160		12,880		25,760		64,400
161		13,041		26,082		65,205
162		13,203		26,406		66,015
163		13,366		26,732		66,830
164		13,530		27,060		67,650
165		13,695		27,390		68,475
166		13,861		27,722		69,305
167		14,028		28,056		70,140
168		14,196		28,392		70,980
169		14,365		28,730		71,825
170		14,535		29,070		72,675
171		14,706		29,412		73,530
172		14,878		29,756		74,390
173		15,051		30,102		75,255
174		15,225		30,450		76,125
175		15,400		30,800		77,000
176		15,576		31,152		77,880
177		15,753		31,506		78,765
178		15,931		31,862		79,655
179		16,110		32,220		80,550
180		16,290		32,580		81,450
181		16,471		32,942		82,355
182		16,653		33,306		83,265
183		16,836		33,672		84,180
184		17,020		34,040		85,100
185		17,205		34,410		86,025
186		17,391		34,782		86,955
187		17,578		35,156		87,890
188		17,766		35,532		88,830
189		17,955		35,910		89,775
190		18,145		36,290		90,725
191		18,336		36,672		91,680
192		18,528		37,056		92,640
193		18,721		37,442		93,605
194		18,915		37,830		94,575
195		19,110		38,220		95,550
196		19,306		38,612		96,530
197		19,503		39,006		97,515
198		19,701		39,402		98,505
199		19,900		39,800		99,500
200		20,100		40,200		100,500
201		20,301		40,602		101,505
202		20,503		41,006		102,515
203		20,706		41,412		103,530
204		20,910		41,820		104,550
205		21,115		42,230		105,575
206		21,321		42,642		106,605
207		21,528		43,056		107,640
208		21,736		43,472		108,680
209		21,945		43,890		109,725
210		22,155		44,310		110,775
211		22,366		44,732		111,830
212		22,578		45,156		112,890
213		22,791		45,582		113,955
214		23,005		46,010		115,025
215		23,220		46,440		116,100
216		23,436		46,872		117,180
217		23,653		47,306		118,265
218		23,871		47,742		119,355
219		24,090		48,180		120,450
220		24,310		48,620		121,550
221		24,531		49,062		122,655
222		24,753		49,506		123,765
223		24,976		49,952		124,880
224		25,200		50,400		126,000
225		25,425		50,850		127,125
226		25,651		51,302		128,255
227		25,878		51,756		129,390
228		26,106		52,212		130,530
229		26,335		52,670		131,675
230		26,565		53,130		132,825
231		26,796		53,592		133,980
232		27,028		54,056		135,140
233		27,261		54,522		136,305
234		27,495		54,990		137,475
235		27,730		55,460		138,650
236		27,966		55,932		139,830
237		28,203		56,406		141,015
238		28,441		56,882		142,205
239		28,680		57,360		143,400
240		28,920		57,840		144,600
241		29,161		58,322		145,805
242		29,403		58,806		147,015
243		29,646		59,292		148,230
244		29,890		59,780		149,450
245		30,135		60,270		150,675
246		30,381		60,762		151,905
247		30,628		61,256		153,140
248		30,876		61,752		154,380
249		31,125		62,250		155,625
250		31,375		62,750		156,875
251		31,626		63,252		158,130
252		31,878		63,756		159,390
253		32,131		64,262		160,655
254		32,385		64,770		161,925
255		32,640		65,280		163,200
256		32,896		65,792		164,480
257		33,153		66,306		165,765
258		33,411		66,822		167,055
259		33,670		67,340		168,350
260		33,930		67,860		169,650
261		34,191		68,382		170,955
262		34,453		68,906		172,265
263		34,716		69,432		173,580
264		34,980		69,960		174,900
265		35,245		70,490		176,225
266		35,511		71,022		177,555
267		35,778		71,556		178,890
268		36,046		72,092		180,230
269		36,315		72,630		181,575
270		36,585		73,170		182,925
271		36,856		73,712		184,280
272		37,128		74,256		185,640
273		37,401		74,802		187,005
274		37,675		75,350		188,375
275		37,950		75,900		189,750
276		38,226		76,452		191,130
277		38,503		77,006		192,515
278		38,781		77,562		193,905
279		39,060		78,120		195,300
280		39,340		78,680		196,700
281		39,621		79,242		198,105
282		39,903		79,806		199,515
283		40,186		80,372		200,930
284		40,470		80,940		202,350
285		40,755		81,510		203,775
286		41,041		82,082		205,205
287		41,328		82,656		206,640
288		41,616		83,232		208,080
289		41,905		83,810		209,525
290		42,195		84,390		210,975
291		42,486		84,972		212,430
292		42,778		85,556		213,890
293		43,071		86,142		215,355
294		43,365		86,730		216,825
295		43,660		87,320		218,300
296		43,956		87,912		219,780
297		44,253		88,506		221,265
298		44,551		89,102		222,755
299		44,850		89,700		224,250
300		45,150		90,300		225,750
301		45,451		90,902		227,255
302		45,753		91,506		228,765
303		46,056		92,112		230,280
304		46,360		92,720		231,800
305		46,665		93,330		233,325
306		46,971		93,942		234,855
307		47,278		94,556		236,390
308		47,586		95,172		237,930
309		47,895		95,790		239,475
310		48,205		96,410		241,025
311		48,516		97,032		242,580
312		48,828		97,656		244,140
313		49,141		98,282		245,705
314		49,455		98,910		247,275
315		49,770		99,540		248,850
316		50,086		100,172		250,430
317		50,403		100,806		252,015
318		50,721		101,442		253,605
319		51,040		102,080		255,200
320		51,360		102,720		256,800
321		51,681		103,362		258,405
322		52,003		104,006		260,015
323		52,326		104,652		261,630
324		52,650		105,300		263,250
325		52,975		105,950		264,875
326		53,301		106,602		266,505
327		53,628		107,256		268,140
328		53,956		107,912		269,780
329		54,285		108,570		271,425
330		54,615		109,230		273,075
331		54,946		109,892		274,730
332		55,278		110,556		276,390
333		55,611		111,222		278,055
334		55,945		111,890		279,725
335		56,280		112,560		281,400
336		56,616		113,232		283,080
337		56,953		113,906		284,765
338		57,291		114,582		286,455
339		57,630		115,260		288,150
340		57,970		115,940		289,850
341		58,311		116,622		291,555
342		58,653		117,306		293,265
343		58,996		117,992		294,980
344		59,340		118,680		296,700
345		59,685		119,370		298,425
346		60,031		120,062		300,155
347		60,378		120,756		301,890
348		60,726		121,452		303,630
349		61,075		122,150		305,375
350		61,425		122,850		307,125
351		61,776		123,552		308,880
352		62,128		124,256		310,640
353		62,481		124,962		312,405
354		62,835		125,670		314,175
355		63,190		126,380		315,950
356		63,546		127,092		317,730
357		63,903		127,806		319,515
358		64,261		128,522		321,305
359		64,620		129,240		323,100
360		64,980		129,960		324,900
361		65,341		130,682		326,705
362		65,703		131,406		328,515
363		66,066		132,132		330,330
364		66,430		132,860		332,150
365		66,795		133,590		333,975


TOTAL: 		$66,795		$133,590	$333,975

Las Vegas Photos

So I finally got myself around to uploading the photos from Las Vegas.  It was only almost a month ago already so why should I have done it any sooner.  Anyways head on over to the image galleries and check out Las Vegas for the 2009 USBC Bowling National Open Championships.  

Syndicate content

About kBasarab.com

Welcome to kBasarab.com - Kevin Basarab's home on the web. Here you will find my blog entries, photo galleries and more. I'd eventually like to add some genealogy on the Basarab name to the site but am looking for the best way to do this.  I currently work as a web developer for The Florida Times-Union using Drupal CMS and do wedding videography on weekends. I am also available for contract/freelance work. If you have any ideas or comments please feel free to contact me.

Google Reader Shared Items

User login