Category: programming
10/11/08 02:38 - ID#46055
Surebert Flash Player 10 Uploads Fixed
. I have to hurry an intergrate it into all my projects before people start moving en massse to flash player ten and no one can upload multifiles anymore.I am much happier with the new version and I learned a lot. Like how much MXML application suck for tiny things. The smallest I could get it as an MXML application was about 150k which is so freakin lame considering it is just a bttton. I didn't even think to look at the size until I was done and I was so pissed. There was no way I was going to add a 150k button to pages.
So I scapped where I was at and build one form scratch as and Actionscript 3 project in Flex and used the flash drawing API to draw the button states etc. Its nice with an actionscript project you can really get the project size so tiny. I ended up managing to get it all under 10K which is a lot more reasonable. You can style everything bou tthe button from javascript and all the event handlers are the same as the old surebert multifile uploader ones so implementation should be easy. I commented the javascript API but no so much the flex code. The Javascript is here
and assumes you are using the surebert toolkit although you could adapt it to run on anything else. Anyways, the flex code is here if you are interested 

Permalink: Surebert_Flash_Player_10_Uploads_Fixed.html
Words: 295
Category: programming
10/07/08 10:37 - ID#45984
Adobe and Safari I hate you tonight
On another note, I can't believe I am still at work. I am trying to finish this video uploading site for a contest they are hosting. Unfortunately, the magic that is my surebert multi file unloader is about to die as Flash Player 10 changed the way you can call the FileReference browse method and calling it from javascript is no longer an option. They want it to have a flash interface. Adobe says it makes it safer, I say it just makes it flashier and makes me mad.
I plan on creating a new multi file uploader widget based on my previous work
but I won't have time tonight and they needed a solution now. I decided to just use traditional file uploads seeing as they are only uploading one file.Cool enough, but sadly you don't get the progress which is really the fun part of the surebert uploader. Luckily, there is a php extension
that allows you not only track how much of the file has been uploaded but how long it expects to take, the current speed, etc. Its really so easy and you can quickly get the data back via json. You add an extra random ID attribute to your form and it uses that as a key to track the file upload. Then you can make requests back to the server to get updates on the time remaining, etc. You make the requests via ajax which is really simple and great.Sadly, after testing in IE6 and firefox and everything working, I tested it in Safari which refuses to receive ajax responses after it has initiated a file upload. I send them, it just won't process any responses. I hate you safari. Seriously, its always you that has to make everything fucked up.
Anyways, so I re-factored and ended up going with an iframe solution as safari was happy with that and so were the other browsers. Its cool to get an estimated finish time.


Permalink: Adobe_and_Safari_I_hate_you_tonight.html
Words: 386
Category: programming
09/01/08 12:35 - ID#45530
Flash Debug Player
At somepoint today I found this in the logs
1
NO YOU SUCK! DON'T TAKE THE LORD'S NAME IN VAIN
Stop All Animation
Stop All Animation
I also found that javascript was sending my location was being sent a bunch.
var tf_partner_attributes={122: ['','',''],107: ['','','']};
var tf_zip = '14263';
var tf_city = 'Buffalo';
var tf_state = 'NY';
var tf_pub_attributes = ['#F78200',false,1,true,false,true,2,5,true,'1.0em' ];
var tf_on_fly_flag=0;
tf_show_fly_ads(tf_ads);Permalink: Flash_Debug_Player.html
Words: 126
Category: programming
07/13/08 02:05 - ID#44995
Mobile posting from blackberry email
I would have rather gone dancing at HEMF on grand island but seeing
a nobody got back to me I just programmed some more, lame.

Permalink: Mobile_posting_from_blackberry_email.html
Words: 42
Category: programming
07/12/08 06:27 - ID#44958
Should have been sleeping
iPhone able to post pictures so (e:jim) and I could blog from dancing
today. Which I will be too tired to to, LOL. I am such a loser.

Permalink: Should_have_been_sleeping.html
Words: 48
Category: programming
07/04/08 03:33 - ID#44862
Learning Iphone
The real issue is then I can't just post it on the site for everyone to use once it's done. You are going to need some sort of itunes acct and get it from apple "if" they approve my app. Its all really annoying. Maybe I will just get sick of it and quit, lol.
Seems really lame to me that you can't just distribute your own apps to your own audience.
Permalink: Learning_Iphone.html
Words: 137
Category: programming
12/04/07 10:13 - ID#42391
Does this seem like advanced Java, lol?
package lab_04c;
/**
*
* @author visco
*/
public class Main {
/**
* @param args the command line arguments
*/
public static void main(String[] args) {
System.out.println("Student Score Grade");
int[] scores = {76,91,80,55,71,98,70,88,69,60};
String[] names = {
"Suzie Q",
"Peggy Forsnacht",
"Boy George",
"Flea",
"Captain Hook",
"Nelson Mandela",
"he Might Thor",
"Oedipa Maas",
"Uncle Sam",
"The Tick"};
String[] grades = new String[scores.length];
System.out.println("Name Grade Score");
for(int x=0;x<scores.length;x++){
int score = scores[x];
String grade = "";
if(score < 60){
grade = "F";
} else if (score < 70){
grade = "D";
} else if (score < 80){
grade = "C";
} else if (score < 90){
grade = "B";
} else {
grade = "A";
}
grades[x] = grade;
System.out.println(names[x]+" "+score+" "+grade);
}
String[] possibleGrades = {"A", "B", "C", "D", "F"};
int[] frequency = {0,0,0,0,0};
double total=0;
Student: for(int student=0;student<scores.length;student++){
Grades: for(int g=0;g<possibleGrades.length;g++){
if(grades[student] == possibleGrades[g]){
frequency[g]++;
}
}
total += scores[student];
}
System.out.println("
Statistics:");
for(int g=0;g<possibleGrades.length;g++){
System.out.println("Total "+possibleGrades[g]+"s: "+frequency[g]);
}
System.out.println("
The mean score was : "+(total/scores.length));
}
}Permalink: Does_this_seem_like_advanced_Java_lol_.html
Words: 203
Category: programming
10/23/07 05:30 - ID#41765
Sometime computer commands are scary
chown -R viscop aids
Thats it. I was updating a site about AIDS for work and the content is still so old. I hope they update it soon. I feel like people with a NYS grant for an AIDS website should be on top of it, argh. The current site is this one
I think am thinking the information should be organized more like this
(that is just the test version) but the problem is the content is so out of date. Seems like anything dated 1998 about AIDS must be outdated, right - I mean that is ten years ago - or has nothing progressed?In 1998, the Department of Health announced the results of a study which found that partial Zidovudine (ZDV) prophylactic regimens begun during delivery or within 48 hours after birth may have substantial benefit in reducing the risk of perinatal HIV transmission (NEJM 1998;339:1409-1414). HIV infected mothers who began ZDV prophylaxis therapy during labor and delivery had almost the same reduced rate of HIV transmission (5.3%) as HIV infected mothers who began prophylaxis during the prenatal period (5.0%). HIV exposed newborns whose mothers had never taken ZDV, but began therapy in the first 48 hours of life, experienced significantly reduced HIV transmission (9.5%) as compared to infants whose therapy was initiated after 48 hours of life (25%) and infants receiving no therapy (31.6%).
It was so hard to come up with a design for AIDS. I kept going black and red and it was hard to not make it depressing.
Permalink: Sometime_computer_commands_are_scary.html
Words: 254
Category: programming
07/18/07 05:18 - ID#40156
Surebert 3.1 is here!


Permalink: Surebert_3_1_is_here_.html
Words: 57
Category: programming
07/06/07 09:37 - ID#39974
Programming for the iphone
So anyways it gets worse. Not only can you only email photos via email. You can email only one photo per email. Basically, this translated to one picture per mobile entry from the iphone. And to make it even more ridiculous every attachment is named photo.jpg so that when they arrive the new ones were replacing the old ones.
I ended up writing a script that would take the file name and add part of the title after talking with (e:jim) about it. But as he pointed out, although I was able to script around it - what about all the grandmothers saving pictures of there grandkids all named photo.jpg. They will end up just replacing all the old photos.
Who the fucks decision was this. I think they should be fired.
Permalink: Programming_for_the_iphone.html
Words: 210
Author Info
Date Cloud
- 04/26
- 11/25
- 05/25
- 04/25
- 01/25
- 03/24
- 11/23
- 02/23
- 01/23
- 12/22
- 01/22
- 12/21
- 11/21
- 12/20
- 11/20
- 01/19
- 12/18
- 08/18
- 04/18
- 03/18
- 02/17
- 01/17
- 12/16
- 11/16
- 09/16
- 08/16
- 07/16
- 06/16
- 05/16
- 04/16
- 03/16
- 02/16
- 01/16
- 12/15
- 11/15
- 10/15
- 09/15
- 08/15
- 07/15
- 06/15
- 05/15
- 04/15
- 03/15
- 02/15
- 01/15
- 12/14
- 11/14
- 10/14
- 09/14
- 08/14
- 07/14
- 06/14
- 05/14
- 04/14
- 03/14
- 02/14
- 01/14
- 12/13
- 11/13
- 10/13
- 09/13
- 08/13
- 07/13
- 06/13
- 05/13
- 04/13
- 03/13
- 02/13
- 01/13
- 12/12
- 11/12
- 10/12
- 09/12
- 08/12
- 07/12
- 06/12
- 05/12
- 04/12
- 03/12
- 02/12
- 01/12
- 12/11
- 11/11
- 10/11
- 09/11
- 08/11
- 07/11
- 06/11
- 05/11
- 04/11
- 03/11
- 02/11
- 01/11
- 12/10
- 11/10
- 10/10
- 09/10
- 08/10
- 07/10
- 06/10
- 05/10
- 04/10
- 03/10
- 02/10
- 01/10
- 12/09
- 11/09
- 10/09
- 09/09
- 08/09
- 07/09
- 06/09
- 05/09
- 04/09
- 03/09
- 02/09
- 01/09
- 12/08
- 11/08
- 10/08
- 09/08
- 08/08
- 07/08
- 06/08
- 05/08
- 04/08
- 03/08
- 02/08
- 01/08
- 12/07
- 11/07
- 10/07
- 09/07
- 08/07
- 07/07
- 06/07
- 05/07
- 04/07
- 03/07
- 02/07
- 01/07
- 12/06
- 11/06
- 10/06
- 09/06
- 08/06
- 07/06
- 06/06
- 05/06
- 04/06
- 03/06
- 02/06
- 01/06
- 12/05
- 11/05
- 10/05
- 09/05
- 08/05
- 07/05
- 06/05
- 05/05
- 04/05
- 03/05
- 02/05
- 01/05
- 12/04
- 11/04
- 10/04
- 09/04
- 08/04
- 07/04
- 06/04
- 05/04
- 04/04
- 03/04
- 02/04
- 01/04
- 12/03
- 11/03
- 10/03
- 09/03
- 08/03
- 07/03
Category Cloud
- 24 linwood
- animals
- art
- basra
- bathroom
- biking
- birthdays
- body
- botanical gardens
- brushwood
- buffalo
- camping
- cars
- clothes
- clothing
- computers
- dancing
- food
- furniture
- games
- haircut
- haircuts
- halloween
- hiking
- holidays
- house
- key west
- mobile
- music
- nature
- pets
- provincetown
- rochester
- swimming
- toronto
- toys
- travel
- vacation
- weather
- wedding
- weddings
- work
- accidents
- allentown
- android
- animals
- apple
- architecture
- art
- artvoice
- bars
- bathroom
- beach
- bikes
- biking
- birthdays
- body
- books
- brushwood
- buffalo
- buffalo rising
- bugs
- buildings
- camping
- cancer
- cars
- cats
- central terminal
- childhood
- church of the ascension
- clothes
- clothing
- computer
- computers
- conference
- crohns
- dance
- dancing
- dentist
- design
- downtown
- drugs
- electronics
- elmwood
- energy
- environment
- estrip
- events
- exercise
- family
- festivals
- firecracker
- food
- friends
- furniture
- gadgets
- games
- garden
- gay
- government
- gym
- hair
- haircut
- haircuts
- halloween
- hardware
- health
- hiking
- history
- holiday
- holidays
- house
- housing
- jewlery
- kenmore
- key west
- life
- linux
- linwood
- love
- marriage
- media
- mobile
- mobl
- movies
- music
- mustache
- nature
- nikon
- opinion
- orange tongue
- party
- peeptalk
- people
- pets
- photos
- poetry
- politics
- portland
- pride
- programming
- property
- protest
- random
- recycling
- religion
- rememberbuffalo
- renting
- school
- shoes
- shopping
- sports
- stress
- stuff
- swimming
- technology
- television
- thesis
- thursday
- thursdays
- toys
- transportation
- travel
- vacation
- vegas
- war
- water
- weather
- web
- wedding
- weddings
- weekend
- windows
- winter
- work
- world
- youtube
- zooey

mobile


:::link:::
:::link:::
- Z
If I click on the upload multiple images button, I get the spinning beachball and then am forced to quit out of the browser after a few minutes of no activity.
I'll try updating flash and seeing if that fixes it.