<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-5865571627745262767</id><updated>2011-04-21T20:38:14.258-07:00</updated><category term='linux'/><category term='prototype.js'/><category term='platform'/><category term='php'/><category term='Javascript'/><category term='ec2'/><category term='ajax'/><category term='iframe'/><category term='programming'/><category term='development'/><category term='designmode'/><category term='actionscript xml web development web2.0'/><category term='julklapp'/><category term='startup'/><category term='padding'/><category term='scriptaculous'/><category term='julpaket.com'/><category term='Google Rank'/><category term='API'/><category term='readwriteweb'/><category term='Increase Visitor'/><category term='sed'/><category term='library'/><category term='replace'/><category term='ViralIcon'/><category term='firefox'/><category term='ui'/><category term='find'/><category term='technical recommendation'/><category term='web2.0'/><category term='zend framework'/><category term='ViralLink'/><category term='start'/><category term='grep'/><category term='tips for founders'/><category term='framework'/><category term='zend'/><category term='Rank'/><category term='image crop'/><category term='julklappar'/><title type='text'>Short scripts and stuff</title><subtitle type='html'></subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://somescripts.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5865571627745262767/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://somescripts.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Mattias Aspelund</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='21' height='32' src='http://4.bp.blogspot.com/_ThLXP21fsaA/Sf8weW7REQI/AAAAAAAABEw/4peHXxOG_bE/S220/mattias_privatbild.jpg'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>12</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-5865571627745262767.post-4984813579051863960</id><published>2009-05-19T01:57:00.000-07:00</published><updated>2009-05-19T02:04:56.519-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><category scheme='http://www.blogger.com/atom/ns#' term='find'/><category scheme='http://www.blogger.com/atom/ns#' term='grep'/><category scheme='http://www.blogger.com/atom/ns#' term='replace'/><category scheme='http://www.blogger.com/atom/ns#' term='ec2'/><category scheme='http://www.blogger.com/atom/ns#' term='sed'/><title type='text'>Find and replace in text files recursive using grep and sed</title><content type='html'>I've created a small shell script for searching and replacing text in multiple files in a subdirectory.&lt;br /&gt;My reason was that I needed a tool to change the ip-address of several mysql-servers in several files named config.ini, all residing in subdirectories.&lt;br /&gt;The syntax is:&lt;br /&gt;&lt;pre&gt;$ ./myfile.sh old-ip new-ip&lt;/pre&gt;&lt;br /&gt;And here is the script:&lt;br /&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;#!/bin/sh&lt;br /&gt;for fl in `find ./* | grep config.ini$`;&lt;br /&gt; do&lt;br /&gt; (&lt;br /&gt;  echo $fl&lt;br /&gt;  sed --in-place "s/$1/$2/g" $fl&lt;br /&gt; )&lt;br /&gt; done&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;The reason for me doing this is that I'm using Amazon EC2. For a fast connection, I need to use the EC2 internal IP. When I for some reason need to change the MySQL server to be called, that internal ip is changed, and hence I need to change my config files.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5865571627745262767-4984813579051863960?l=somescripts.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://somescripts.blogspot.com/feeds/4984813579051863960/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5865571627745262767&amp;postID=4984813579051863960' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5865571627745262767/posts/default/4984813579051863960'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5865571627745262767/posts/default/4984813579051863960'/><link rel='alternate' type='text/html' href='http://somescripts.blogspot.com/2009/05/find-and-replace-in-text-files.html' title='Find and replace in text files recursive using grep and sed'/><author><name>Mattias Aspelund</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='21' height='32' src='http://4.bp.blogspot.com/_ThLXP21fsaA/Sf8weW7REQI/AAAAAAAABEw/4peHXxOG_bE/S220/mattias_privatbild.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5865571627745262767.post-5075466368446261606</id><published>2008-10-22T18:11:00.001-07:00</published><updated>2008-10-22T18:19:45.850-07:00</updated><title type='text'>PHP: imagecopyresampled results in part black images</title><content type='html'>When using imagecopyresampled parts of the destination images was black. I solved this by using a script found on PHP.net that increases the memory limit for PHP, since large source images requires large amount of memory.&lt;br /&gt;&lt;br /&gt;I did some modifications though, since I wanted the script to work for jpeg, gif and png, and I also returned the original memory limit for the script so that it would be easy to restore the memory limits after the image processing. &lt;br /&gt;&lt;br /&gt;Anyway, here's the script:&lt;br /&gt;&lt;pre style='color:#0000cc;font-size:10px;'&gt;&lt;br /&gt;    /**&lt;br /&gt;     * Increases the memory limit for PHP so that images can be loaded&lt;br /&gt;     *&lt;br /&gt;     * @param string $filename - full path to the image file to be used&lt;br /&gt;     * @return int - old memory limit so that you can restore the memory limit after image processing&lt;br /&gt;     */&lt;br /&gt;    function _memorySize($filename){&lt;br /&gt;      $imageInfo = getimagesize($filename);&lt;br /&gt;&lt;br /&gt;      if(strpos($filename,'.jpg')===false){&lt;br /&gt;       $imageInfo['bits']=24;&lt;br /&gt;       $imageInfo['channels']=16;&lt;br /&gt;      }&lt;br /&gt;  $MB = Pow(1024,2);   // number of bytes in 1M&lt;br /&gt;  $K64 = Pow(2,16);    // number of bytes in 64K&lt;br /&gt;  $TWEAKFACTOR = 1.8;   // Or whatever works for you&lt;br /&gt;  $memoryNeeded = round( ( $imageInfo[0] * $imageInfo[1]&lt;br /&gt;                                          * $imageInfo['bits']&lt;br /&gt;                                          * $imageInfo['channels'] / 8&lt;br /&gt;                            + $K64&lt;br /&gt;                          ) * $TWEAKFACTOR&lt;br /&gt;                       );&lt;br /&gt;  $memoryHave = memory_get_usage();&lt;br /&gt;  $memoryLimitMB = (integer) ini_get('memory_limit');&lt;br /&gt;  $memoryLimit = $memoryLimitMB * $MB;&lt;br /&gt;  if ( function_exists('memory_get_usage') &lt;br /&gt;       &amp;&amp; (($memoryHave + $memoryNeeded) &lt; $memoryLimit) &lt;br /&gt;     ) {&lt;br /&gt;     $newLimit = $memoryLimitMB + ceil( ( $memoryHave &lt;br /&gt;                                        + $memoryNeeded &lt;br /&gt;                                        - $memoryLimit &lt;br /&gt;                                        ) / $MB &lt;br /&gt;                                      );&lt;br /&gt;     ini_set( 'memory_limit', $newLimit . 'M' );&lt;br /&gt;     return $memoryLimitMB;&lt;br /&gt;  }&lt;br /&gt;  return false;     &lt;br /&gt;    }&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5865571627745262767-5075466368446261606?l=somescripts.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://somescripts.blogspot.com/feeds/5075466368446261606/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5865571627745262767&amp;postID=5075466368446261606' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5865571627745262767/posts/default/5075466368446261606'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5865571627745262767/posts/default/5075466368446261606'/><link rel='alternate' type='text/html' href='http://somescripts.blogspot.com/2008/10/php-imagecopyresampled-results-in-part.html' title='PHP: imagecopyresampled results in part black images'/><author><name>Mattias Aspelund</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='21' height='32' src='http://4.bp.blogspot.com/_ThLXP21fsaA/Sf8weW7REQI/AAAAAAAABEw/4peHXxOG_bE/S220/mattias_privatbild.jpg'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5865571627745262767.post-8757051507236339224</id><published>2008-10-22T17:56:00.000-07:00</published><updated>2008-10-22T18:20:22.570-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='firefox'/><category scheme='http://www.blogger.com/atom/ns#' term='Javascript'/><category scheme='http://www.blogger.com/atom/ns#' term='padding'/><category scheme='http://www.blogger.com/atom/ns#' term='designmode'/><category scheme='http://www.blogger.com/atom/ns#' term='iframe'/><title type='text'>Setting margin, padding and designMode enable a javascript created iframe in Firefox</title><content type='html'>It was a little bit tricky to designMode enable and change the style of a javascript created iframe in firefox.&lt;br /&gt;&lt;br /&gt;Anyway, the trick seems to be to wait a little with a setTimeout before setting designMode='on' and changing the style of the javascript created iframe. &lt;br /&gt;&lt;br /&gt;My successfull code looks like this [Firefox only, not IE]:&lt;br /&gt;&lt;br /&gt;&lt;pre style='color:#0000cc;font-size:10px;'&gt;&lt;br /&gt;function addEditableField(parent, iframeId){&lt;br /&gt;  // Create the iframe, give it an id and attach it to an existing dom-element&lt;br /&gt;  var newIFrame = document.createElement('iframe');&lt;br /&gt;  newIFrame.id = 'iframeId';&lt;br /&gt;  document.getElementById(parent).appendChild(newIFrame);&lt;br /&gt;  // Wait a little for the iframe document to be prepared before doing stuff to it&lt;br /&gt;  setTimeout("enable('"+iframeId+"')",20);&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;function enable(id){&lt;br /&gt;  // Now some time has passed, so now we can play with the iframe:&lt;br /&gt;  document.getElementById(id).contentWindow.document.designMode='on';&lt;br /&gt;  document.getElementById(id).contentWindow.document.body.style.margin = '3px';&lt;br /&gt;  document.getElementById(id).contentWindow.document.body.style.padding = '3px';&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;addEditableField('parentDiv','testField');&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;And that's it. (Btw, sorry for the long title, but I prefer to know what I'll get when I go somewhere using google).&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5865571627745262767-8757051507236339224?l=somescripts.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://somescripts.blogspot.com/feeds/8757051507236339224/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5865571627745262767&amp;postID=8757051507236339224' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5865571627745262767/posts/default/8757051507236339224'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5865571627745262767/posts/default/8757051507236339224'/><link rel='alternate' type='text/html' href='http://somescripts.blogspot.com/2008/10/setting-margin-and-padding-on.html' title='Setting margin, padding and designMode enable a javascript created iframe in Firefox'/><author><name>Mattias Aspelund</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='21' height='32' src='http://4.bp.blogspot.com/_ThLXP21fsaA/Sf8weW7REQI/AAAAAAAABEw/4peHXxOG_bE/S220/mattias_privatbild.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5865571627745262767.post-1228186631840824084</id><published>2008-09-30T03:35:00.000-07:00</published><updated>2008-09-30T03:41:30.863-07:00</updated><title type='text'>All your graphs are belong to us - Google Visualization</title><content type='html'>&lt;a href="http://code.google.com/apis/visualization/images/visualization.gif"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 320px;" src="http://code.google.com/apis/visualization/images/visualization.gif" border="0" alt="" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;I don't know if I've lived under a stone or something, but I missed the release of &lt;a href='http://code.google.com/apis/visualization/'&gt;Google Visualization&lt;/a&gt;. It's a great javascript library for making increadible graphs of all types of the same type as google use on Google Analytics.&lt;br /&gt;&lt;br /&gt;I tried it yesterday and the results where amazing. I replaced some old gif graphs with Google graphs, and suddenly I had beautiful, interactive graphs created on the fly!&lt;br /&gt;&lt;br /&gt;I know I've said it before - I really, really like Google, and tools like these are one of many many reasons.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5865571627745262767-1228186631840824084?l=somescripts.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://somescripts.blogspot.com/feeds/1228186631840824084/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5865571627745262767&amp;postID=1228186631840824084' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5865571627745262767/posts/default/1228186631840824084'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5865571627745262767/posts/default/1228186631840824084'/><link rel='alternate' type='text/html' href='http://somescripts.blogspot.com/2008/09/google-visualization-hidden-gem.html' title='All your graphs are belong to us - Google Visualization'/><author><name>Mattias Aspelund</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='21' height='32' src='http://4.bp.blogspot.com/_ThLXP21fsaA/Sf8weW7REQI/AAAAAAAABEw/4peHXxOG_bE/S220/mattias_privatbild.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5865571627745262767.post-5070041412156686297</id><published>2008-09-28T03:44:00.000-07:00</published><updated>2008-09-28T03:55:08.389-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Javascript'/><category scheme='http://www.blogger.com/atom/ns#' term='prototype.js'/><category scheme='http://www.blogger.com/atom/ns#' term='scriptaculous'/><category scheme='http://www.blogger.com/atom/ns#' term='ui'/><category scheme='http://www.blogger.com/atom/ns#' term='image crop'/><title type='text'>Easy to use Javascript Image Cropper UI with Prototype.js</title><content type='html'>&lt;a href="http://2.bp.blogspot.com/_ThLXP21fsaA/SN9iau_25NI/AAAAAAAAA5g/vUepji2YvYs/s1600-h/imagecrop.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;" src="http://2.bp.blogspot.com/_ThLXP21fsaA/SN9iau_25NI/AAAAAAAAA5g/vUepji2YvYs/s400/imagecrop.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5251023901969278162" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;I just found this &lt;a href='http://www.defusion.org.uk/code/javascript-image-cropper-ui-using-prototype-scriptaculous/'&gt;great javascript library that is an user interface for cropping images&lt;/a&gt;. It depends on both prototype.js and scriptaculous, which I like since I'm using them on all my projects. &lt;br /&gt;The code is easy to use, and I integrated it into my Zend Framework with a couple of hours work (most of the work was actually not related to the cropping ui, but with the actual file handling and image cropping).&lt;br /&gt;&lt;br /&gt;Anyway, it's great, big thanks to David Spurr! Use it, love it, tip it!&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5865571627745262767-5070041412156686297?l=somescripts.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://somescripts.blogspot.com/feeds/5070041412156686297/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5865571627745262767&amp;postID=5070041412156686297' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5865571627745262767/posts/default/5070041412156686297'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5865571627745262767/posts/default/5070041412156686297'/><link rel='alternate' type='text/html' href='http://somescripts.blogspot.com/2008/09/easy-to-use-javascript-image-cropper-ui.html' title='Easy to use Javascript Image Cropper UI with Prototype.js'/><author><name>Mattias Aspelund</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='21' height='32' src='http://4.bp.blogspot.com/_ThLXP21fsaA/Sf8weW7REQI/AAAAAAAABEw/4peHXxOG_bE/S220/mattias_privatbild.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/_ThLXP21fsaA/SN9iau_25NI/AAAAAAAAA5g/vUepji2YvYs/s72-c/imagecrop.png' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5865571627745262767.post-4156366205345952591</id><published>2008-01-21T03:09:00.000-08:00</published><updated>2008-01-21T03:18:51.068-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='startup'/><category scheme='http://www.blogger.com/atom/ns#' term='web2.0'/><category scheme='http://www.blogger.com/atom/ns#' term='readwriteweb'/><category scheme='http://www.blogger.com/atom/ns#' term='tips for founders'/><title type='text'>Readwriteweb - Tips for startups on Software Engineering</title><content type='html'>&lt;a href='http://www.readwriteweb.com/archives/36_startup_tips.php'&gt;ReadWriteWeb&lt;/a&gt; has a pretty nice story on 36 tips for web startups, from Software Engineering to PR and more :)&lt;br /&gt;&lt;br /&gt;I agree on what they say completely on the software engineering team. In short their tips are:&lt;br /&gt;1) You must have code&lt;br /&gt;2) You must have a technical co-founder&lt;br /&gt;3) Hire A+ engineers who love coding&lt;br /&gt;4) Keep the engineering team small and do not outsource&lt;br /&gt;5) Ask tough questions during the interview&lt;br /&gt;6) Avoid hiring non-technical managers&lt;br /&gt;7) Cultivate an agile culture&lt;br /&gt;8) Do not re-invent the wheel&lt;br /&gt;&lt;br /&gt;I think that the second point is the most important point, you need to have industry knowledge in your founding team (just as you should have people in your team that know the target audience)&lt;br /&gt;&lt;br /&gt;&lt;a href='http://www.readwriteweb.com/archives/36_startup_tips.php'&gt;Read the full post&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5865571627745262767-4156366205345952591?l=somescripts.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://somescripts.blogspot.com/feeds/4156366205345952591/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5865571627745262767&amp;postID=4156366205345952591' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5865571627745262767/posts/default/4156366205345952591'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5865571627745262767/posts/default/4156366205345952591'/><link rel='alternate' type='text/html' href='http://somescripts.blogspot.com/2008/01/readwriteweb-tips-for-startups-on.html' title='Readwriteweb - Tips for startups on Software Engineering'/><author><name>Mattias Aspelund</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='21' height='32' src='http://4.bp.blogspot.com/_ThLXP21fsaA/Sf8weW7REQI/AAAAAAAABEw/4peHXxOG_bE/S220/mattias_privatbild.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5865571627745262767.post-6581098331842317523</id><published>2008-01-21T02:18:00.000-08:00</published><updated>2008-01-21T02:35:08.744-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='startup'/><category scheme='http://www.blogger.com/atom/ns#' term='web2.0'/><category scheme='http://www.blogger.com/atom/ns#' term='platform'/><category scheme='http://www.blogger.com/atom/ns#' term='API'/><category scheme='http://www.blogger.com/atom/ns#' term='library'/><category scheme='http://www.blogger.com/atom/ns#' term='technical recommendation'/><title type='text'>Web2.0 Startup - What should you use?</title><content type='html'>This is a short post on what libraries, languages and such that you should use for your web2.0 startup. &lt;br /&gt;&lt;br /&gt;&lt;strong&gt;1) PHP&lt;/strong&gt;&lt;br /&gt;PHP is the most used scripting language used by millions of sites. It's proven scalable, easy to learn and every programmer knows. There are also loads of free and ready to use libraries for PHP.&lt;br /&gt;&lt;strong&gt;2) MySQL&lt;/strong&gt;&lt;br /&gt;MySQL is free, it's fast and used by companies as Google and Facebook. Let's face it, if it's good enough for Facebook, it's probably good enough for you.&lt;br /&gt;&lt;strong&gt;3) Apache&lt;/strong&gt;&lt;br /&gt;Apache is the worlds most used server and you find loads of information about it all over the web. Again, it's proven scalable, stable, and most of all, it's FREE!&lt;br /&gt;&lt;strong&gt;4) Zend Framework&lt;/strong&gt;&lt;br /&gt;Zend Framework is a platform for creating MVC (Model/View/Controller) code, mainly developed by a huge user community, IBM and Zend. Using this you get a framework for PHP for free, making it easier to debug and maintain. It also contains many great built in features for many tasks, making PHP a great alternative to platforms as .Net.&lt;br /&gt;&lt;strong&gt;5) Use Prototype.js&lt;/strong&gt;&lt;br /&gt;All sites contain lots of javascript nowadays. Javascript is a pretty nasty language, with different API's for different browsers (read Firefox and Internet Explorer). It also lacks some functionality for many modern websites such as Ajax. Prototype.js enhances javascript making it platform independent and easier to use. There is no need to reinvent the wheel, use this library that has proven a great solution for many sites, it is also pretty well documentet and has a large user community supporting it.&lt;br /&gt;&lt;strong&gt;6) Use Scriptaculous&lt;/strong&gt;&lt;br /&gt;For your modern, Web2.0 website you need animations and transitions. Use Scriptaculous since it meets many of your website's interface needs.&lt;br /&gt;&lt;br /&gt;That's it. Use this and you will have easily maintained, scalable code ready for your rapid development!&lt;br /&gt;&lt;br /&gt;&lt;a href='http://www.apache.org/'&gt;Apache&lt;/a&gt;&lt;br /&gt;&lt;a href='http://www.php.net/'&gt;PHP&lt;/a&gt;&lt;br /&gt;&lt;a href='http://www.mysql.org/'&gt;MySQL&lt;/a&gt;&lt;br /&gt;&lt;a href='http://framework.zend.com/'&gt;Zend Framework&lt;/a&gt;&lt;br /&gt;&lt;a href='http://www.prototypejs.org/'&gt;Prototype.js&lt;/a&gt;&lt;br /&gt;&lt;a href='http://script.aculo.us/'&gt;Scriptaculous&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5865571627745262767-6581098331842317523?l=somescripts.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://somescripts.blogspot.com/feeds/6581098331842317523/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5865571627745262767&amp;postID=6581098331842317523' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5865571627745262767/posts/default/6581098331842317523'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5865571627745262767/posts/default/6581098331842317523'/><link rel='alternate' type='text/html' href='http://somescripts.blogspot.com/2008/01/web20-startup-what-should-you-use.html' title='Web2.0 Startup - What should you use?'/><author><name>Mattias Aspelund</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='21' height='32' src='http://4.bp.blogspot.com/_ThLXP21fsaA/Sf8weW7REQI/AAAAAAAABEw/4peHXxOG_bE/S220/mattias_privatbild.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5865571627745262767.post-373807639800206313</id><published>2007-12-02T08:07:00.000-08:00</published><updated>2007-12-02T08:10:18.103-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='julpaket.com'/><category scheme='http://www.blogger.com/atom/ns#' term='web2.0'/><category scheme='http://www.blogger.com/atom/ns#' term='julklapp'/><category scheme='http://www.blogger.com/atom/ns#' term='julklappar'/><title type='text'>Julpaket.com - Noggrant utvalda julklappar från sveriges bästa webbshoppar.</title><content type='html'>På &lt;a href='http://www.julpaket.com'&gt;Julpaket.com&lt;/a&gt; matchas din profil mot &lt;a href='http://www.julpaket.com'&gt;noggrant utvalda julklappar&lt;/a&gt; från några av sveriges bästa webbshoppar.&lt;br /&gt;&lt;br /&gt;Man kan skapa en önskelista och sedan skicka den till sina nära och kära! Enkel och inspirerande att använda!&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5865571627745262767-373807639800206313?l=somescripts.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://somescripts.blogspot.com/feeds/373807639800206313/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5865571627745262767&amp;postID=373807639800206313' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5865571627745262767/posts/default/373807639800206313'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5865571627745262767/posts/default/373807639800206313'/><link rel='alternate' type='text/html' href='http://somescripts.blogspot.com/2007/12/julpaketcom-noggrant-utvalda-julklappar.html' title='Julpaket.com - Noggrant utvalda julklappar från sveriges bästa webbshoppar.'/><author><name>Mattias Aspelund</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='21' height='32' src='http://4.bp.blogspot.com/_ThLXP21fsaA/Sf8weW7REQI/AAAAAAAABEw/4peHXxOG_bE/S220/mattias_privatbild.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5865571627745262767.post-6783427072020735652</id><published>2007-06-24T09:44:00.000-07:00</published><updated>2008-12-10T09:21:50.815-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='start'/><category scheme='http://www.blogger.com/atom/ns#' term='startup'/><category scheme='http://www.blogger.com/atom/ns#' term='web2.0'/><category scheme='http://www.blogger.com/atom/ns#' term='ajax'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><title type='text'>So you want to be a web2.0 programmer</title><content type='html'>&lt;a href="http://4.bp.blogspot.com/_ThLXP21fsaA/Rn6nkZh2VSI/AAAAAAAAABg/_nV-jpVZAFk/s1600-h/books.png"&gt;&lt;img id="BLOGGER_PHOTO_ID_5079681673490486562" style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://4.bp.blogspot.com/_ThLXP21fsaA/Rn6nkZh2VSI/AAAAAAAAABg/_nV-jpVZAFk/s400/books.png" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Ok, there's a little buzz around web2.0 now ;-) And you want to become a part of the new wave of transforming not only the Internet but also the way business is done.&lt;br /&gt;&lt;br /&gt;You've got an idea, you know how to program, but are new to web2.0. I'll give you a crashcourse on what you need to learn and what tools to download to be a part of the new revolution.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-size:130%;"&gt;What you should learn (or know):&lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;br /&gt;&lt;li&gt;DHTML / XML&lt;/li&gt;&lt;br /&gt;&lt;li&gt;Javascript&lt;/li&gt;&lt;br /&gt;&lt;li&gt;PHP&lt;/li&gt;&lt;br /&gt;&lt;li&gt;MySQL&lt;/li&gt;&lt;br /&gt;&lt;li&gt;Flash / Actionscript&lt;/li&gt;&lt;br /&gt;&lt;li&gt;C++&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-size:130%;"&gt;What you should use:&lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;br /&gt;&lt;li&gt;Apache&lt;/li&gt;&lt;br /&gt;&lt;li&gt;PHP / Zend Framework&lt;/li&gt;&lt;br /&gt;&lt;li&gt;MySQL&lt;/li&gt;&lt;br /&gt;&lt;li&gt;Prototype&lt;/li&gt;&lt;br /&gt;&lt;li&gt;Scriptaculous&lt;/li&gt;&lt;br /&gt;&lt;li&gt;Flash&lt;/li&gt;&lt;br /&gt;&lt;li&gt;OpenBSD&lt;/li&gt;&lt;br /&gt;&lt;li&gt;C++&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;&lt;br /&gt;So why did I choose that?&lt;br /&gt;&lt;br /&gt;Well, first of all, you obviously need a web server. I choose Apache since it stable, has been around forever, and it's fast.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://1.bp.blogspot.com/_ThLXP21fsaA/Rn6oNph2VTI/AAAAAAAAABo/4jwH9h1xt6c/s1600-h/coders.png"&gt;&lt;img id="BLOGGER_PHOTO_ID_5079682382160090418" style="FLOAT: right; MARGIN: 0px 0px 10px 10px; CURSOR: hand" alt="" src="http://1.bp.blogspot.com/_ThLXP21fsaA/Rn6oNph2VTI/AAAAAAAAABo/4jwH9h1xt6c/s400/coders.png" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;p&gt;You should do most of the stuff in a scripting language because things on the web are changing at high speed, and you want to be flexible in that way. PHP is a really easy and fast scripting language, and there are plenty of good PHP-programmers out there. When your company expand, you don't want to be slowed down because all C# and Java programmers are hired by multinational companys and demand high salaries.&lt;/p&gt;&lt;br /&gt;&lt;br /&gt;Since you want to be flexible, you build your code modular. Since you want to have code that are easy to maintain, you need to have a good structure from the start. By using Zend Framework you will get all that. But don't cheat!&lt;br /&gt;&lt;br /&gt;All websites are dynamic nowadays, so you need a database. Use MySQL. It's free, is fast and it's stable.&lt;br /&gt;&lt;br /&gt;Since you want fun things to happen on your site, with lots of web2.0 features like Ajax and animations and you do most of that in javascript. What you don't want is to do all the work from scratch. Prototype and Scriptaculous is the answer. With Prototype, you enhance javascript and makes programming easy, and it also have great Ajax features. With Scriptaculous, you'll get loads of animation and drag-and-drop-functionality added to your javascript. Prototype and Scriptaculous is the way to go.&lt;br /&gt;&lt;br /&gt;But no web2.0 site with any big plans can live without Flash. It's with flash you embed video, so you need to learn that too. Flash is also great for making small games and nice animations, but it's the video part that is the essential reason for learning it.&lt;br /&gt;&lt;br /&gt;OpenBSD. As long as your site have less than a million visitors a month, a simple standard Linux-PC is ok (Windows is never ok except when you use IIS, and even then I'm not sure. Mac is just weird). But when you get Slashdotted and Techcrunched, or your facebook widget is used by hundred of thousands of simultanious users, you will need to cluster, and for clustering, OpenBSD is the best choice.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://2.bp.blogspot.com/_ThLXP21fsaA/Rn6pg5h2VUI/AAAAAAAAABw/Lo-x2ENUeK8/s1600-h/logos.png"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;" src="http://2.bp.blogspot.com/_ThLXP21fsaA/Rn6pg5h2VUI/AAAAAAAAABw/Lo-x2ENUeK8/s400/logos.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5079683812384200002" /&gt;&lt;/a&gt;&lt;br /&gt;You have to use C++ for the core of your project. PHP is nice and fast, but not fast enough for processing the input of all your visitors that wants the right content presented to them instantly. C++ modules for PHP is the answer and it's easy to use in clustered environments. (You need compiled programs when you need really good benchmarks).&lt;br /&gt;&lt;br /&gt;Well that's that. Now you have everything you need for creating 2008's version of Facebook and Digg.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;About this: Mattias Johansson have programmed since 1985, for the Internet since 1994 and holds a MSc in Engineering Physics. While programming he has tested loads of different programming environments.&lt;br /&gt;&lt;br /&gt;The combination above might not be optimal in all cases, as in the case of you being an angry Java developer, but if you go that way you will have the Gods of Programming on your side.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5865571627745262767-6783427072020735652?l=somescripts.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://somescripts.blogspot.com/feeds/6783427072020735652/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5865571627745262767&amp;postID=6783427072020735652' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5865571627745262767/posts/default/6783427072020735652'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5865571627745262767/posts/default/6783427072020735652'/><link rel='alternate' type='text/html' href='http://somescripts.blogspot.com/2007/06/so-you-want-to-be-web20-programmer.html' title='So you want to be a web2.0 programmer'/><author><name>Mattias Aspelund</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='21' height='32' src='http://4.bp.blogspot.com/_ThLXP21fsaA/Sf8weW7REQI/AAAAAAAABEw/4peHXxOG_bE/S220/mattias_privatbild.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_ThLXP21fsaA/Rn6nkZh2VSI/AAAAAAAAABg/_nV-jpVZAFk/s72-c/books.png' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5865571627745262767.post-6680550136106214793</id><published>2007-06-24T09:15:00.000-07:00</published><updated>2008-12-10T09:21:51.376-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='development'/><category scheme='http://www.blogger.com/atom/ns#' term='actionscript xml web development web2.0'/><category scheme='http://www.blogger.com/atom/ns#' term='framework'/><category scheme='http://www.blogger.com/atom/ns#' term='zend'/><category scheme='http://www.blogger.com/atom/ns#' term='php'/><category scheme='http://www.blogger.com/atom/ns#' term='zend framework'/><title type='text'>Zend Framework 1.0 - Now there is no other way</title><content type='html'>&lt;a href="http://3.bp.blogspot.com/_ThLXP21fsaA/Rn6ePJh2VQI/AAAAAAAAABQ/dAQQobZJYOM/s1600-h/zend.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;" src="http://3.bp.blogspot.com/_ThLXP21fsaA/Rn6ePJh2VQI/AAAAAAAAABQ/dAQQobZJYOM/s400/zend.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5079671412813616386" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;I was thrilled and happy when I first found Zend Framework, and now I am thrilled that it has been released in version 1.0 RC2.&lt;br /&gt;&lt;br /&gt;I've been developing for the greater part of my life and tested a great variety of programming languages and platforms. For some reason I got hooked on PHP a couple of years ago, and I guess it was because of the ease and development speed that I really couldn't let PHP go. &lt;br /&gt;&lt;br /&gt;After being involved in a project that grew much bigger than anyone initially anticipated, I realized that the language itself doesn't provide much help or ease in creating well structured work. At the same time I've read over and over about the great benchmarks of the PHP/Mysql/BSD combination compared to the Microsoft .Net alternative. Lot's of sites out there are using PHP/MySQL as their development platform serving millions of visitors, and PHP gave me a greater degree of freedom compared to the .Net alternative.&lt;br /&gt;&lt;br /&gt;Recently it was time for me to start another project, but this time I realized that I had to put a greater effort in creating a much better structure from the start. I went through lots and lots of big OS PHP-projects to find the holy grale of wellstructured code, and suddenly I found the Zend Framework! &lt;br /&gt;&lt;br /&gt;&lt;a href="http://4.bp.blogspot.com/_ThLXP21fsaA/Rn6e6Zh2VRI/AAAAAAAAABY/H-bxy2mg6aE/s1600-h/zend_modules.png"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;" src="http://4.bp.blogspot.com/_ThLXP21fsaA/Rn6e6Zh2VRI/AAAAAAAAABY/H-bxy2mg6aE/s400/zend_modules.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5079672155842958610" /&gt;&lt;/a&gt;&lt;br /&gt;Zend Framework is a framework for creating php-projects rapidly and in a nicely, robust, modular structured way. The main contributors to the projects is Zend (obviously) and IBM, so the stability of the framework compared to alternatives are great.&lt;br /&gt;It's built for using the MVC pattern architecture (Model/View/Controller) and has a wide range of modules ready to be used.&lt;br /&gt;&lt;br /&gt;Now that Zend Framework v1.0 RC2 is released I'm happy to say that after some development I'm glad to say that I'm almost overexited about the results! Great web applications are built very fast, without giving up the flexibility of PHP or a well structured code.&lt;br /&gt;&lt;br /&gt;If you're a php developer and haven't checked it out yet, I strongly encourage you to do so; it will make your life easier.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5865571627745262767-6680550136106214793?l=somescripts.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://somescripts.blogspot.com/feeds/6680550136106214793/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5865571627745262767&amp;postID=6680550136106214793' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5865571627745262767/posts/default/6680550136106214793'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5865571627745262767/posts/default/6680550136106214793'/><link rel='alternate' type='text/html' href='http://somescripts.blogspot.com/2007/06/zend-framework-10-now-there-is-no-other.html' title='Zend Framework 1.0 - Now there is no other way'/><author><name>Mattias Aspelund</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='21' height='32' src='http://4.bp.blogspot.com/_ThLXP21fsaA/Sf8weW7REQI/AAAAAAAABEw/4peHXxOG_bE/S220/mattias_privatbild.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/_ThLXP21fsaA/Rn6ePJh2VQI/AAAAAAAAABQ/dAQQobZJYOM/s72-c/zend.png' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5865571627745262767.post-2645802153145190133</id><published>2007-06-24T05:50:00.001-07:00</published><updated>2007-06-24T05:50:57.790-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ViralLink'/><category scheme='http://www.blogger.com/atom/ns#' term='ViralIcon'/><category scheme='http://www.blogger.com/atom/ns#' term='Rank'/><category scheme='http://www.blogger.com/atom/ns#' term='Google Rank'/><category scheme='http://www.blogger.com/atom/ns#' term='Increase Visitor'/><title type='text'>About ViralLinks, ViralIcons and Viral[Generic]</title><content type='html'>I've been blogging around a bit and wanted to get some tips on getting more visitors, better google rank etc, and I found lots of tips about ViralLinks, ViralIcons and other Viral things. It resembles the banner exchange programs that was popular back in the 90's and I don't remember them being that successfull. They worked a bit like a pyramid game, the earlier you joined, the better outcome you got.&lt;br /&gt;&lt;br /&gt;I might be the same thing here with Viral[Whatever], for the early top ten it probably works fine, but as the list grows I'd guess that the google search engine will decrease the rating of the links: link-pages aren't that high ranked in google.&lt;br /&gt;&lt;br /&gt;My experience is that it is almost always better to create an article about something, post it in some link-sites that are about specialized in that subject, and wait. Specialised link sites hold content that are relevant to the visitor and hence it gets a higher score than simple viral link lists. Moreover, specialized link sites are copied over and over by people starting new link sites, so you don't even have to work to get more links over time. &lt;br /&gt;&lt;br /&gt;One page I posted three years ago on one site now have 10000 links to it on google, and I didn't do anything else than the initial post.&lt;br /&gt;&lt;br /&gt;Do you agree or disagree with me?&lt;br /&gt;&lt;br /&gt;By the way, look at a really interesting blog &lt;a href="http://49things.blogspot.com"&gt;49things to do - Microsoft Surface and Apple IPhone Parody&lt;/a&gt; for some laughs (you might allready have seen them though, but my other blog is pretty fun).&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5865571627745262767-2645802153145190133?l=somescripts.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://somescripts.blogspot.com/feeds/2645802153145190133/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5865571627745262767&amp;postID=2645802153145190133' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5865571627745262767/posts/default/2645802153145190133'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5865571627745262767/posts/default/2645802153145190133'/><link rel='alternate' type='text/html' href='http://somescripts.blogspot.com/2007/06/about-virallinks-viralicons-and.html' title='About ViralLinks, ViralIcons and Viral[Generic]'/><author><name>Mattias Aspelund</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='21' height='32' src='http://4.bp.blogspot.com/_ThLXP21fsaA/Sf8weW7REQI/AAAAAAAABEw/4peHXxOG_bE/S220/mattias_privatbild.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5865571627745262767.post-8332103746837853573</id><published>2007-02-10T01:46:00.000-08:00</published><updated>2007-02-13T00:57:25.126-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='actionscript xml web development web2.0'/><title type='text'>Fetch som data from XML with actionscript</title><content type='html'>As a person used to working with good programming IDE's and well documented PHP / MySQL and C# and likes, I can't say I'm very impressed with the Actionscript documentation and Flash IDE, but at least it's nice to see that actionscript nowadays is a pretty usefull scripting language :) One of the first things I've played around with is the XML-fetching function in actionscript.&lt;br /&gt;The script is small and easy, it does one thing: Reads an xml file and displays the results in the flash movie using the flash dynamic text-type. I do this in three easy steps:&lt;br /&gt;1) Create the xml-file&lt;br /&gt;2) Setup the flash scene&lt;br /&gt;3) Create a script that reads the xml file and displays the text in the flash scene.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-size:130%;"&gt;&lt;strong&gt;1. Create the xml file.&lt;br /&gt;&lt;/strong&gt;&lt;/span&gt;When I did this I used php to fetch some data from a MySQL database. In this example I just create the XML file, not dynamic at all.&lt;br /&gt;&lt;br /&gt;The xml-file has the following content:&lt;br /&gt;&lt;br /&gt;&amp;lt;?xml version="1.0" encoding="UTF-8"?&amp;gt;&lt;br /&gt;   &amp;lt;items&amp;gt;&lt;br /&gt;      &amp;lt;item&amp;gt;&lt;br /&gt;         &amp;lt;title&amp;gt;This is a sample title&amp;lt;/title&amp;gt;&lt;br /&gt;         &amp;lt;body&amp;gt;Lorem ipsum&amp;lt;/body&amp;gt;&lt;br /&gt;      &amp;lt;/item&amp;gt;&lt;br /&gt;   &amp;lt;/items&amp;gt;&lt;br /&gt;&lt;br /&gt;I save this file to my website as www.mysite.com/test.xml&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;&lt;span style="font-size:130%;"&gt;2. Setup the flash screen &lt;/span&gt;&lt;/strong&gt;&lt;br /&gt;I start out with an empty flash movie. In layer 1 I add a text using the Text tool.&lt;br /&gt;Then I select the text and in the properties panel I change the text property from Static Text to Dynamic Text. Then by clicking right below the dropdown now saying dynamic text, I click in the field displaying &lt;instance&gt;and give the text the instance name text1.&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;&lt;span style="font-size:130%;"&gt;3. Create the script &lt;/span&gt;&lt;/strong&gt;&lt;br /&gt;Now it’s time for the fun part. In order to add the actionscript I click on the first frame on the timeline panel followed by expanding the Actions panel.&lt;br /&gt;Test the script by adding the following code:&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;&lt;span style="font-size:85%;"&gt;text1.text = 'Hello world!'; &lt;/span&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;Test the script with Control / Test Movie (Ctrl+enter).&lt;br /&gt;&lt;br /&gt;Now copy/paste the following into the actionscript code:&lt;br /&gt;&lt;br /&gt;&lt;pre style="font-size:85%;"&gt;// Create a new XML object.&lt;br /&gt;var myXml:XML = new XML();&lt;br /&gt;&lt;br /&gt;// Set the ignoreWhite property to true (default value is false).&lt;br /&gt;myXml.ignoreWhite = true;&lt;br /&gt;&lt;br /&gt;function findByNodeName(parentNode:XMLNode, nodeName:String){&lt;br /&gt;   var targetNode:XMLNode;&lt;br /&gt;   // Iterate through all the parentNode's children until the target&lt;br /&gt;   // XMLNode is found&lt;br /&gt;   for (var current_node:XMLNode = parentNode.firstChild; current_node != null; current_node=current_node.nextSibling) {&lt;br /&gt;      // Is this the one?&lt;br /&gt;      if(current_node.nodeName == nodeName){&lt;br /&gt;         return current_node;&lt;br /&gt;      }else{ // Nope, but does this XMLNode have it among it's children?&lt;br /&gt;         if(targetNode = findByNodeName(current_node, nodeName)){&lt;br /&gt;            // Yup, now return it&lt;br /&gt;            return targetNode;&lt;br /&gt;         }&lt;br /&gt;      }&lt;br /&gt;   }&lt;br /&gt;   // Nope, we didn't find any nodes with that nodename...&lt;br /&gt;   return false;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;// After loading is complete, fetch the interesting data of the XML object.&lt;br /&gt;myXml.onLoad = function(success) {&lt;br /&gt;   if(success){&lt;br /&gt;      text1.text = findByNodeName(myXml, 'newstitle').firstChild.nodeValue;&lt;br /&gt;   }else{&lt;br /&gt;      text1.text = 'Could not load the xml-file';&lt;br /&gt;   }&lt;br /&gt;};&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;// Load the XML into the flooring object.&lt;br /&gt;myXml.load("http://localhost/efterborsen.se/topnews.xml.php");&lt;br /&gt;// Stop the animation. It will be started again after the load is completed.&lt;br /&gt;stop();&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;Test this script and you have loaded some external data to your flash movie.&lt;br /&gt;I hope you like it! Enjoy!&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5865571627745262767-8332103746837853573?l=somescripts.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://somescripts.blogspot.com/feeds/8332103746837853573/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5865571627745262767&amp;postID=8332103746837853573' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5865571627745262767/posts/default/8332103746837853573'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5865571627745262767/posts/default/8332103746837853573'/><link rel='alternate' type='text/html' href='http://somescripts.blogspot.com/2007/02/fetch-som-data-from-xml-with.html' title='Fetch som data from XML with actionscript'/><author><name>Mattias Aspelund</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='21' height='32' src='http://4.bp.blogspot.com/_ThLXP21fsaA/Sf8weW7REQI/AAAAAAAABEw/4peHXxOG_bE/S220/mattias_privatbild.jpg'/></author><thr:total>0</thr:total></entry></feed>
