Monday, 20 May 2013

Begginer webdeveloper. How to make development right?

Begginer webdeveloper. How to make development right?

I am at the beginning of my programmer career. I work in some local company for over six months. In the company there are about 55 programmers and webdevelopers and it is the biggest webdev company within a radius of 100 km around my home. What is more, the company creates websites and webapplications for the large companies from my country.
My company for the last 10 years have been developing its own PHP framework. And that's my main problem. For me it is quite hard and tiresome to develop and maintain websites in this framework.
Let me give an example. It is very often, that JavaScript scripts are attached as follows:
<?php
$i = some_function($some_input);
$j = whatever($whatever);

$script = '
    var i = ' . $i . ';
    var j = ' . $j . ';
    alert(i + j);'
 echo $script;
?>
Of course code above is simplified, I wanted to show you general design.
Another example: templates. For me the real ordeal.
<?php if(!empty($products)) ?>
    <?php foreach ($products as $product) ?> 
        <div class="product-<?php echo $product['symbol'] ?>">
            <?php echo $product['name'] ?>
        </div>
    <?php endforeach ?>
<?php endif ?>
Is it frequent approach? I found it quite hard and tiring to debug and improve sites written as above.

No comments:

Post a Comment