Wednesday 27 February 2013

Articulating articles of art

Today I managed to write 3 articles for my photography tips website, though I only actually completed one of them. I had them all written by mid afternoon, then spent most of the rest of the afternoon and part of the evening trying to get some photos to illustrate them. I wasn't very successful at that, which is why I have only one of the articles finished.

Tuesday 26 February 2013

Lagging behind

Today I managed to write an article, woohoo! Of course, really I should have written 3 articles today to make up for only doing 1 yesterday. (2 articles a day over 5 days will make the 10 articles I am aiming to write this week). Still, 1 article is better than none.

I also had a $5 Zinio credit, but I found it quite hard to choose a magazine to spend it against. One of the magazines I considered was a special edition of Amateur Photographer called Advanced Photography Skills. Sounds great for me.

But then you read the features on the front cover. When it includes things like Using Layers and Shooting RAW, you have to really ask yourself, does it actually cover any advanced photography skills, or just basics? Maybe it does cover a few advanced techniques, but you wouldn't think so from what the front cover mentions.

There were actually quite a few magazines like this, promising advanced technical tips etc. but only mentioning basic tips on the cover. One even boasted that it featured something like 12 pages on RAW. Really? I can't really see how they can cover 12 pages of advanced techniques on RAW, my guess is that they just cover the different adjustments you can make in LR / ACR, and maybe opening as a smart object in PS.

Anyway, I bought one of these mags, it was only 20p. It did say on the cover something about street photography tips, so that might have something new in it I don't know.

Monday 25 February 2013

Why I've stopped using Fotomoto

I forgot to write a couple of weeks ago that I decided to stop using Fotomoto on my photography website. I think I had been using it for about a year, but only received one order. I did have quite a few images listed in the Fotomoto dashboard, so people had been clicking to look at prints. Whether they didn't order was down to the cost, a print size they wanted not being available, or they never intended to order but were just curious about the pricing, who can say?

Anyway, I stopped using Fotomoto because of the one order that I did get. It was an order for 10 postcards. I thought that Fotomoto processed the order, then sent you the profit. Actually what happens is that the payment is paid from the purchaser directly to you. Fotomoto then takes their cut from you (an automatic debit via Paypal).

Then you need to choose whether to use Fotomoto to process the order, or to self fulfil. For the postcards, if you choose to fulfil via Fotomoto, then they use Bay Photo in the US for processing the order. This was no good as

  1. The cost was too high when postage was taken into account since the person ordering the cards was in the UK.
  2. The delivery time would take too long, and according to Fotomoto the customer had selected 'Express' shipping.

So I decided to self fulfill the order. Getting 10 postcards printed is not easy. I looked at RedBubble, but they also get their postcards printed in the US. Eventually I settled on Moo.com. The minimum order was 20 cards, but this just meant I could get some extra cards for myself.

The next issue was that the Fotomoto widget only allowed the buyer to select a crop of the image where the image was cropped to fit the card. I thought they had an option that allowed the buyer to select the whole image, but it turns out that this is for prints only (and then they cut the print size down to remove the borders).

So I emailed the buyer with the different crop options, so they could choose which one they wanted. As it turned out, they wanted the default one (cropped to fit) that Fotomoto gives anyway. In their reply though, they mentioned text on the back of the card.

It's a good job they did, as no mention of text on the back of the card is made in the order details that you can get from Fotomoto. I enquired about this with Fotomoto, and apparently letting you know that the purchaser added text (through their order widget) is not a feature they provide. So

  1. If you self fulfil, you could easily send an order not knowing that text was (or could be) added to the back of the card, ending up with an unhappy customer when they receive their order with the text missing
  2. If you do realise that text can be added and that Fotomoto won't tell you when text has been added, you then have to email the customer asking them if they added any text, what that text was, the font and font size etc. Since they had already done this as part of the order process, this is quite unprofessional.

Anyway, in the end I did get it sorted by emailing the customer, and thankfully they were a nice person. I got 11 cards printed with their design (an extra one just in case anything went wrong with one of their other cards), and 9 printed with my own designs.

With Moo the front of each card can be different, but the back must be the same. So on my 9 cards I have the text the customer ordered printed on the back. This is only a small amount of text, nothing personal, and can easily be covered with a blank sticker.

They estimated that it would take a little less than a week until the cards were printed and ready for shipping. I felt I had to pay for expedited shipping since the customer had paid for 'Express' shipping, and there had already been a delay of a couple of days while I got the issues with the cropping and text sorted. (Though these two days were the weekend thankfully and not working days).

This put me a bit out of pocket on the overall transaction. But I would rather take a small loss on the order than disappoint the customer.

So the postcards arrived here a few days after ordering, I then posted the customer's ones on to them. Moo are quite good in that the postcards come in an outer moo branded sleeve with a removal unbranded sleeve that contains the postcards inside. This then has a slot that you can fit a business card into if you wanted. I didn't bother with this, and just sent them on in the unbranded white sleeve.

I sent them 1st class, and I was hoping they would arrive with the customer the next day, since it was a local address. Unfortunately it didn't, and arrived the day after, which still isn't too bad. So the customer ordered on Friday afternoon and received the item the next Saturday (just over a week). I'm not sure if that qualifies as 'Express', but certainly faster than it would have been from the US. The customer seemed happy enough anyway.

So, with all that trouble, I don't think it's worth using Fotomoto unless you are in the US. My plan is to just offer image licenses, and then let people print the photos using whatever service they want, with a list of suggested services.

This way there's no hassle for me, people can get the image printed and cropped however they like, add text to it, etc, and get it printed using a local printer if they wish. So better for me and better for the customer. It will probably be a while until I get round to implementing this though. For the moment, I have just removed Fotomoto from my website.

Today I was just working on an article for my photo tips website. I was hoping to get at least 2 articles written, but actually I have completed the grand total of 0. I have nearly finished one though, I just need to do a bit of fact checking and probably change part of it I've written that seems to be incorrect.

Sunday 24 February 2013

Snout as train jazz folk

Today I started doing some work on the church website and went to church.

In the afternoon and some of the evening I did some cooking, making brownies and ginger cake.

In the evening I also watched Yan San and went on Wii Sports Resort with Zilberto.

The End.

Saturday 23 February 2013

Websiting

Today I uploaded the update for my pog website. As part of the update I changed the way that URLs are displayed / created. Most pages weren't affected, but some were.

Most of the rest of the day was spent trying to find and fix links to pages where the URL had changed. The old URLs still worked, just they generated a 302 redirect. In my opinion it is better to just have the links going straight the page than through a 302, so I wanted to update all these affected links.

In the evening me, Mauser, and Billy went to Joules Yard for a meal. It was Cajun night, and we had a nice meal with strawberry cheesecake for pudding. There was a band playing called Ock 'n' Dough, who were described as being an Anglo-Latvian Cajun Ceilidh band.

So we thought they would be a sort of Eastern European folk mixed with Gaelic band. But actually the Cajun part of their description was the important bit, and they were more like American country. They were quite good though. We only stayed for an hour and a half, then went back home.

After that I listened to Jean Jacques (Perrey) for a bit, then Billy went to see KK.

Friday 22 February 2013

MS, you waste my time

I spent a lot of today just waiting for my VMs (used for testing websites on different IE versions) to update. The updates are just so incredibly slow to download and install. Why can't MS just allow you to install more than one version of IE on a computer? (Or even better add automatic updating like Chrome and FF do - then I wouldn't need to worry about testing sites in older versions of IE at all).

I also went to see someone to help them with some website stuff.

I finished off an article for my photo tips website that I'd written most of a couple of weeks ago. And I took a few more flower photos.

Thursday 21 February 2013

Websiting

Today I was just doing more website work. Mostly I was trying to get some javascript working on a form again. Since I have now changed the structure of the form, the javascript couldn't work as the ids etc. of the elements it was trying to access didn't exist.

It took me a long time to get it working, and it is pretty messy code-wise. When I have more time I should probably rewrite all the javascript for the site, maybe using jquery instead of plain js.

Yesterday I had a problem when I wanted to sort an database result set in alphabetical order, but many of the records had NULL for the field I wanted to sort on. This meant that all the rows with NULL for the field being sorted on came at the start of the result set, when I wanted them at the end. There are quite a few different solutions here: MySQL Orderby a number, Nulls last.

In the end for my solution, I just used IFNULL(field, 'Unknown') for the field I wanted to sort on. This worked best for my particular situation.

Today I had an issue where I needed to get the URL of the current page in PHP, minus the query string. I found there is actually a PHP function you could use to do this: parse_url. However, this returns quite a bit of information. I thought that it might actually be faster to just do substr($_SERVER['REQUEST_URI'], 0, strpos($_SERVER['REQUEST_URI'], '?')), so I am using that instead (and storing the result in $_SERVER['REQUEST_URI_NO_ARGS']).

When doing the javascript validation of the form, one of the problems I had was accessing the form elements that used arrays in their names (which was all of them). W3 schools gives an example of accessing a form element using js based on the name, but no examples where the name contains an array: W3 Schools - JavaScript Form Validation.

I found the answer to my problem here: HTML form input tag name element array with JavaScript. The answer is that the name attribute is just treated as a string in javascript. So while a form element with a name of records[27][country][123][name] would be accessed as $_POST['records'][27]['country'][123]['name'] in PHP, in js it is just accessed as form.elements['records[27][country][123][name]'].

While working on the javascript, I had to access the last element of an array. I was doing this using var lastItem = myArray[myArray.length-1];. I thought that there must be a method of the Array object that can be used to get the last element instead (like PHP's end()). But it turns out that there isn't: last element of array in javascript.

Another problem I had was trying to find specific nodes in a section of HTML cloned from the page, but not yet inserted back into the document. In the end I didn't need this, but there is some info on this here: Is there any way to find an element in a documentFragment?.

Firefox with its autocomplete refilling form fields with previous values when a page is refreshed struck again. This time I noticed the issue with a hidden field. Luckily I spotted it, and so added autocomplete="off" to the hidden fields. Depending on what actions the user had taken, these hidden fields could have included references to data that was no longer existing in the form once the page had been refreshed, and so could have caused some problems. More about this issue here: How can I prevent Firefox's Autocomplete?.

The last issue I had was with checking the type of an object. I thought I remembered that typeof would give 'object' for an array. I didn't actually need this, as I knew my data would only be a string or an array, so I could just check for typeof myvar == 'string' and if not assume it was an array. But there is more info on this here: Finding Variable Type in JavaScript.

Stack Overflow is a really great resource, it often comes up with answers to my questions in the search results. Probably the best thing about it though is that you usually get opinions from a few different people rather than just one person's way of doing something. This allows you to choose the best method that works for you.

Wednesday 20 February 2013

Websiting

This morning I was doing some website work. I had a couple of SQL queries to clean up unused values from tables. But the queries were very slow.

Looking into this, I found recommendations to use JOINs as using IN and subqueries is very slow. (I was using NOT IN with a subquery). MYSQL Delete w/ Join and MySQL Forums :: Optimizer & Parser :: 'not in' query is very slow how to change it?. Sure enough, when I changed my queries to use joins, they were immensely faster.

Doing var_dump on an array while doing some debugging, I noticed that the integer values pulled from the database were strings. This doesn't really matter for my purposes, but I thought it would be better if the types were retained from the database. Doing a quick search, it seems that it just doesn't work this way with MySQL though: MySQL integer field is returned as string in PHP. I wonder why the driver has not been written to keep types?

Most of the rest of the day I was just doing website work. I actually (kind of) got some work done today. Though it's just re-writing existing functionality, so you could say I didn't get anything new done.

Tuesday 19 February 2013

Samwise

This morning I finally finished off the pictures for the Christmas video. (Of course, we may need some more yet, but I think that I have everything covered).

The rest of the day I was trying to take photos of some cut flowers.

At the weekend I won an auction for an Ortho EL-Nikkor that the listing said was good for UV photography, but unfortunately my bid wasn't high enough to meet the reserve price. The seller has now relisted it for £430, which is way more than I can afford. :(

Sunday 17 February 2013

Why does everything take so long?

The past week I was hoping to get the Christmas video finished and do some work on a couple of my websites, amongst other things. I didn't do any blogging (thinking particularly of my photo tips blog that I normally try to write 3 articles for weekly, but I didn't do any blogging on any of my blogs) so that I could get these tasks done.

But it is now the end of the week and I haven't even managed to finish the Christmas video, let alone the website tasks. Typical. Main problem was, as usual, people constantly falling over, heads falling off, hands falling off, etc.

I also had to make a new model for the end since it was meant to have the boy getting a present, but I'd killed the boy off. So I needed a new child model. I used the armature of the dead boy, painted his shoes black, and gave him new plasticine clothes, and a new head. The head (and clothes) I tried to make look like Ivan from Ivan's childhood.

I think through the coming week I am going to try putting off doing my photo tips blog posts again, and concentrate on finishing the tasks I wanted to complete this week.

Tuesday 5 February 2013

No articles written at all!

This morning I was just going through my emails and doing a couple of odd jobs.

In the afternoon I did some photos of a daffodil.

In the evening I watched An Idiot Abroad and David Roberts with Mauser and Bo. After that I finished writing a blog post I'd been writing in the afternoon for my photo website. I posted that then linked to it from social media websites. Now it's time for bed. Bye! Zzzzz....

Monday 4 February 2013

GRRRR!

Today I was just working on an article for my photo tips website. I had the article written by 10:45am, so I thought I should be able to spend the afternoon getting some website work done.

But finding suitable images to illustrate the article with (plus doing some odd bits of housework) took up all the afternoon.

In the evening I watched a episode of An Idiot Abroad and David Roberts with Billy and Mauser, then did a bit of exercise. That took up most of the evening, and so I didn't even actually finish my article today. GRRRR!

Sunday 3 February 2013

annoying computer stuff

This morning I found that networking (internet connection) wasn't working on my Ubuntu VM. Eventually (by the afternoon) I managed to fix it by using Synaptic to uninstall open-vm-tools (and similar packages), then restarting. After I had it working, I installed them again and networking went down again, but then after restarting again, it was okay. Strange.

I'm not sure what they do anyway, as copy / paste still doesn't work between the VM and the host OS.

In the afternoon I did a little work on my pog website. I had an error like:

Warning: require_once(mynamespace/Exception.php): failed to open stream: No such file or directory in /path/to/files in file.php on line XX

I had decided to try using namespacing when rewriting a bit of my site's code into classes. But what I hadn't thought of / realised is that of course when you are in that namespace, any new objects you try to create will be resolved relative to the current namespace, unless you specify an absolute path, e.g.

namespace mynamespace;
class myclass{
 public function wrong(){
  //tries to create a new /mynamespace/Exception object
  throw new Exception();
 }
 
 public function right(){
  //will create a new global namespace (normal) Exception object
  throw new \Exception();
 }
}

I did some reading, and it seems that namespaces are only really a good idea for frameworks, classes you might want to use in multiple projects, or large projects. I also didn't realise that all constants and functions will attempt to resolve to the current namespace, and then fall back to the global namespace. So I would guess this should be slower than just working in the global namespace. So I think I'll change my code back to not using a namespace.

Saturday 2 February 2013

Not much

I spent a lot of this morning just reading a forum thread Is Street Photography an Invasion of Privacy?.

I also fixed the manual adapter for my OM10, which was previously very stiff. I found some very good instructions on how to do it here: MANUAL ADAPTOR... ARRRRRRGGGGHHHH!!! It's very simple really:

  1. Make a note of current setting on the adaptor
  2. Undo the screws on the back of the adaptor then pull in half.
  3. Squirt WD-40 on the rear of the front-half of the adaptor
  4. Turn dial a few times, then clean up WD-40.
  5. Put dial back to previous setting, then put the adaptor back together again.

Works really well.

In the afternoon I went out on a walk with Mauser and Bo. We got stopped by a policeman who said there had been a incident in Lubenham, so he wanted to take our details. So I gave him my details and took his collar number.

In the evening I watched an episode of Idiot Abroad and David Roberts with Billy and Bo, then did an Island Lap with them.

Friday 1 February 2013

Now how did that fit in?

This morning I prepared my pog website update for Sunday.

Then I started reading the OM10 manual and cleaned the camera. When I took the lens off to clean it, there was a big bit of black stuff inside it (like a small flake of paint or plastic that had peeled off. So I started to take the lens apart to clean it.

After lunch I carried on with my lens cleansing operation, but realized that actually the dirt appeared to be nearer the front of the lens than the back (which is what I was dismantling). Looking carefully at the front of the lens, I saw two small slots that looked like you were meant to put tweezers in them to be able to unscrew the front.

After doing some googling, it did appear that the front of the lens could be unscrewed. However, when I picked up the lens I noticed an aperture blade was now loose inside the lens. Oh dear...

After a bit I managed to get the front of the lens open and take all the aperture blades out, then fit them, and put the different bits together again. Putting each bit together again too me ages as I always couldn't remember how bits fitted together.


Pretty sure the aperture's not meant to look like that

Dismantled lens

Putting the aperture back together

By the end of the afternoon, I had managed to successfully put the lens back together again. There were a couple of issues though. One was that the DOF preview button would stay stuck down (and the aperture stay closed) when the rear of the lens was screwed on tightly.

The other issue was that a couple of bits had fallen out of the lens while I was taking it apart. They were used for the aperture click stops, so I thought Never mind, I'll get a stepless aperture lens as a bonus. But when the lens was mounted on the camera, the aperture would always drift to f/16.

So I had to undo the lens again, put the aperture click bits back (very fiddly), then put the lens back together again. At least if I want a stepless aperture 50mm lens in the future I know how to get one.

In the evening I watched An Idiot Abroad, David Roberts, and did an Island lap with Mauser and Bo.