<?xml version="1.0" encoding="UTF-8"?>
<feed xml:lang="en-US" xmlns="http://www.w3.org/2005/Atom">
  <title>Xilinus  - English</title>
  <id>tag:blog.xilinus.com,2009:mephisto/english</id>
  <generator version="0.8.0" uri="http://mephistoblog.com">Mephisto Drax</generator>
  <link href="http://blog.xilinus.com/feed/english/atom.xml" rel="self" type="application/atom+xml"/>
  <link href="http://blog.xilinus.com/english" rel="alternate" type="text/html"/>
  <updated>2009-01-07T16:40:00Z</updated>
  <entry xml:base="http://blog.xilinus.com/">
    <author>
      <name>seb</name>
    </author>
    <id>tag:blog.xilinus.com,2009-01-07:334</id>
    <published>2009-01-07T16:35:00Z</published>
    <updated>2009-01-07T16:40:00Z</updated>
    <category term="English"/>
    <category term="Javascript"/>
    <link href="http://blog.xilinus.com/2009/1/7/speaker-fot-skillsmatter" rel="alternate" type="text/html"/>
    <title>Trainer for SkillsMatter</title>
<content type="html">
            &lt;p&gt;I am really proud to be a member of SkillsMatter to deliver courses about:&lt;/p&gt;


	&lt;ul&gt;
	&lt;li&gt; JavaScript, &lt;span class=&quot;caps&quot;&gt;JSON&lt;/span&gt; &#38; &lt;span class=&quot;caps&quot;&gt;DOM&lt;/span&gt;  &lt;/li&gt;
		&lt;li&gt; Ajax Enterprise Web Development&lt;/li&gt;
	&lt;/ul&gt;


	&lt;p&gt;The first 5-day session will start in London on February 2th. I will do this session with my friend &lt;a href=&quot;http://tobielangel.com&quot;&gt;Tobie Langel&lt;/a&gt; itself.
More sessions are coming for 2009 in London (UK), Paris (France) and Aarhus (Danmark).&lt;/p&gt;


	&lt;p&gt;I will post dates as soon as I know them.&lt;/p&gt;


	&lt;p&gt;I hope to see some of you there :)&lt;/p&gt;
          </content>  </entry>
  <entry xml:base="http://blog.xilinus.com/">
    <author>
      <name>seb</name>
    </author>
    <id>tag:blog.xilinus.com,2009-01-05:331</id>
    <published>2009-01-05T18:47:00Z</published>
    <updated>2009-01-05T18:48:51Z</updated>
    <category term="English"/>
    <category term="Javascript"/>
    <link href="http://blog.xilinus.com/2009/1/5/addresschooser-widget" rel="alternate" type="text/html"/>
    <title>AddressChooser widget by Mapeed</title>
<content type="html">
            &lt;h2&gt;Introduction&lt;/h2&gt;


	&lt;p&gt;May be some of you knows about service I launched more than one year now called &lt;a href=&quot;http://who-s-web.com&quot;&gt;who-s-web&lt;/a&gt;.
Its server-side cluster algorithm is at the origin of a new service launched few weeks ago: &lt;a href=&quot;http://www.mapeed.com&quot;&gt;Mapeed&lt;/a&gt;.&lt;/p&gt;


	&lt;p&gt;But this site has also an address form when you register with a great feature: you can check your address on a little google map before submitting it, you can even move marker if it&#8217;s not correct.
This &#8220;widget&#8221; is something you need when you let someone enter a location like a user&#8217;s address or  a place&#8217;s location for a real better user experience.&lt;/p&gt;


	&lt;p&gt;After having seeing this same kind of form on &lt;a href=&quot;http://www.google.com/local/add/lookup&quot;&gt;Google Local Business Center&lt;/a&gt;, I decided to make a Javascript component to bring this behavior with only a couple of lines of code and &lt;a href=&quot;http://addresschooser.mapeed.com&quot;&gt;Mapeed.AddressChooser&lt;/a&gt; is born :).&lt;/p&gt;


&amp;lt;center&gt;
  &lt;a href=&quot;http://addresschooser.mapeed.com&quot;&gt;&lt;img src=&quot;http://addresschooser.mapeed.com/doc/images/screenshot.png&quot; /&gt;&lt;/a&gt;
&amp;lt;/center&gt;

	&lt;h2&gt;Features&lt;/h2&gt;


	&lt;ul&gt;
	&lt;li&gt;Javascript framework-agnostic. You can use it as is or with any great frameworks like Prototype, JQuery &#8230;&lt;/li&gt;
		&lt;li&gt;Mapping system independent. The current implementation is based on Google Map using a Google Map proxy object.&lt;/li&gt;
		&lt;li&gt;Interactive map display location while you arex typing an address.&lt;/li&gt;
		&lt;li&gt;Center map on user location (based on its IP) if mapping system allows it.&lt;/li&gt;
		&lt;li&gt;Fully customizable.&lt;/li&gt;
		&lt;li&gt;Fully documented with &lt;a href=&quot;http://pdoc.org&quot;&gt;pdoc&lt;/a&gt;.&lt;/li&gt;
		&lt;li&gt;Works on Safari, Firefox, &lt;span class=&quot;caps&quot;&gt;IE 6&lt;/span&gt;/7, Chrome and Opera.&lt;/li&gt;
		&lt;li&gt;...&lt;/li&gt;
	&lt;/ul&gt;


	&lt;h2&gt;Download&lt;/h2&gt;


	&lt;p&gt;This component is free, open-source and available on github here: &lt;a href=&quot;http://github.com/mapeed/addresschooser&quot;&gt;http://github.com/mapeed/addresschooser&lt;/a&gt;.&lt;/p&gt;


	&lt;p&gt;You can also get a zip file or directly download Javascript file, checkout &lt;a href=&quot;http://addresschooser.mapeed.com&quot;&gt;official website&lt;/a&gt;.&lt;/p&gt;


	&lt;p&gt;Enjoy!&lt;/p&gt;
          </content>  </entry>
  <entry xml:base="http://blog.xilinus.com/">
    <author>
      <name>seb</name>
    </author>
    <id>tag:blog.xilinus.com,2009-01-03:327</id>
    <published>2009-01-03T16:43:00Z</published>
    <updated>2009-01-05T18:50:05Z</updated>
    <category term="English"/>
    <category term="Ruby"/>
    <link href="http://blog.xilinus.com/2009/1/3/rake-and-cap-auto-complete-for-bash-shell" rel="alternate" type="text/html"/>
    <title>rake and cap auto complete for bash shell</title>
<content type="html">
            &lt;p&gt;I love git and git auto complete bash shell. I get so used to it that I type &lt;span class=&quot;caps&quot;&gt;TAB TAB&lt;/span&gt; key even for cap and rake command.
I&#8217;ve been frustrated so many times to not have auto complete for those commands, so I spent a few time on reading git code and google for it.&lt;/p&gt;


	&lt;p&gt;And here is my result, a little script to add to your .bashrc and you will have rake and cap completion! And mix of what I read on different code/articles.&lt;/p&gt;


	&lt;p&gt;My code is available on github: &lt;a href=&quot;http://github.com/sgruhier/rake_cap_bash_autocomplete&quot;&gt;rake_cap_bash_autocomplete&lt;/a&gt;
You do not need to download the repository, just copy sheel file and check &lt;span class=&quot;caps&quot;&gt;README&lt;/span&gt; for installation.&lt;/p&gt;


	&lt;ol&gt;
	&lt;li&gt;Copy &lt;code&gt;rake_cap_bash_autocomplete.sh&lt;/code&gt; to somewhere (e.g. &lt;code&gt;~/.rake_cap_bash_autocomplete.sh&lt;/code&gt;).                              &lt;/li&gt;
		&lt;li&gt;Added the following line to your &lt;code&gt;.bashrc&lt;/code&gt;: &lt;code&gt;source ~/.rake_cap_bash_autocomplete.sh&lt;/code&gt;&lt;/li&gt;
	&lt;/ol&gt;


	&lt;p&gt;Then, if you test it in an empty rails directory for instance, you will have:
&lt;small&gt;
&lt;pre&gt;
&lt;code&gt;
$ rake TAB TAB
db:abort_if_pending_migrations  db:schema:dump                  doc:plugins                     rails:freeze:edge               test:recent
db:charset                      db:schema:load                  doc:rails                       rails:freeze:gems               test:uncommitted
db:collation                    db:sessions:clear               doc:reapp                       rails:unfreeze                  test:units
db:create                       db:sessions:create              doc:rerails                     rails:update                    time:zones:all
db:create:all                   db:structure:dump               gems                            rails:update:configs            time:zones:local
db:drop                         db:test:clone                   gems:build                      rails:update:javascripts        time:zones:us
db:drop:all                     db:test:clone_structure         gems:install                    rails:update:scripts            tmp:cache:clear
db:fixtures:identify            db:test:load                    gems:refresh_specs              routes                          tmp:clear
db:fixtures:load                db:test:prepare                 gems:unpack                     secret                          tmp:create
db:migrate                      db:test:purge                   gems:unpack:dependencies        stats                           tmp:pids:clear
db:migrate:down                 db:version                      log:clear                       test                            tmp:sessions:clear
db:migrate:redo                 doc:app                         notes                           test:benchmark                  tmp:sockets:clear
db:migrate:reset                doc:clobber_app                 notes:custom                    test:functionals                
db:migrate:up                   doc:clobber_plugins             notes:fixme                     test:integration                
db:reset                        doc:clobber_rails               notes:optimize                  test:plugins                    
db:rollback                     doc:guides                      notes:todo                      test:profile                    
&lt;/code&gt;
&lt;/pre&gt;
&lt;/small&gt;
And when you begin to enter a task command:
&lt;small&gt;
&lt;pre&gt;
&lt;code&gt;
$ rake test: TAB TAB
test:benchmark    test:functionals  test:integration  test:plugins      test:profile      test:recent       test:uncommitted  test:units        
&lt;/code&gt;
&lt;/pre&gt;
&lt;/small&gt;
If you have more than 128 commands, you will see
&lt;small&gt;
&lt;pre&gt;
&lt;code&gt;$ rake TAB TAB
Display all 128 possibilities? (y or n)
&lt;/code&gt;
&lt;/pre&gt;
&lt;/small&gt;&lt;/p&gt;


	&lt;p&gt;Same for cap&lt;/p&gt;


	&lt;p&gt;Enjoy!&lt;/p&gt;
          </content>  </entry>
  <entry xml:base="http://blog.xilinus.com/">
    <author>
      <name>seb</name>
    </author>
    <id>tag:blog.xilinus.com,2008-12-13:312</id>
    <published>2008-12-13T15:20:00Z</published>
    <updated>2008-12-16T09:51:49Z</updated>
    <category term="English"/>
    <category term="Javascript"/>
    <link href="http://blog.xilinus.com/2008/12/13/protofx-a-new-effect-engine-for-prototype" rel="alternate" type="text/html"/>
    <title>ProtoFX a new effect engine for Prototype</title>
<content type="html">
            &lt;h2&gt;Introduction&lt;/h2&gt;


	&lt;p&gt;I did this framework first of all for personal use. I could not find what I needed in script.aculo.us and honestly, I do not see any activity in &lt;a href=&quot;http://github.com/madrobby/scriptaculous/tree/master&quot;&gt;script.aculo.us&lt;/a&gt; or &lt;a href=&quot;http://github.com/madrobby/scripty2/tree/master&quot;&gt;scripty2&lt;/a&gt; (alpha version of script.aculo.us 2)&lt;/p&gt;


	&lt;p&gt;I like also &lt;a href=&quot;http://jquery.com&quot;&gt;jQuery&lt;/a&gt; when I need to just have animation. But as I use a lot &lt;a href=&quot;http://www.prototypejs.org&quot;&gt;Prototype&lt;/a&gt; to build complex web applications, I needed something based on this powerfull JS Framework.&lt;/p&gt;


	&lt;p&gt;So ProtoFX is born :)&lt;/p&gt;


	&lt;p&gt;It&#8217;s a light weight animation framework (&lt;em&gt;base&lt;/em&gt; version is less than 7Ko packed) with great features. I decided to use music semantic for class names. Running effects is like playing a song isn&#8217;t it?. The object in charge of time synchronization is called &lt;em&gt;Metronome&lt;/em&gt;. The &#8220;queue&#8221; system (I will describe it later, but it&#8217;s more powerfull than a classical queue system) is called &lt;em&gt;Score&lt;/em&gt;.&lt;/p&gt;


	&lt;p&gt;Actions are like music player actions: play/stop/reverse/rewind&#8230;&lt;/p&gt;


	&lt;p&gt;But let&#8217;s talk about ProtoFX features.&lt;/p&gt;


	&lt;h2&gt;Features&lt;/h2&gt;


	&lt;h3&gt;Easy to use&lt;/h3&gt;


	&lt;p&gt;I tryed to make an &lt;span class=&quot;caps&quot;&gt;API&lt;/span&gt; really easy to use. You just need to chain methods on an effect object. 
For example to fade an element, just do:&lt;/p&gt;


&lt;pre class=&quot;sunburst&quot;&gt;&lt;span class=&quot;line-numbers&quot;&gt;   1 &lt;/span&gt; &lt;span class=&quot;Keyword&quot;&gt;new&lt;/span&gt; &lt;span class=&quot;JEntityNameType&quot;&gt;FX.Element&lt;/span&gt;(element).animate({opacity: &lt;span class=&quot;Constant&quot;&gt;0&lt;/span&gt;}).play();
&lt;/pre&gt;

	&lt;p&gt;If you need to set some options like &lt;em&gt;duration&lt;/em&gt;  just call &lt;em&gt;setOptions&lt;/em&gt; function in chained methods.&lt;/p&gt;


&lt;pre class=&quot;sunburst&quot;&gt;&lt;span class=&quot;line-numbers&quot;&gt;   1 &lt;/span&gt; &lt;span class=&quot;Keyword&quot;&gt;new&lt;/span&gt; &lt;span class=&quot;JEntityNameType&quot;&gt;FX.Element&lt;/span&gt;(element).setOptions({duration: &lt;span class=&quot;Constant&quot;&gt;2000&lt;/span&gt;}).animate({opacity: &lt;span class=&quot;Constant&quot;&gt;0&lt;/span&gt;}).play();
&lt;/pre&gt;

	&lt;p&gt;Pretty simple!&lt;/p&gt;


	&lt;h3&gt;Actions&lt;/h3&gt;


	&lt;p&gt;As I said before, actions are like using a music player. 
You can do:&lt;/p&gt;


	&lt;ul&gt;
	&lt;li&gt;play&lt;/li&gt;
		&lt;li&gt;stop&lt;/li&gt;
		&lt;li&gt;reverse (even if the effect is running, call reverse and your animation will run backward)&lt;/li&gt;
		&lt;li&gt;rewind. Next time you call play it will play from the beginning&lt;/li&gt;
	&lt;/ul&gt;


	&lt;h3&gt;Delta&lt;/h3&gt;


	&lt;p&gt;Sometimes you do not know exactly where is your element in the page, you just want to move it of XX pixels to the left. You can use operand +=, -=, /= and *= to specify delta like this&lt;/p&gt;


&lt;pre class=&quot;sunburst&quot;&gt;&lt;span class=&quot;line-numbers&quot;&gt;   1 &lt;/span&gt; &lt;span class=&quot;Keyword&quot;&gt;new&lt;/span&gt; &lt;span class=&quot;JEntityNameType&quot;&gt;FX.Element&lt;/span&gt;(element).animate({left: &lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;+=100px&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;}).play();
&lt;/pre&gt;

	&lt;h3&gt;&#8220;Cloneable&#8221;&lt;/h3&gt;


	&lt;p&gt;One great feature is to be able to create an effect without specifying an element. Consider that like just specifying effect parameters. To be able to play it on a element, just clone the effect and call play.&lt;/p&gt;


	&lt;p&gt;This is very usefull for UI widget for instance. UI is usually created dynamically. In this case it&#8217;s pretty hard to give an effect as UI option because you do not know the element to apply the effect when you create your UI component.&lt;/p&gt;


	&lt;p&gt;With ProtoFX, you can have an effect parameter on your widget. The widget will clone it when it needs to play animation.&lt;/p&gt;


&lt;pre class=&quot;sunburst&quot;&gt;&lt;span class=&quot;line-numbers&quot;&gt;   1 &lt;/span&gt; &lt;span class=&quot;Storage&quot;&gt;var&lt;/span&gt; fx &lt;span class=&quot;Keyword&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;Keyword&quot;&gt;new&lt;/span&gt; &lt;span class=&quot;JEntityNameType&quot;&gt;FX.Element&lt;/span&gt;().animate({opacity: &lt;span class=&quot;Constant&quot;&gt;0&lt;/span&gt;});
&lt;span class=&quot;line-numbers&quot;&gt;   2 &lt;/span&gt; ...
&lt;span class=&quot;line-numbers&quot;&gt;   3 &lt;/span&gt; ...
&lt;span class=&quot;line-numbers&quot;&gt;   4 &lt;/span&gt; fx.cloneFor(element1).play();
&lt;span class=&quot;line-numbers&quot;&gt;   5 &lt;/span&gt; fx.cloneFor(element2).&lt;span class=&quot;SupportFunction&quot;&gt;reverse&lt;/span&gt;().play();
&lt;/pre&gt;

	&lt;h3&gt;Event notifications and callbacks&lt;/h3&gt;


	&lt;p&gt;As a lot of prototype add-ons, ProtoFX fire events on different actions like &#8216;fx:started&#8221;, &#8220;fx:stopped&#8221; ... You just need to observe those events if need be, as usual.&lt;/p&gt;


	&lt;p&gt;But sometimes, I think it needs too much code for simple action, so event notifications are also notify to callbacks.
So you can write code like that:&lt;/p&gt;


&lt;pre class=&quot;sunburst&quot;&gt;&lt;span class=&quot;line-numbers&quot;&gt;   1 &lt;/span&gt; &lt;span class=&quot;Storage&quot;&gt;var&lt;/span&gt; fx &lt;span class=&quot;Keyword&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;Keyword&quot;&gt;new&lt;/span&gt; &lt;span class=&quot;JEntityNameType&quot;&gt;FX.Element&lt;/span&gt;(element)
&lt;span class=&quot;line-numbers&quot;&gt;   2 &lt;/span&gt;   .onBeforeStarted(&lt;span class=&quot;Storage&quot;&gt;function&lt;/span&gt;() {element.show();})
&lt;span class=&quot;line-numbers&quot;&gt;   3 &lt;/span&gt;   .animate({height: &lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;'&lt;/span&gt;+=100px&lt;span class=&quot;String&quot;&gt;'&lt;/span&gt;&lt;/span&gt;})
&lt;span class=&quot;line-numbers&quot;&gt;   4 &lt;/span&gt;   .play();
&lt;/pre&gt;

	&lt;p&gt;Instead of&lt;/p&gt;


&lt;pre class=&quot;sunburst&quot;&gt;&lt;span class=&quot;line-numbers&quot;&gt;   1 &lt;/span&gt; &lt;span class=&quot;Storage&quot;&gt;var&lt;/span&gt; fx &lt;span class=&quot;Keyword&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;Keyword&quot;&gt;new&lt;/span&gt; &lt;span class=&quot;JEntityNameType&quot;&gt;FX.Element&lt;/span&gt;(element)
&lt;span class=&quot;line-numbers&quot;&gt;   2 &lt;/span&gt;   .animate({height: &lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;'&lt;/span&gt;+=100px&lt;span class=&quot;String&quot;&gt;'&lt;/span&gt;&lt;/span&gt;})
&lt;span class=&quot;line-numbers&quot;&gt;   3 &lt;/span&gt;   .play();
&lt;span class=&quot;line-numbers&quot;&gt;   4 &lt;/span&gt; 
&lt;span class=&quot;line-numbers&quot;&gt;   5 &lt;/span&gt; 
&lt;span class=&quot;line-numbers&quot;&gt;   6 &lt;/span&gt; &lt;span class=&quot;Support&quot;&gt;document&lt;/span&gt;.observe(&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;'&lt;/span&gt;fx:beforeStarted&lt;span class=&quot;String&quot;&gt;'&lt;/span&gt;&lt;/span&gt;, &lt;span class=&quot;Storage&quot;&gt;function&lt;/span&gt;(&lt;span class=&quot;Support&quot;&gt;event&lt;/span&gt;) {
&lt;span class=&quot;line-numbers&quot;&gt;   7 &lt;/span&gt;   &lt;span class=&quot;Support&quot;&gt;event&lt;/span&gt;.element().show();
&lt;span class=&quot;line-numbers&quot;&gt;   8 &lt;/span&gt; }  
&lt;span class=&quot;line-numbers&quot;&gt;   9 &lt;/span&gt; 
&lt;span class=&quot;line-numbers&quot;&gt;  10 &lt;/span&gt; &lt;span class=&quot;Comment&quot;&gt;&lt;span class=&quot;Comment&quot;&gt;//&lt;/span&gt; And do not forget to unregister the event!!&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;  11 &lt;/span&gt; 
&lt;/pre&gt;

	&lt;h3&gt;Element methods&lt;/h3&gt;


	&lt;p&gt;I have also added some usefull element methods that I use a lot with scripty like Element#fade/appear, Element#blindUp/blindDown. I will add more if needed.&lt;/p&gt;


	&lt;h3&gt;Based on Penner equations&lt;/h3&gt;


	&lt;p&gt;Effect transitions are based on the famous Penner equations (like jQuery). It gives nice and fluid effects like bouncing effects.&lt;/p&gt;


	&lt;h3&gt;Score&lt;/h3&gt;


	&lt;p&gt;As I said, the queue system is called &lt;em&gt;Score&lt;/em&gt;. but &lt;em&gt;Score&lt;/em&gt; is an effect itself (subclass of Fx.Base) so you can also call play/stop/reverse/rewind on it!!&lt;/p&gt;


	&lt;p&gt;You can add effect at the beginning, at the end, after a specific effect. You can add delay between effects, even negative delay for effect overlap.&lt;/p&gt;


&lt;pre class=&quot;sunburst&quot;&gt;&lt;span class=&quot;line-numbers&quot;&gt;   1 &lt;/span&gt; &lt;span class=&quot;Storage&quot;&gt;var&lt;/span&gt; group &lt;span class=&quot;Keyword&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;Keyword&quot;&gt;new&lt;/span&gt; &lt;span class=&quot;JEntityNameType&quot;&gt;FX.Score&lt;/span&gt;(&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;'&lt;/span&gt;group1&lt;span class=&quot;String&quot;&gt;'&lt;/span&gt;&lt;/span&gt;);
&lt;span class=&quot;line-numbers&quot;&gt;   2 &lt;/span&gt; group.&lt;span class=&quot;SupportFunction&quot;&gt;add&lt;/span&gt;(fx1)
&lt;span class=&quot;line-numbers&quot;&gt;   3 &lt;/span&gt;      .&lt;span class=&quot;SupportFunction&quot;&gt;add&lt;/span&gt;(fx2, {delay: &lt;span class=&quot;Keyword&quot;&gt;-&lt;/span&gt;&lt;span class=&quot;Constant&quot;&gt;1000&lt;/span&gt;, position: &lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;'&lt;/span&gt;last&lt;span class=&quot;String&quot;&gt;'&lt;/span&gt;&lt;/span&gt;})
&lt;span class=&quot;line-numbers&quot;&gt;   4 &lt;/span&gt;      .&lt;span class=&quot;SupportFunction&quot;&gt;add&lt;/span&gt;(fx3, {delay: &lt;span class=&quot;Keyword&quot;&gt;-&lt;/span&gt;&lt;span class=&quot;Constant&quot;&gt;1000&lt;/span&gt;, position: &lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;'&lt;/span&gt;first&lt;span class=&quot;String&quot;&gt;'&lt;/span&gt;&lt;/span&gt;})
&lt;span class=&quot;line-numbers&quot;&gt;   5 &lt;/span&gt;      .&lt;span class=&quot;SupportFunction&quot;&gt;add&lt;/span&gt;(fx4, {delay: &lt;span class=&quot;Constant&quot;&gt;1000&lt;/span&gt;, after: &lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;'&lt;/span&gt;fx2&lt;span class=&quot;String&quot;&gt;'&lt;/span&gt;&lt;/span&gt;});
&lt;/pre&gt;

	&lt;h2&gt;Samples&lt;/h2&gt;


	&lt;p&gt;Some samples are included with the distrib on github.
Check out &lt;a href=&quot;http://www.xilinus.com/protofx/examples/basketball.html&quot;&gt;this fun example&lt;/a&gt;. 
Play with the play/stop and reverse checkbox. click on it when animation is running!!&lt;/p&gt;


	&lt;h2&gt;Get it!&lt;/h2&gt;


	&lt;p&gt;ProtoFX is under &lt;span class=&quot;caps&quot;&gt;MIT&lt;/span&gt; Licence like Prototype.
You can get it from github here: &lt;a href=&quot;http://github.com/xilinus/protofx/tree/master&quot;&gt;http://github.com/xilinus/protofx/tree/master&lt;/a&gt;&lt;/p&gt;


	&lt;p&gt;Documentation is generated with &lt;a href=&quot;http://www.pdoc.org&quot;&gt;pdoc&lt;/a&gt; from Tobie Langel. Just run: rake doc to generate it locally.&lt;/p&gt;


	&lt;p&gt;Unit tests are coming soon :)&lt;/p&gt;
          </content>  </entry>
  <entry xml:base="http://blog.xilinus.com/">
    <author>
      <name>seb</name>
    </author>
    <id>tag:blog.xilinus.com,2008-12-13:311</id>
    <published>2008-12-13T12:37:00Z</published>
    <updated>2008-12-13T13:48:26Z</updated>
    <category term="English"/>
    <link href="http://blog.xilinus.com/2008/12/13/mapeed-is-now-in-public-beta" rel="alternate" type="text/html"/>
    <title>Mapeed is now in public beta</title>
<content type="html">
            &lt;p&gt;After months of development, &lt;a href=&quot;http://www.mapeed.com&quot;&gt;Mapeed&lt;/a&gt; is now open in public beta.&lt;/p&gt;


	&lt;p&gt;We are very happy to deliver this first version to anyone who needs to display huge amount of markers on a Google Map.&lt;/p&gt;


	&lt;p&gt;Mapeed is a server-side clustering plugin for Google Maps.  Cluster are created depending on zoom level and location. Use our server &lt;span class=&quot;caps&quot;&gt;API&lt;/span&gt; to synchronize your data to our server (only latitude and longitude) and use our Javascript &lt;span class=&quot;caps&quot;&gt;API&lt;/span&gt; to manage markers/clusters.&lt;/p&gt;


	&lt;p&gt;The big picture is
- Google map delivers images
- Mapeed delivers markers in a efficient way.&lt;/p&gt;


	&lt;p&gt;To show a way to use Mapeed, we have created &lt;a href=&quot;http://www.crunchvision.com&quot;&gt;CrunchVision&lt;/a&gt; a mashup of &lt;a href=&quot;http://crunchbase.com&quot;&gt;CrunchBase&lt;/a&gt;, &lt;a href=&quot;http://maps.google.com&quot;&gt;Google Map&lt;/a&gt; and  &lt;a href=&quot;http://www.mapeed.com&quot;&gt;Mapeed&lt;/a&gt;.&lt;/p&gt;


	&lt;p&gt;This mash-up has even been cited in &lt;a href=&quot;http://www.techcrunch.com/2008/12/01/crunchvision-is-crunchbase-on-a-map-are-you-on-it&quot;&gt;techcrunch.com&lt;/a&gt; !!&lt;/p&gt;


	&lt;p&gt;This version works only for google maps but if you need to use it on other mapping systems, contact us.&lt;/p&gt;
          </content>  </entry>
  <entry xml:base="http://blog.xilinus.com/">
    <author>
      <name>seb</name>
    </author>
    <id>tag:blog.xilinus.com,2008-05-27:301</id>
    <published>2008-05-27T07:38:00Z</published>
    <updated>2008-05-29T09:13:45Z</updated>
    <category term="English"/>
    <link href="http://blog.xilinus.com/2008/5/27/funny-comic" rel="alternate" type="text/html"/>
    <title>Funny comic</title>
<content type="html">
            &lt;p&gt;I just saw this little comic on a blog, I really like it!
&lt;br /&gt;&lt;/p&gt;


&lt;p&gt;
&lt;img src=&quot;http://blog.xilinus.com/assets/2008/5/27/comic.jpg&quot; /&gt;
&lt;/p&gt;
&lt;br /&gt;
But this kids should learn ruby instead of C, it will be easier and shorter to write :). 
It could be something like this:
&lt;pre class=&quot;sunburst&quot;&gt;&lt;span class=&quot;line-numbers&quot;&gt;   1 &lt;/span&gt;  &lt;span class=&quot;Constant&quot;&gt;500&lt;/span&gt;.&lt;span class=&quot;Entity&quot;&gt;times&lt;/span&gt; { puts &lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;'&lt;/span&gt;I will not throw paper airplanes in class&lt;span class=&quot;String&quot;&gt;'&lt;/span&gt;&lt;/span&gt; }
&lt;/pre&gt;
          </content>  </entry>
  <entry xml:base="http://blog.xilinus.com/">
    <author>
      <name>seb</name>
    </author>
    <id>tag:blog.xilinus.com,2008-05-15:294</id>
    <published>2008-05-15T08:07:00Z</published>
    <updated>2008-05-15T08:07:13Z</updated>
    <category term="English"/>
    <link href="http://blog.xilinus.com/2008/5/15/first-railscamp-in-paris" rel="alternate" type="text/html"/>
    <title>First RailsCamp in Paris</title>
<content type="html">
            &lt;p&gt;I will be at the first &lt;a href=&quot;http://barcamp.org/RailsCampParis&quot;&gt;RailsCamps&lt;/a&gt; in Paris organized by Jean-François Tran and the &lt;a href=&quot;http://www.rubyfrance.org/&quot;&gt;French Ruby comunity&lt;/a&gt;.&lt;/p&gt;


	&lt;p&gt;This is a great event to meet people working with rails and to learn some great stuffs around Ruby frameworks.&lt;/p&gt;


	&lt;p&gt;I will do a session about google maps and rails. I will try to create a application from scratch!&lt;/p&gt;


	&lt;p&gt;And may be a talk about Merb and DataMapper.&lt;/p&gt;


	&lt;p&gt;See you there :)&lt;/p&gt;
          </content>  </entry>
  <entry xml:base="http://blog.xilinus.com/">
    <author>
      <name>seb</name>
    </author>
    <id>tag:blog.xilinus.com,2008-05-15:292</id>
    <published>2008-05-15T08:06:00Z</published>
    <updated>2008-05-15T08:06:51Z</updated>
    <category term="English"/>
    <link href="http://blog.xilinus.com/2008/5/15/new-design" rel="alternate" type="text/html"/>
    <title>New Design </title>
<content type="html">
            &lt;p&gt;Xilinus is changing, design too :)&lt;/p&gt;


	&lt;p&gt;Xilinus is now a company in web application development based on Ruby frameworks (Ruby On Rails, Merb).&lt;/p&gt;


	&lt;p&gt;This explains the new design, xilinus.com will be updated soon too.&lt;/p&gt;


	&lt;p&gt;If you have a project of web application feel free to  &lt;a href=&quot;mailto:contact@xilinus.com&quot;&gt;contact us&lt;/a&gt;&lt;/p&gt;
          </content>  </entry>
  <entry xml:base="http://blog.xilinus.com/">
    <author>
      <name>seb</name>
    </author>
    <id>tag:blog.xilinus.com,2008-02-22:281</id>
    <published>2008-02-22T14:53:00Z</published>
    <updated>2008-05-05T16:42:22Z</updated>
    <category term="English"/>
    <category term="Javascript"/>
    <category term="Prototype UI"/>
    <link href="http://blog.xilinus.com/2008/2/22/new-component-auto_complete-in-prototype-ui" rel="alternate" type="text/html"/>
    <title>New component (auto_complete) in prototype UI</title>
<content type="html">
            &lt;p&gt;I have added a new component in &lt;a href=&quot;http://www.prototype-ui.com&quot;&gt;Prototype UI&lt;/a&gt;  after having seeing this auto_complete from &lt;a href=&quot;http://www.interiders.com/2008/02/11/prototextboxlist-meets-autocompletion/&quot;&gt;InteRiders&lt;/a&gt;&lt;/p&gt;


	&lt;p&gt;First of all, I want to thanks those guys and also &lt;a href=&quot;http://devthought.com/textboxlist-meets-autocompletion/&quot;&gt;Guillermo Rauch&lt;/a&gt; for the first version based on mootools.&lt;/p&gt;


	&lt;p&gt;For a customer, I needed an component based on prototype butn with content set by Ajax request and with some other features. I decided to port this component in prototype UI.&lt;/p&gt;


The main advantage of  being part of Prototype UI is I can use some great functionnalities of this frame work without adding complicated code like:
	&lt;ul&gt;
	&lt;li&gt;Shadowing system for a better look and feel and better user experience. It does not look like a &#8220;flat&#8221; div under the input field&lt;/li&gt;
		&lt;li&gt;IFrameShim to avoid the bug of having select box over the completion&lt;/li&gt;
		&lt;li&gt;packr version&lt;/li&gt;
	&lt;/ul&gt;


	&lt;p&gt;The component is fully unobtrusive, all &lt;span class=&quot;caps&quot;&gt;HTML&lt;/span&gt; code needed for displaying completion is built by the script.
As always, I try to make component skinnable. You can see below a &#8220;facebook&#8221; style as the original version and a more Apple like look and feel.&lt;/p&gt;


	&lt;p&gt;&lt;small&gt;Facebook style&lt;/small&gt;&lt;br /&gt;
&lt;img src=&quot;http://blog.xilinus.com/assets/2008/2/22/Picture_6.png&quot; /&gt;&lt;br /&gt;
&lt;small&gt;Apple style&lt;/small&gt;&lt;br /&gt;
&lt;img src=&quot;http://blog.xilinus.com/assets/2008/2/22/Picture_7.png&quot; /&gt;
&lt;br /&gt;&lt;/p&gt;


	&lt;p&gt;It&#8217;s only available in trunk version right now but it will be included in the next release candidate planned for March.&lt;/p&gt;


	&lt;p&gt;If you really want to use it :), you can &lt;a href=&quot;http://prototype-ui.com/auto_complete.zip&quot;&gt;dowload a zip file&lt;/a&gt; with functionnal tests included.&lt;/p&gt;


	&lt;p&gt;I will add some features like serialization or a way to hand automatically hidden fields for an easier submit process. I have also to work on unit tests and documentation before the release.&lt;/p&gt;


	&lt;p&gt;If you want to try it, check those two functional tests: &lt;a href=&quot;http://prototype-ui.com/current/test/functional/auto_complete/test_auto_complete.html&quot;&gt;non ajax&lt;/a&gt; and &lt;a href=&quot;http://prototype-ui.com/current/test/functional/auto_complete/test_auto_complete_ajax.html&quot;&gt;ajax fill&lt;/a&gt;  (be aware that it&#8217;s faking an ajax request, some browser do not like it :)).&lt;/p&gt;


	&lt;p&gt;PS: I will be away from my computer for a week, so I won&#8217;t reply to any comments before March.&lt;/p&gt;
          </content>  </entry>
  <entry xml:base="http://blog.xilinus.com/">
    <author>
      <name>seb</name>
    </author>
    <id>tag:blog.xilinus.com,2008-02-06:278</id>
    <published>2008-02-06T20:02:00Z</published>
    <updated>2008-05-05T16:43:01Z</updated>
    <category term="English"/>
    <category term="Javascript"/>
    <link href="http://blog.xilinus.com/2008/2/6/first-release-candidate-of-prototype-ui" rel="alternate" type="text/html"/>
    <title>First Release Candidate of Prototype UI</title>
<content type="html">
            &lt;p&gt;I am very proud to announce First Release Candidate of &lt;a href=&quot;http://www.prototype-ui.com&quot;&gt;Prototype UI&lt;/a&gt;.&lt;/p&gt;


	&lt;p&gt;This release only includes Window and Carousel. In trunk version you will find also Context Menu and an experimental Dock.
Really soon, we will add Tooltips, Calendar (from Min), Accordion and more&lt;/p&gt;


	&lt;p&gt;So stay tuned :)&lt;/p&gt;
          </content>  </entry>
  <entry xml:base="http://blog.xilinus.com/">
    <author>
      <name>seb</name>
    </author>
    <id>tag:blog.xilinus.com,2008-01-30:276</id>
    <published>2008-01-30T16:28:00Z</published>
    <updated>2008-05-05T16:43:23Z</updated>
    <category term="English"/>
    <link href="http://blog.xilinus.com/2008/1/30/easy-error-display-on-rails-ajax-form" rel="alternate" type="text/html"/>
    <title>Easy error display on rails ajax form</title>
<content type="html">
            &lt;p&gt;I have never found a easy way to handle errors in rails with ajax form. Here is my implementation.&lt;/p&gt;


	&lt;p&gt;You have nothing to change in your view and in your controller, just few line of Javascript.&lt;/p&gt;


	&lt;p&gt;Here is how it works:&lt;/p&gt;


	&lt;h3&gt;The form&lt;/h3&gt;


Let&#8217;s imagine we have a contact form 3 required fields, name, email and message like this
&lt;pre class=&quot;sunburst&quot;&gt;&lt;span class=&quot;line-numbers&quot;&gt;   1 &lt;/span&gt; 
&lt;span class=&quot;line-numbers&quot;&gt;   2 &lt;/span&gt; &lt;span class=&quot;EmbeddedSourceBright&quot;&gt;&lt;span class=&quot;EmbeddedSourceBright&quot;&gt;&amp;lt;%&lt;/span&gt;&lt;span class=&quot;Keyword&quot;&gt;-&lt;/span&gt; form_remote_for &lt;span class=&quot;Variable&quot;&gt;&lt;span class=&quot;Variable&quot;&gt;@&lt;/span&gt;contact&lt;/span&gt;&lt;span class=&quot;EmbeddedSourceBright&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;Constant&quot;&gt;&lt;span class=&quot;Constant&quot;&gt;:&lt;/span&gt;html&lt;/span&gt; &lt;span class=&quot;EmbeddedSourceBright&quot;&gt;=&amp;gt;&lt;/span&gt; &lt;span class=&quot;EmbeddedSourceBright&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;Constant&quot;&gt;&lt;span class=&quot;Constant&quot;&gt;:&lt;/span&gt;class&lt;/span&gt; &lt;span class=&quot;EmbeddedSourceBright&quot;&gt;=&amp;gt;&lt;/span&gt; &lt;span class=&quot;Constant&quot;&gt;&lt;span class=&quot;Constant&quot;&gt;:&lt;/span&gt;contact&lt;/span&gt;&lt;span class=&quot;EmbeddedSourceBright&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;Constant&quot;&gt;&lt;span class=&quot;Constant&quot;&gt;:&lt;/span&gt;id&lt;/span&gt; &lt;span class=&quot;EmbeddedSourceBright&quot;&gt;=&amp;gt;&lt;/span&gt; &lt;span class=&quot;Constant&quot;&gt;&lt;span class=&quot;Constant&quot;&gt;:&lt;/span&gt;contact_form&lt;/span&gt;&lt;span class=&quot;EmbeddedSourceBright&quot;&gt;}&lt;/span&gt; &lt;span class=&quot;Keyword&quot;&gt;do &lt;/span&gt;&lt;span class=&quot;EmbeddedSourceBright&quot;&gt;|&lt;/span&gt;&lt;span class=&quot;Variable&quot;&gt;f&lt;/span&gt;&lt;span class=&quot;EmbeddedSourceBright&quot;&gt;|&lt;/span&gt; &lt;span class=&quot;EmbeddedSourceBright&quot;&gt;-%&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;   3 &lt;/span&gt;   &lt;span class=&quot;MetaTagInline&quot;&gt;&lt;span class=&quot;MetaTagInline&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;MetaTagInline&quot;&gt;label&lt;/span&gt; &lt;span class=&quot;MetaTagInline&quot;&gt;for&lt;/span&gt;=&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;name&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;MetaTagInline&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;Name *&lt;span class=&quot;MetaTagInline&quot;&gt;&lt;span class=&quot;MetaTagInline&quot;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&quot;MetaTagInline&quot;&gt;label&lt;/span&gt;&lt;span class=&quot;MetaTagInline&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;   4 &lt;/span&gt;   &lt;span class=&quot;EmbeddedSourceBright&quot;&gt;&lt;span class=&quot;EmbeddedSourceBright&quot;&gt;&amp;lt;%=&lt;/span&gt; f&lt;span class=&quot;EmbeddedSourceBright&quot;&gt;&lt;span class=&quot;EmbeddedSourceBright&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;Entity&quot;&gt;text_field&lt;/span&gt;&lt;/span&gt; &lt;span class=&quot;Constant&quot;&gt;&lt;span class=&quot;Constant&quot;&gt;:&lt;/span&gt;name&lt;/span&gt;&lt;span class=&quot;EmbeddedSourceBright&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;Constant&quot;&gt;&lt;span class=&quot;Constant&quot;&gt;:&lt;/span&gt;class&lt;/span&gt; &lt;span class=&quot;EmbeddedSourceBright&quot;&gt;=&amp;gt;&lt;/span&gt; &lt;span class=&quot;Constant&quot;&gt;&lt;span class=&quot;Constant&quot;&gt;:&lt;/span&gt;text&lt;/span&gt; &lt;span class=&quot;EmbeddedSourceBright&quot;&gt;%&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;   5 &lt;/span&gt;   &lt;span class=&quot;MetaTagInline&quot;&gt;&lt;span class=&quot;MetaTagInline&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;MetaTagInline&quot;&gt;br&lt;/span&gt;/&lt;span class=&quot;MetaTagInline&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;   6 &lt;/span&gt;   
&lt;span class=&quot;line-numbers&quot;&gt;   7 &lt;/span&gt;   &lt;span class=&quot;MetaTagInline&quot;&gt;&lt;span class=&quot;MetaTagInline&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;MetaTagInline&quot;&gt;label&lt;/span&gt; &lt;span class=&quot;MetaTagInline&quot;&gt;for&lt;/span&gt;=&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;email&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;MetaTagInline&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;Email *&lt;span class=&quot;MetaTagInline&quot;&gt;&lt;span class=&quot;MetaTagInline&quot;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&quot;MetaTagInline&quot;&gt;label&lt;/span&gt;&lt;span class=&quot;MetaTagInline&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;   8 &lt;/span&gt;   &lt;span class=&quot;EmbeddedSourceBright&quot;&gt;&lt;span class=&quot;EmbeddedSourceBright&quot;&gt;&amp;lt;%=&lt;/span&gt; f&lt;span class=&quot;EmbeddedSourceBright&quot;&gt;&lt;span class=&quot;EmbeddedSourceBright&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;Entity&quot;&gt;text_field&lt;/span&gt;&lt;/span&gt; &lt;span class=&quot;Constant&quot;&gt;&lt;span class=&quot;Constant&quot;&gt;:&lt;/span&gt;email&lt;/span&gt;&lt;span class=&quot;EmbeddedSourceBright&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;Constant&quot;&gt;&lt;span class=&quot;Constant&quot;&gt;:&lt;/span&gt;class&lt;/span&gt; &lt;span class=&quot;EmbeddedSourceBright&quot;&gt;=&amp;gt;&lt;/span&gt; &lt;span class=&quot;Constant&quot;&gt;&lt;span class=&quot;Constant&quot;&gt;:&lt;/span&gt;text&lt;/span&gt; &lt;span class=&quot;EmbeddedSourceBright&quot;&gt;%&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;   9 &lt;/span&gt;   &lt;span class=&quot;MetaTagInline&quot;&gt;&lt;span class=&quot;MetaTagInline&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;MetaTagInline&quot;&gt;br&lt;/span&gt;/&lt;span class=&quot;MetaTagInline&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;  10 &lt;/span&gt; 
&lt;span class=&quot;line-numbers&quot;&gt;  11 &lt;/span&gt;   &lt;span class=&quot;MetaTagInline&quot;&gt;&lt;span class=&quot;MetaTagInline&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;MetaTagInline&quot;&gt;label&lt;/span&gt; &lt;span class=&quot;MetaTagInline&quot;&gt;for&lt;/span&gt;=&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;message&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;MetaTagInline&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;Message *&lt;span class=&quot;MetaTagInline&quot;&gt;&lt;span class=&quot;MetaTagInline&quot;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&quot;MetaTagInline&quot;&gt;label&lt;/span&gt;&lt;span class=&quot;MetaTagInline&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;  12 &lt;/span&gt;   &lt;span class=&quot;EmbeddedSourceBright&quot;&gt;&lt;span class=&quot;EmbeddedSourceBright&quot;&gt;&amp;lt;%=&lt;/span&gt; f&lt;span class=&quot;EmbeddedSourceBright&quot;&gt;&lt;span class=&quot;EmbeddedSourceBright&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;Entity&quot;&gt;text_area&lt;/span&gt;&lt;/span&gt; &lt;span class=&quot;Constant&quot;&gt;&lt;span class=&quot;Constant&quot;&gt;:&lt;/span&gt;message&lt;/span&gt; &lt;span class=&quot;EmbeddedSourceBright&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;Constant&quot;&gt;&lt;span class=&quot;Constant&quot;&gt;:&lt;/span&gt;class&lt;/span&gt; &lt;span class=&quot;EmbeddedSourceBright&quot;&gt;=&amp;gt;&lt;/span&gt; &lt;span class=&quot;Constant&quot;&gt;&lt;span class=&quot;Constant&quot;&gt;:&lt;/span&gt;text&lt;/span&gt;&lt;span class=&quot;EmbeddedSourceBright&quot;&gt;%&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;  13 &lt;/span&gt;   &lt;span class=&quot;MetaTagInline&quot;&gt;&lt;span class=&quot;MetaTagInline&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;MetaTagInline&quot;&gt;br&lt;/span&gt;/&lt;span class=&quot;MetaTagInline&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;   
&lt;span class=&quot;line-numbers&quot;&gt;  14 &lt;/span&gt; 
&lt;span class=&quot;line-numbers&quot;&gt;  15 &lt;/span&gt;   &lt;span class=&quot;MetaTagInline&quot;&gt;&lt;span class=&quot;MetaTagInline&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;MetaTagInline&quot;&gt;label&lt;/span&gt; &lt;span class=&quot;MetaTagInline&quot;&gt;for&lt;/span&gt;=&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;submit&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;MetaTagInline&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;Constant&quot;&gt;&lt;span class=&quot;Constant&quot;&gt;&amp;amp;&lt;/span&gt;nbsp&lt;span class=&quot;Constant&quot;&gt;;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;MetaTagInline&quot;&gt;&lt;span class=&quot;MetaTagInline&quot;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&quot;MetaTagInline&quot;&gt;label&lt;/span&gt;&lt;span class=&quot;MetaTagInline&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;  16 &lt;/span&gt;   &lt;span class=&quot;EmbeddedSourceBright&quot;&gt;&lt;span class=&quot;EmbeddedSourceBright&quot;&gt;&amp;lt;%=&lt;/span&gt; submit_tag &lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;Submit&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt; &lt;span class=&quot;EmbeddedSourceBright&quot;&gt;%&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;  17 &lt;/span&gt;   &lt;span class=&quot;MetaTagInline&quot;&gt;&lt;span class=&quot;MetaTagInline&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;MetaTagInline&quot;&gt;br&lt;/span&gt;/&lt;span class=&quot;MetaTagInline&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;        
&lt;span class=&quot;line-numbers&quot;&gt;  18 &lt;/span&gt; &lt;span class=&quot;EmbeddedSourceBright&quot;&gt;&lt;span class=&quot;EmbeddedSourceBright&quot;&gt;&amp;lt;%&lt;/span&gt;&lt;span class=&quot;Keyword&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;Keyword&quot;&gt;end&lt;/span&gt; &lt;span class=&quot;EmbeddedSourceBright&quot;&gt;-%&amp;gt;&lt;/span&gt;&lt;/span&gt;      
&lt;/pre&gt;

	&lt;p&gt;We use form_remote_for for ajax post and we set an id to the form for later use.
It should look like this&lt;/p&gt;


	&lt;p&gt;&lt;img src=&quot;http://blog.xilinus.com/assets/2008/1/30/Picture_11.png&quot;&gt;&lt;/p&gt;


	&lt;h3&gt;The model&lt;/h3&gt;


Contact model just have some validations
&lt;pre class=&quot;sunburst&quot;&gt;&lt;span class=&quot;line-numbers&quot;&gt;   1 &lt;/span&gt; 
&lt;span class=&quot;line-numbers&quot;&gt;   2 &lt;/span&gt; &lt;span class=&quot;Keyword&quot;&gt;class&lt;/span&gt; &lt;span class=&quot;JEntityNameType&quot;&gt;Contact&lt;span class=&quot;EntityInheritedClass&quot;&gt; &lt;span class=&quot;EntityInheritedClass&quot;&gt;&amp;lt;&lt;/span&gt; ActiveRecord::Base&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;   3 &lt;/span&gt;   validates_presence_of &lt;span class=&quot;Constant&quot;&gt;&lt;span class=&quot;Constant&quot;&gt;:&lt;/span&gt;name&lt;/span&gt;, &lt;span class=&quot;Constant&quot;&gt;&lt;span class=&quot;Constant&quot;&gt;:&lt;/span&gt;email&lt;/span&gt;, &lt;span class=&quot;Constant&quot;&gt;&lt;span class=&quot;Constant&quot;&gt;:&lt;/span&gt;message&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;   4 &lt;/span&gt; &lt;span class=&quot;Keyword&quot;&gt;end&lt;/span&gt;
&lt;/pre&gt;

	&lt;h3&gt;The controller&lt;/h3&gt;


The controller is a classic &lt;span class=&quot;caps&quot;&gt;REST&lt;/span&gt; action create. In this example I just handle Ajax post but you can add code for &lt;span class=&quot;caps&quot;&gt;HTML&lt;/span&gt; or &lt;span class=&quot;caps&quot;&gt;XML&lt;/span&gt; request.
The only thing we need to do is to return an &lt;span class=&quot;caps&quot;&gt;JSON&lt;/span&gt; response.
&lt;pre class=&quot;sunburst&quot;&gt;&lt;span class=&quot;line-numbers&quot;&gt;   1 &lt;/span&gt; 
&lt;span class=&quot;line-numbers&quot;&gt;   2 &lt;/span&gt;   &lt;span class=&quot;Keyword&quot;&gt;def&lt;/span&gt; &lt;span class=&quot;Entity&quot;&gt;create&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;   3 &lt;/span&gt;     &lt;span class=&quot;Variable&quot;&gt;&lt;span class=&quot;Variable&quot;&gt;@&lt;/span&gt;contact&lt;/span&gt; &lt;span class=&quot;Keyword&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;Support&quot;&gt;Contact&lt;/span&gt;.&lt;span class=&quot;Entity&quot;&gt;new&lt;/span&gt;(params[&lt;span class=&quot;Constant&quot;&gt;&lt;span class=&quot;Constant&quot;&gt;:&lt;/span&gt;contact&lt;/span&gt;])
&lt;span class=&quot;line-numbers&quot;&gt;   4 &lt;/span&gt;     respond_to &lt;span class=&quot;Keyword&quot;&gt;do &lt;/span&gt;|&lt;span class=&quot;Variable&quot;&gt;format&lt;/span&gt;|
&lt;span class=&quot;line-numbers&quot;&gt;   5 &lt;/span&gt;       format.&lt;span class=&quot;Entity&quot;&gt;js&lt;/span&gt; {
&lt;span class=&quot;line-numbers&quot;&gt;   6 &lt;/span&gt;         &lt;span class=&quot;Keyword&quot;&gt;if&lt;/span&gt; &lt;span class=&quot;Variable&quot;&gt;&lt;span class=&quot;Variable&quot;&gt;@&lt;/span&gt;contact&lt;/span&gt;.&lt;span class=&quot;Entity&quot;&gt;save&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;   7 &lt;/span&gt;           render &lt;span class=&quot;Constant&quot;&gt;&lt;span class=&quot;Constant&quot;&gt;:&lt;/span&gt;json&lt;/span&gt; =&amp;gt; {&lt;span class=&quot;Constant&quot;&gt;&lt;span class=&quot;Constant&quot;&gt;:&lt;/span&gt;object&lt;/span&gt; =&amp;gt; &lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;contact&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;, &lt;span class=&quot;Constant&quot;&gt;&lt;span class=&quot;Constant&quot;&gt;:&lt;/span&gt;success&lt;/span&gt; =&amp;gt; &lt;span class=&quot;Constant&quot;&gt;true&lt;/span&gt;}
&lt;span class=&quot;line-numbers&quot;&gt;   8 &lt;/span&gt;         &lt;span class=&quot;Keyword&quot;&gt;else&lt;/span&gt;    
&lt;span class=&quot;line-numbers&quot;&gt;   9 &lt;/span&gt;           render &lt;span class=&quot;Constant&quot;&gt;&lt;span class=&quot;Constant&quot;&gt;:&lt;/span&gt;json&lt;/span&gt; =&amp;gt; {&lt;span class=&quot;Constant&quot;&gt;&lt;span class=&quot;Constant&quot;&gt;:&lt;/span&gt;object&lt;/span&gt; =&amp;gt; &lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;contact&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;, &lt;span class=&quot;Constant&quot;&gt;&lt;span class=&quot;Constant&quot;&gt;:&lt;/span&gt;success&lt;/span&gt; =&amp;gt; &lt;span class=&quot;Constant&quot;&gt;false&lt;/span&gt;, &lt;span class=&quot;Constant&quot;&gt;&lt;span class=&quot;Constant&quot;&gt;:&lt;/span&gt;errors&lt;/span&gt; =&amp;gt; &lt;span class=&quot;Variable&quot;&gt;&lt;span class=&quot;Variable&quot;&gt;@&lt;/span&gt;contact&lt;/span&gt;.&lt;span class=&quot;Entity&quot;&gt;errors&lt;/span&gt;}
&lt;span class=&quot;line-numbers&quot;&gt;  10 &lt;/span&gt;         &lt;span class=&quot;Keyword&quot;&gt;end&lt;/span&gt;    
&lt;span class=&quot;line-numbers&quot;&gt;  11 &lt;/span&gt;       }
&lt;span class=&quot;line-numbers&quot;&gt;  12 &lt;/span&gt;     &lt;span class=&quot;Keyword&quot;&gt;end&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;  13 &lt;/span&gt;   &lt;span class=&quot;Keyword&quot;&gt;end&lt;/span&gt;
&lt;/pre&gt;

	&lt;h3&gt;Javascript&lt;/h3&gt;


	&lt;p&gt;So how our code will handle this &lt;span class=&quot;caps&quot;&gt;JSON&lt;/span&gt; response. The view is a classic remote_form, the model just have validation and our controller returns a &lt;span class=&quot;caps&quot;&gt;JSON&lt;/span&gt; string.
It&#8217;s pretty easy.&lt;/p&gt;


With Prototype, you can register function on Ajax callback, here comes the magic:
&lt;pre class=&quot;sunburst&quot;&gt;&lt;span class=&quot;line-numbers&quot;&gt;   1 &lt;/span&gt; 
&lt;span class=&quot;line-numbers&quot;&gt;   2 &lt;/span&gt; Ajax.Responders.register({
&lt;span class=&quot;line-numbers&quot;&gt;   3 &lt;/span&gt;   &lt;span class=&quot;Entity&quot;&gt;onComplete&lt;/span&gt;: &lt;span class=&quot;Storage&quot;&gt;function&lt;/span&gt;(&lt;span class=&quot;Variable&quot;&gt;responder, request&lt;/span&gt;){  
&lt;span class=&quot;line-numbers&quot;&gt;   4 &lt;/span&gt;     &lt;span class=&quot;Storage&quot;&gt;var&lt;/span&gt; response &lt;span class=&quot;Keyword&quot;&gt;=&lt;/span&gt; (request.&lt;span class=&quot;SupportConstant&quot;&gt;responseText&lt;/span&gt;.evalJSON(&lt;span class=&quot;Constant&quot;&gt;true&lt;/span&gt;)); 
&lt;span class=&quot;line-numbers&quot;&gt;   5 &lt;/span&gt;     &lt;span class=&quot;Keyword&quot;&gt;if&lt;/span&gt; (response.&lt;span class=&quot;SupportConstant&quot;&gt;object&lt;/span&gt;)  {
&lt;span class=&quot;line-numbers&quot;&gt;   6 &lt;/span&gt;       &lt;span class=&quot;Comment&quot;&gt;&lt;span class=&quot;Comment&quot;&gt;//&lt;/span&gt; Remove old erroes&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;   7 &lt;/span&gt;       &lt;span class=&quot;Keyword&quot;&gt;$&lt;/span&gt;(response.&lt;span class=&quot;SupportConstant&quot;&gt;object&lt;/span&gt; &lt;span class=&quot;Keyword&quot;&gt;+&lt;/span&gt; &lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;_form&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;).&lt;span class=&quot;SupportFunction&quot;&gt;select&lt;/span&gt;(&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;.error&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;).invoke(&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;removeClassName&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;, &lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;error&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;);
&lt;span class=&quot;line-numbers&quot;&gt;   8 &lt;/span&gt;       &lt;span class=&quot;Keyword&quot;&gt;$&lt;/span&gt;(response.&lt;span class=&quot;SupportConstant&quot;&gt;object&lt;/span&gt; &lt;span class=&quot;Keyword&quot;&gt;+&lt;/span&gt; &lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;_form&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;).&lt;span class=&quot;SupportFunction&quot;&gt;select&lt;/span&gt;(&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;.error_message&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;).invoke(&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;remove&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;);
&lt;span class=&quot;line-numbers&quot;&gt;   9 &lt;/span&gt; 
&lt;span class=&quot;line-numbers&quot;&gt;  10 &lt;/span&gt;       &lt;span class=&quot;Comment&quot;&gt;&lt;span class=&quot;Comment&quot;&gt;//&lt;/span&gt; Success: clear all input with text&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;  11 &lt;/span&gt;       &lt;span class=&quot;Keyword&quot;&gt;if&lt;/span&gt; (response.success) {
&lt;span class=&quot;line-numbers&quot;&gt;  12 &lt;/span&gt;         &lt;span class=&quot;Storage&quot;&gt;var&lt;/span&gt; form &lt;span class=&quot;Keyword&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;Keyword&quot;&gt;$&lt;/span&gt;(response.&lt;span class=&quot;SupportConstant&quot;&gt;object&lt;/span&gt; &lt;span class=&quot;Keyword&quot;&gt;+&lt;/span&gt; &lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;_form&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;);
&lt;span class=&quot;line-numbers&quot;&gt;  13 &lt;/span&gt;         form.&lt;span class=&quot;SupportFunction&quot;&gt;select&lt;/span&gt;(&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;.text&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;).each(&lt;span class=&quot;Storage&quot;&gt;function&lt;/span&gt;(element) {element.&lt;span class=&quot;SupportConstant&quot;&gt;value&lt;/span&gt; &lt;span class=&quot;Keyword&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;});
&lt;span class=&quot;line-numbers&quot;&gt;  14 &lt;/span&gt;       }
&lt;span class=&quot;line-numbers&quot;&gt;  15 &lt;/span&gt;       &lt;span class=&quot;Comment&quot;&gt;&lt;span class=&quot;Comment&quot;&gt;//&lt;/span&gt; Else add error by creating a div with error message&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;  16 &lt;/span&gt;       &lt;span class=&quot;Keyword&quot;&gt;else&lt;/span&gt; {
&lt;span class=&quot;line-numbers&quot;&gt;  17 &lt;/span&gt;         response.errors.each(&lt;span class=&quot;Storage&quot;&gt;function&lt;/span&gt;(error) {     
&lt;span class=&quot;line-numbers&quot;&gt;  18 &lt;/span&gt;           &lt;span class=&quot;Storage&quot;&gt;var&lt;/span&gt; element &lt;span class=&quot;Keyword&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;Keyword&quot;&gt;$&lt;/span&gt;(response.&lt;span class=&quot;SupportConstant&quot;&gt;object&lt;/span&gt; &lt;span class=&quot;Keyword&quot;&gt;+&lt;/span&gt; &lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;_&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt; &lt;span class=&quot;Keyword&quot;&gt;+&lt;/span&gt; error[&lt;span class=&quot;Constant&quot;&gt;0&lt;/span&gt;]);
&lt;span class=&quot;line-numbers&quot;&gt;  19 &lt;/span&gt;           &lt;span class=&quot;Keyword&quot;&gt;if&lt;/span&gt; (element) {
&lt;span class=&quot;line-numbers&quot;&gt;  20 &lt;/span&gt;             element.addClassName(&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;error&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;);
&lt;span class=&quot;line-numbers&quot;&gt;  21 &lt;/span&gt;             element.insert({after: &lt;span class=&quot;Keyword&quot;&gt;new&lt;/span&gt; &lt;span class=&quot;JEntityNameType&quot;&gt;Element&lt;/span&gt;(&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;div&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;, {className: &lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;error_message&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;}).update(error[&lt;span class=&quot;Constant&quot;&gt;1&lt;/span&gt;])});
&lt;span class=&quot;line-numbers&quot;&gt;  22 &lt;/span&gt;           }
&lt;span class=&quot;line-numbers&quot;&gt;  23 &lt;/span&gt;         })
&lt;span class=&quot;line-numbers&quot;&gt;  24 &lt;/span&gt;       }
&lt;span class=&quot;line-numbers&quot;&gt;  25 &lt;/span&gt;     }
&lt;span class=&quot;line-numbers&quot;&gt;  26 &lt;/span&gt;   }
&lt;span class=&quot;line-numbers&quot;&gt;  27 &lt;/span&gt; });       
&lt;/pre&gt;
The result will be like this:

	&lt;p&gt;&lt;img src=&quot;http://blog.xilinus.com/assets/2008/1/30/Picture_12.png&quot; /&gt;&lt;/p&gt;


	&lt;h3&gt;Explanation&lt;/h3&gt;


	&lt;p&gt;If fact everything is &lt;span class=&quot;caps&quot;&gt;JSON&lt;/span&gt; data, it contains object name, and errors.&lt;/p&gt;


	&lt;p&gt;The JS just create divs after any field with error with error message and add an error class to the input. 
You just need to set some &lt;span class=&quot;caps&quot;&gt;CSS&lt;/span&gt; attributes.&lt;/p&gt;
          </content>  </entry>
  <entry xml:base="http://blog.xilinus.com/">
    <author>
      <name>seb</name>
    </author>
    <id>tag:blog.xilinus.com,2007-11-04:247</id>
    <published>2007-11-04T15:28:00Z</published>
    <updated>2008-05-05T16:43:46Z</updated>
    <category term="English"/>
    <category term="Javascript"/>
    <category term="javascript"/>
    <category term="prototype 1.6"/>
    <link href="http://blog.xilinus.com/2007/11/4/prototype-ui-beta-version-pwc-reloaded" rel="alternate" type="text/html"/>
    <title>Prototype UI beta version (PWC reloaded)</title>
<content type="html">
            &lt;p&gt;I am very happy and proud to announce &lt;a href=&quot;http://www.prototype-ui.com&quot;&gt;prototype UI&lt;/a&gt; is officially open today.&lt;/p&gt;


	&lt;p&gt;At the beginning of the project, it was only a full rewrite of &lt;a href=&quot;http://prototype-window.xilinus.com/&quot;&gt;Prototype Window&lt;/a&gt; but it became quickly a UI library based on &lt;a href=&quot;http://prototypejs.org/&quot;&gt;Prototype 1.6&lt;/a&gt; and &lt;a href=&quot;http://script.aculo.us/&quot;&gt;script.aculo.us 1.8&lt;/a&gt; to include all my previous components like &lt;a href=&quot;http://prototype-carousel.xilinus.com/&quot;&gt;Prototype Carousel&lt;/a&gt; ....&lt;/p&gt;


	&lt;p&gt;This library is developed by &lt;a href=&quot;http://i.gotfresh.info/&quot;&gt;Samuel Lebeau&lt;/a&gt; and myself. Sam worked hard on the core classes and the object design. It&#8217;s also done with help of  &lt;a href=&quot;http://thinkweb2.com/projects/prototype/&quot; title=&quot;kangax&quot;&gt;Juriy Zaytsev&lt;/a&gt; and &lt;a href=&quot;http://www.webalys.com/&quot;&gt;Vincent Le Moign&lt;/a&gt; for the design.&lt;/p&gt;


	&lt;p&gt;And I want to thank &lt;a href=&quot;http://www.mila76.it/&quot;&gt;Emanuel &#8216;Mila76&#8217;&lt;/a&gt; for his help on IE (BIG &lt;span class=&quot;caps&quot;&gt;HELP&lt;/span&gt;) and for his div version of &lt;span class=&quot;caps&quot;&gt;PWC&lt;/span&gt; (the new window system is based on it).&lt;/p&gt;


	&lt;p&gt;This version is only for developer and early adopters. You can only download it with subversion. The final release will be done when prototype 1.6 will be stable and of course when prototype UI too :).&lt;/p&gt;


	&lt;p&gt;You will be able to download a JS per component, a JS file with the full library and a build page will allow you to create your own JS file with UI components you need.&lt;/p&gt;


	&lt;p&gt;This goal is to build to best free UI library (under &lt;span class=&quot;caps&quot;&gt;MIT&lt;/span&gt; licence) based on Prototype.&lt;/p&gt;


In the current version you have
	&lt;ul&gt;
	&lt;li&gt;window
	&lt;ul&gt;
	&lt;li&gt;skinnable&lt;/li&gt;
		&lt;li&gt;shadowing system independent from window and skinnable&lt;/li&gt;
		&lt;li&gt;div based&lt;/li&gt;
		&lt;li&gt;resizable from all borders and corners&lt;/li&gt;
		&lt;li&gt;custom buttons&lt;/li&gt;
		&lt;li&gt;Dialogs (like it&#8217;s done in &lt;span class=&quot;caps&quot;&gt;PWC&lt;/span&gt;) are not yet implemented but will be done soon&lt;/li&gt;
	&lt;/ul&gt;&lt;/li&gt;
	&lt;/ul&gt;


	&lt;ul&gt;
	&lt;li&gt;carousel: only &lt;span class=&quot;caps&quot;&gt;HTML&lt;/span&gt; content (no Ajax content)&lt;/li&gt;
		&lt;li&gt;dock (experimental)&lt;/li&gt;
		&lt;li&gt;shadow: a simple class to add shadow on any element with a absolute position.&lt;/li&gt;
	&lt;/ul&gt;


	&lt;p&gt;Stay tuned ;) and long life to prototype UI.&lt;/p&gt;


	&lt;p&gt;Here is a &lt;a href=&quot;http://blog.xilinus.com/prototype-ui/test/functional/window/test_expose.html&quot;&gt;sample test&lt;/a&gt; to see the new window system (from functional tests included in the distrib)&lt;/p&gt;


	&lt;p&gt;PS: Any feedback is really appreciated (bugs, documentation, patches, &lt;span class=&quot;caps&quot;&gt;API&lt;/span&gt; &#8230;)&lt;/p&gt;
          </content>  </entry>
  <entry xml:base="http://blog.xilinus.com/">
    <author>
      <name>seb</name>
    </author>
    <id>tag:blog.xilinus.com,2007-10-03:208</id>
    <published>2007-10-03T20:07:00Z</published>
    <updated>2008-05-05T16:44:10Z</updated>
    <category term="English"/>
    <category term="Javascript"/>
    <category term="layout"/>
    <category term="prototype 1.6"/>
    <link href="http://blog.xilinus.com/2007/10/3/simple-layout-manager-with-prototype-1-6" rel="alternate" type="text/html"/>
    <title>Simple Layout Manager with Prototype 1.6</title>
<content type="html">
            &lt;p&gt;Aaron (Aaron @ ennerchi)  ask me to develop a simple layout manager for a web application. First of all, I want to thanks him for accepting to release this layout manager in open source under &lt;span class=&quot;caps&quot;&gt;MIT&lt;/span&gt;-license.&lt;/p&gt;


	&lt;p&gt;This class is inspired by  &lt;a href=&quot;http://www.ruzee.com/blog/ruzeelayoutmanager/&quot;&gt;&lt;span class=&quot;caps&quot;&gt;RUZEE&lt;/span&gt;.LayoutManager&lt;/a&gt; but based on &lt;a href=&quot;http://prototypejs.org/2007/8/15/prototype-1-6-0-release-candidate&quot;&gt;prototype 1.6&lt;/a&gt;. &lt;span class=&quot;caps&quot;&gt;RUZEE&lt;/span&gt; version was to slow on complex layout.&lt;/p&gt;


	&lt;p&gt;It&#8217;s an unobtrusive script based on &lt;span class=&quot;caps&quot;&gt;CSS&lt;/span&gt; classes. This picture shows what &lt;span class=&quot;caps&quot;&gt;CSS&lt;/span&gt; class to use.&lt;/p&gt;


	&lt;p&gt;&lt;img src=&quot;http://blog.xilinus.com/assets/2007/9/30/layout2&quot; /&gt;&lt;br /&gt;&lt;/p&gt;


	&lt;p&gt;Inside a &lt;em&gt;lm_container&lt;/em&gt; you can add:&lt;/p&gt;


	&lt;ul&gt;
	&lt;li&gt;&lt;em&gt;lm_top&lt;/em&gt; / &lt;em&gt;lm_bottom&lt;/em&gt; for top/bottom rows with fixed height and resizable width, you can add as many rows as you want,&lt;/li&gt;
	&lt;/ul&gt;


	&lt;ul&gt;
	&lt;li&gt;&lt;em&gt;lm_left&lt;/em&gt; / &lt;em&gt;lm_right&lt;/em&gt; for left/right columns with fixed width and resizable height, you can add as many columns as you want,&lt;/li&gt;
	&lt;/ul&gt;


	&lt;ul&gt;
	&lt;li&gt;&lt;em&gt;lm_center&lt;/em&gt;, middle content with resizable width and height, you can have only one per container.&lt;/li&gt;
	&lt;/ul&gt;


Here is a sample &lt;span class=&quot;caps&quot;&gt;HTML&lt;/span&gt; code to show how it works:
&lt;pre class=&quot;sunburst&quot;&gt;&lt;span class=&quot;line-numbers&quot;&gt;   1 &lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;class&lt;/span&gt;=&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;lm_container&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;    
&lt;span class=&quot;line-numbers&quot;&gt;   2 &lt;/span&gt;   &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;class&lt;/span&gt;=&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;lm_top&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;/&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;   3 &lt;/span&gt; 
&lt;span class=&quot;line-numbers&quot;&gt;   4 &lt;/span&gt;   &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;class&lt;/span&gt;=&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;lm_left&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;/&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;   5 &lt;/span&gt; 
&lt;span class=&quot;line-numbers&quot;&gt;   6 &lt;/span&gt;   &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;class&lt;/span&gt;=&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;lm_center&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;/&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;  
&lt;span class=&quot;line-numbers&quot;&gt;   7 &lt;/span&gt; 
&lt;span class=&quot;line-numbers&quot;&gt;   8 &lt;/span&gt;   &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;class&lt;/span&gt;=&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;lm_right&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;/&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;  
&lt;span class=&quot;line-numbers&quot;&gt;   9 &lt;/span&gt; 
&lt;span class=&quot;line-numbers&quot;&gt;  10 &lt;/span&gt;   &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;class&lt;/span&gt;=&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;lm_bottom&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt; 
&lt;span class=&quot;line-numbers&quot;&gt;  11 &lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;/pre&gt;

And just included layoutmanager.js in your head section
&lt;pre class=&quot;sunburst&quot;&gt;&lt;span class=&quot;line-numbers&quot;&gt;   1 &lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;script&lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;type&lt;/span&gt;=&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;text/javascript&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;src&lt;/span&gt;=&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;prototype.js&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;/&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;script&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;   2 &lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;script&lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;type&lt;/span&gt;=&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;text/javascript&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;src&lt;/span&gt;=&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;layout_manager.js&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;/&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;script&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;/pre&gt;

	&lt;p&gt;You can see it in this &lt;a href=&quot;http://blog.xilinus.com/layoutmanager/samples/simple.html&quot;&gt;simple example&lt;/a&gt;&lt;/p&gt;


Of course layout can be nested like this:
&lt;pre class=&quot;sunburst&quot;&gt;&lt;span class=&quot;line-numbers&quot;&gt;   1 &lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;class&lt;/span&gt;=&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;lm_container&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;    
&lt;span class=&quot;line-numbers&quot;&gt;   2 &lt;/span&gt;   &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;class&lt;/span&gt;=&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;lm_top&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;/&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;   3 &lt;/span&gt; 
&lt;span class=&quot;line-numbers&quot;&gt;   4 &lt;/span&gt;   &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;class&lt;/span&gt;=&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;lm_left&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;/&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;   5 &lt;/span&gt; 
&lt;span class=&quot;line-numbers&quot;&gt;   6 &lt;/span&gt;   &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;class&lt;/span&gt;=&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;lm_center&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;   7 &lt;/span&gt;     &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;class&lt;/span&gt;=&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;lm_container&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;    
&lt;span class=&quot;line-numbers&quot;&gt;   8 &lt;/span&gt;       &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;class&lt;/span&gt;=&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;lm_top&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;/&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;   9 &lt;/span&gt;       &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;class&lt;/span&gt;=&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;lm_left&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;/&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;  10 &lt;/span&gt;       &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;class&lt;/span&gt;=&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;lm_center&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;/&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;  
&lt;span class=&quot;line-numbers&quot;&gt;  11 &lt;/span&gt;       &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;class&lt;/span&gt;=&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;lm_right&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;/&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;  
&lt;span class=&quot;line-numbers&quot;&gt;  12 &lt;/span&gt;       &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;class&lt;/span&gt;=&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;lm_bottom&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt; 
&lt;span class=&quot;line-numbers&quot;&gt;  13 &lt;/span&gt;     &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;  14 &lt;/span&gt;   &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;  
&lt;span class=&quot;line-numbers&quot;&gt;  15 &lt;/span&gt; 
&lt;span class=&quot;line-numbers&quot;&gt;  16 &lt;/span&gt;   &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;class&lt;/span&gt;=&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;lm_right&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;/&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;  
&lt;span class=&quot;line-numbers&quot;&gt;  17 &lt;/span&gt; 
&lt;span class=&quot;line-numbers&quot;&gt;  18 &lt;/span&gt;   &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;class&lt;/span&gt;=&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;lm_bottom&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt; 
&lt;span class=&quot;line-numbers&quot;&gt;  19 &lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;/pre&gt;

	&lt;p&gt;You can see it in this &lt;a href=&quot;http://blog.xilinus.com/layoutmanager/samples/embed.html&quot;&gt;embedded example&lt;/a&gt;&lt;/p&gt;


	&lt;p&gt;If you work with ajax request and want to add dynamically content, you just need to call&lt;/p&gt;


&lt;pre class=&quot;sunburst&quot;&gt;&lt;span class=&quot;line-numbers&quot;&gt;   1 &lt;/span&gt; layoutManager.&lt;span class=&quot;SupportFunction&quot;&gt;add&lt;/span&gt;(&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;'&lt;/span&gt;your_element_id&lt;span class=&quot;String&quot;&gt;'&lt;/span&gt;&lt;/span&gt;);
&lt;/pre&gt;

	&lt;p&gt;because you have a global variable: &lt;em&gt;layoutManager&lt;/em&gt;. This zip file contains a sample with an Ajax Request.&lt;/p&gt;


	&lt;p&gt;So &lt;a href=&quot;http://blog.xilinus.com/layoutmanager.zip&quot;&gt;download&lt;/a&gt; it and focus on your web application :)&lt;/p&gt;
          </content>  </entry>
  <entry xml:base="http://blog.xilinus.com/">
    <author>
      <name>seb</name>
    </author>
    <id>tag:blog.xilinus.com,2007-09-30:210</id>
    <published>2007-09-30T12:34:00Z</published>
    <updated>2008-05-05T16:44:36Z</updated>
    <category term="English"/>
    <category term="Ruby"/>
    <category term="pastie"/>
    <category term="pastis"/>
    <category term="ruby"/>
    <link href="http://blog.xilinus.com/2007/9/30/a-pastis-for-pastie" rel="alternate" type="text/html"/>
    <title>A pastis for pastie</title>
<content type="html">
            &lt;p&gt;If you use &lt;a href=&quot;http://pastie.caboo.se/&quot;&gt;pastie&lt;/a&gt;  service to share code (or may be you are already addicted to it), &lt;a href=&quot;http://i.gotfresh.info&quot;&gt;Samuel Lebeau&lt;/a&gt; has released a perfect ruby gems to pastie anything in one command line.&lt;/p&gt;


	&lt;p&gt;It&#8217;s called &lt;a href=&quot;http://pastis.rubyforge.org/&quot;&gt;pastis&lt;/a&gt; (if you are French you know what a Pastis:&#8221;http://en.wikipedia.org/wiki/Pastis&#8221; is :), it&#8217;s a great alcohol from south of France).&lt;/p&gt;


	&lt;p&gt;You can get details on his &lt;a href=&quot;http://i.gotfresh.info/2007/9/12/un-pastis-oui-un-pastiche-non&quot;&gt;blog&lt;/a&gt;.&lt;/p&gt;


	&lt;p&gt;The best is you can add a command on TextMate to pastie selected text. When you workk remotely and you want to share code with co-workers it&#8217;s a great time saver.&lt;/p&gt;


	&lt;p&gt;Here is the command taken from his article:&lt;/p&gt;


&lt;pre class=&quot;sunburst&quot;&gt;&lt;span class=&quot;line-numbers&quot;&gt;   1 &lt;/span&gt; 
&lt;span class=&quot;line-numbers&quot;&gt;   2 &lt;/span&gt; &lt;span class=&quot;Comment&quot;&gt;&lt;span class=&quot;Comment&quot;&gt;#&lt;/span&gt;!/usr/bin/env ruby&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;   3 &lt;/span&gt; &lt;span class=&quot;Keyword&quot;&gt;require&lt;/span&gt; &lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;'&lt;/span&gt;rubygems&lt;span class=&quot;String&quot;&gt;'&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;   4 &lt;/span&gt; &lt;span class=&quot;Keyword&quot;&gt;require&lt;/span&gt; &lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;'&lt;/span&gt;pastis&lt;span class=&quot;String&quot;&gt;'&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;   5 &lt;/span&gt; 
&lt;span class=&quot;line-numbers&quot;&gt;   6 &lt;/span&gt; input &lt;span class=&quot;Keyword&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;Variable&quot;&gt;ENV&lt;/span&gt;[&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;'&lt;/span&gt;TM_SELECTED_TEXT&lt;span class=&quot;String&quot;&gt;'&lt;/span&gt;&lt;/span&gt;] &lt;span class=&quot;Keyword&quot;&gt;||&lt;/span&gt; &lt;span class=&quot;Support&quot;&gt;File&lt;/span&gt;.&lt;span class=&quot;Entity&quot;&gt;read&lt;/span&gt;(&lt;span class=&quot;Variable&quot;&gt;ENV&lt;/span&gt;[&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;'&lt;/span&gt;TM_FILEPATH&lt;span class=&quot;String&quot;&gt;'&lt;/span&gt;&lt;/span&gt;])
&lt;span class=&quot;line-numbers&quot;&gt;   7 &lt;/span&gt; 
&lt;span class=&quot;line-numbers&quot;&gt;   8 &lt;/span&gt; languages &lt;span class=&quot;Keyword&quot;&gt;=&lt;/span&gt; {
&lt;span class=&quot;line-numbers&quot;&gt;   9 &lt;/span&gt;   &lt;span class=&quot;StringRegexp&quot;&gt;&lt;span class=&quot;StringRegexp&quot;&gt;/&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;StringRegexp&quot;&gt;source&lt;span class=&quot;StringRegexpSpecial&quot;&gt;\.&lt;/span&gt;ruby&lt;/span&gt;&lt;span class=&quot;StringRegexp&quot;&gt;&lt;span class=&quot;StringRegexp&quot;&gt;/&lt;/span&gt;&lt;/span&gt; =&amp;gt; &lt;span class=&quot;Constant&quot;&gt;&lt;span class=&quot;Constant&quot;&gt;:&lt;/span&gt;ruby&lt;/span&gt;,
&lt;span class=&quot;line-numbers&quot;&gt;  10 &lt;/span&gt;   &lt;span class=&quot;StringRegexp&quot;&gt;&lt;span class=&quot;StringRegexp&quot;&gt;/&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;StringRegexp&quot;&gt;text&lt;span class=&quot;StringRegexpSpecial&quot;&gt;\.&lt;/span&gt;html&lt;span class=&quot;StringRegexpSpecial&quot;&gt;\.&lt;/span&gt;basic&lt;/span&gt;&lt;span class=&quot;StringRegexp&quot;&gt;&lt;span class=&quot;StringRegexp&quot;&gt;/&lt;/span&gt;&lt;/span&gt; =&amp;gt; &lt;span class=&quot;Constant&quot;&gt;&lt;span class=&quot;Constant&quot;&gt;:&lt;/span&gt;html&lt;/span&gt;,
&lt;span class=&quot;line-numbers&quot;&gt;  11 &lt;/span&gt;   &lt;span class=&quot;StringRegexp&quot;&gt;&lt;span class=&quot;StringRegexp&quot;&gt;/&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;StringRegexp&quot;&gt;text&lt;span class=&quot;StringRegexpSpecial&quot;&gt;\.&lt;/span&gt;html&lt;span class=&quot;StringRegexpSpecial&quot;&gt;\.&lt;/span&gt;ruby&lt;/span&gt;&lt;span class=&quot;StringRegexp&quot;&gt;&lt;span class=&quot;StringRegexp&quot;&gt;/&lt;/span&gt;&lt;/span&gt; =&amp;gt; &lt;span class=&quot;Constant&quot;&gt;&lt;span class=&quot;Constant&quot;&gt;:&lt;/span&gt;rhtml&lt;/span&gt;,
&lt;span class=&quot;line-numbers&quot;&gt;  12 &lt;/span&gt;   &lt;span class=&quot;StringRegexp&quot;&gt;&lt;span class=&quot;StringRegexp&quot;&gt;/&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;StringRegexp&quot;&gt;source&lt;span class=&quot;StringRegexpSpecial&quot;&gt;\.&lt;/span&gt;js&lt;/span&gt;&lt;span class=&quot;StringRegexp&quot;&gt;&lt;span class=&quot;StringRegexp&quot;&gt;/&lt;/span&gt;&lt;/span&gt; =&amp;gt; &lt;span class=&quot;Constant&quot;&gt;&lt;span class=&quot;Constant&quot;&gt;:&lt;/span&gt;javascript&lt;/span&gt;,
&lt;span class=&quot;line-numbers&quot;&gt;  13 &lt;/span&gt;   &lt;span class=&quot;StringRegexp&quot;&gt;&lt;span class=&quot;StringRegexp&quot;&gt;/&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;StringRegexp&quot;&gt;source&lt;span class=&quot;StringRegexpSpecial&quot;&gt;\.&lt;/span&gt;&lt;span class=&quot;StringRegexp&quot;&gt;&lt;span class=&quot;StringRegexp&quot;&gt;(&lt;/span&gt;c|c&lt;span class=&quot;StringRegexpSpecial&quot;&gt;\+&lt;/span&gt;&lt;span class=&quot;StringRegexpSpecial&quot;&gt;\+&lt;/span&gt;&lt;span class=&quot;StringRegexp&quot;&gt;)&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;StringRegexp&quot;&gt;&lt;span class=&quot;StringRegexp&quot;&gt;/&lt;/span&gt;&lt;/span&gt; =&amp;gt; &lt;span class=&quot;Constant&quot;&gt;&lt;span class=&quot;Constant&quot;&gt;:&lt;/span&gt;c&lt;/span&gt;,
&lt;span class=&quot;line-numbers&quot;&gt;  14 &lt;/span&gt;   &lt;span class=&quot;StringRegexp&quot;&gt;&lt;span class=&quot;StringRegexp&quot;&gt;/&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;StringRegexp&quot;&gt;source&lt;span class=&quot;StringRegexpSpecial&quot;&gt;\.&lt;/span&gt;sql&lt;/span&gt;&lt;span class=&quot;StringRegexp&quot;&gt;&lt;span class=&quot;StringRegexp&quot;&gt;/&lt;/span&gt;&lt;/span&gt; =&amp;gt; &lt;span class=&quot;Constant&quot;&gt;&lt;span class=&quot;Constant&quot;&gt;:&lt;/span&gt;sql&lt;/span&gt;,
&lt;span class=&quot;line-numbers&quot;&gt;  15 &lt;/span&gt;   &lt;span class=&quot;StringRegexp&quot;&gt;&lt;span class=&quot;StringRegexp&quot;&gt;/&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;StringRegexp&quot;&gt;source&lt;span class=&quot;StringRegexpSpecial&quot;&gt;\.&lt;/span&gt;diff&lt;/span&gt;&lt;span class=&quot;StringRegexp&quot;&gt;&lt;span class=&quot;StringRegexp&quot;&gt;/&lt;/span&gt;&lt;/span&gt; =&amp;gt; &lt;span class=&quot;Constant&quot;&gt;&lt;span class=&quot;Constant&quot;&gt;:&lt;/span&gt;diff&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;  16 &lt;/span&gt; }
&lt;span class=&quot;line-numbers&quot;&gt;  17 &lt;/span&gt; 
&lt;span class=&quot;line-numbers&quot;&gt;  18 &lt;/span&gt; language &lt;span class=&quot;Keyword&quot;&gt;=&lt;/span&gt; languages[languages.&lt;span class=&quot;Entity&quot;&gt;keys&lt;/span&gt;.&lt;span class=&quot;Entity&quot;&gt;find&lt;/span&gt; { |&lt;span class=&quot;Variable&quot;&gt;pattern&lt;/span&gt;| &lt;span class=&quot;Variable&quot;&gt;ENV&lt;/span&gt;[&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;'&lt;/span&gt;TM_SCOPE&lt;span class=&quot;String&quot;&gt;'&lt;/span&gt;&lt;/span&gt;] &lt;span class=&quot;Keyword&quot;&gt;=~&lt;/span&gt; pattern }] &lt;span class=&quot;Keyword&quot;&gt;||&lt;/span&gt; &lt;span class=&quot;Constant&quot;&gt;&lt;span class=&quot;Constant&quot;&gt;:&lt;/span&gt;plaintext&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;  19 &lt;/span&gt; 
&lt;span class=&quot;line-numbers&quot;&gt;  20 &lt;/span&gt; paste &lt;span class=&quot;Keyword&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;Support&quot;&gt;Pastis&lt;/span&gt;.&lt;span class=&quot;Entity&quot;&gt;paste&lt;/span&gt;(input, &lt;span class=&quot;Constant&quot;&gt;&lt;span class=&quot;Constant&quot;&gt;:&lt;/span&gt;language&lt;/span&gt; =&amp;gt; language)
&lt;span class=&quot;line-numbers&quot;&gt;  21 &lt;/span&gt; 
&lt;span class=&quot;line-numbers&quot;&gt;  22 &lt;/span&gt; &lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;`&lt;/span&gt;open &lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;#{&lt;/span&gt;paste&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;Entity&quot;&gt;url&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;String&quot;&gt;}&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;String&quot;&gt;`&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;  23 &lt;/span&gt; 
&lt;/pre&gt;
          </content>  </entry>
  <entry xml:base="http://blog.xilinus.com/">
    <author>
      <name>seb</name>
    </author>
    <id>tag:blog.xilinus.com,2007-09-04:141</id>
    <published>2007-09-04T20:38:00Z</published>
    <updated>2008-05-05T16:44:52Z</updated>
    <category term="English"/>
    <category term="Javascript"/>
    <link href="http://blog.xilinus.com/2007/9/4/prototype-portal-class-2" rel="alternate" type="text/html"/>
    <title>Prototype Portal Class #2</title>
<content type="html">
            &lt;p&gt;I have added a new option to prototype portal window class to be able to have multiple portals on the same page.
The new option is &lt;em&gt;accept&lt;/em&gt;, based on accept option of Droppable. So you can do something like this;&lt;/p&gt;


&lt;pre class=&quot;sunburst&quot;&gt;&lt;span class=&quot;line-numbers&quot;&gt;   1 &lt;/span&gt; &lt;span class=&quot;Storage&quot;&gt;var&lt;/span&gt;  portal &lt;span class=&quot;Keyword&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;Keyword&quot;&gt;new&lt;/span&gt; &lt;span class=&quot;JEntityNameType&quot;&gt;Xilinus.Portal&lt;/span&gt;(&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;#page2 div&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;, { accept:&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;portal1&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;});
&lt;span class=&quot;line-numbers&quot;&gt;   2 &lt;/span&gt; &lt;span class=&quot;Storage&quot;&gt;var&lt;/span&gt;  portal &lt;span class=&quot;Keyword&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;Keyword&quot;&gt;new&lt;/span&gt; &lt;span class=&quot;JEntityNameType&quot;&gt;Xilinus.Portal&lt;/span&gt;(&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;#page2 div&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;, { accept:&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;portal2&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;});
&lt;/pre&gt;
for having to portal in the same window. With a new &lt;span class=&quot;caps&quot;&gt;HTML&lt;/span&gt; file:
&lt;pre class=&quot;sunburst&quot;&gt;&lt;span class=&quot;line-numbers&quot;&gt;   1 &lt;/span&gt;   &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;id&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;span class=&quot;String&quot;&gt;page1&lt;/span&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;   2 &lt;/span&gt;       &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;id&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;span class=&quot;String&quot;&gt;widget_col_0&lt;/span&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;/&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;   3 &lt;/span&gt;       &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;id&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;span class=&quot;String&quot;&gt;widget_col_1&lt;/span&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;/&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;   4 &lt;/span&gt;       &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;id&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;span class=&quot;String&quot;&gt;widget_col_2&lt;/span&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;/&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;   5 &lt;/span&gt;  &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;       
&lt;span class=&quot;line-numbers&quot;&gt;   6 &lt;/span&gt;   &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;id&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;span class=&quot;String&quot;&gt;page2&lt;/span&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;   7 &lt;/span&gt;       &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;id&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;span class=&quot;String&quot;&gt;widget_col_3&lt;/span&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;/&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;   8 &lt;/span&gt;       &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt; &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;id&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;String&quot;&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;span class=&quot;String&quot;&gt;widget_col_4&lt;/span&gt;&lt;span class=&quot;String&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;&lt;/span&gt;/&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;   9 &lt;/span&gt;  &lt;span class=&quot;MetaTagAll&quot;&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;div&lt;/span&gt;&lt;span class=&quot;MetaTagAll&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;    
&lt;/pre&gt;

I have added a new &lt;a href=&quot;/prototype-portal/test/multi_portal.html&quot;&gt;sample file&lt;/a&gt;. you can give it a try.
I have updated &lt;a href=&quot;/prototype-portal/src/portal.js&quot;&gt;widget.js&lt;/a&gt; javascript file or check out code from svn:
&lt;code&gt;
svn co http://svn.itseb.com/public/prototype-portal/trunk prototype-portal
&lt;/code&gt;
&lt;br /&gt;&lt;br /&gt;
          </content>  </entry>
</feed>

