Pages

lundi 28 février 2011

Une astuce pour Asp.net MVC 3 avec jQuery Mobile et HTML 5

Si vous utilisez HtmlHelper dans Asp.net MVC 3, vous pourriez avoir quelques difficultés à définir des propriétés personnalisées.
Par exemple, en utilisant jQuery Mobile,et j'ai eu besoin d'initialiser «data-theme» ou «data-transition» sur un ActionLink
Si vous l'écrivez avec le séparateur '-' , vous obtenez une erreur de syntaxe. Les gars de Redmond nous ont mijotés une petite surprise, il faut remplacer le '-' par des '_'comme ceci :

@Html.ActionLink("My team", "UsersList", "Home", null,
 new { data_theme = "b", data_transition = "fade",
 data_icon = "star" })

et, automatiquement, les '_' sont remplacés par des '-'
<a data-icon="star" data-theme="b" data-transition="fade"
 href="/Home/UsersList">My team</a>

Je pense que cela marche aussi pour propriétés spécifiques à Html 5

A tip about dashes for Asp.net MVC 3 in jQuery Mobile and HTML 5 context

if you use HTMLhelper in Asp.net MVC 3, you could have some difficulties to set custom properties.
For example, I'm using jQuery Mobile, and I need to set 'data-theme' or 'data-transition' on an ActionLink.
If you write it with '-' separator, you have a syntax error. The Redmond guys have cooked a small surprise for us, you should replace the '-' by '_' like this
@Html.ActionLink("My team", "UsersList", "Home", null,
 new { data_theme = "b", data_transition = "fade",
 data_icon = "star" })
and automaticly, they replace '_' by '-' in Hmtl code
<a data-icon="star" data-theme="b" data-transition="fade"
 href="/Home/UsersList">My team</a>
I think we can do the same thing for HTML 5 properties

jeudi 17 février 2011

How to use Telerik Report in asp.net MVC 3 page

I made a small video to illustrate how to use Telerik report web viewer in a asp.net MVC 3 page



You can find the sources here

Enjoy

lundi 14 février 2011

My first jQuery plugin

Version francaise

jQuery.UnlimitedScroll.js is a jQuery plugin which:
  • Creates a list item from an Ajax call
  • Add lines to the end whenever the scroll reaches the end of the page
  • Add a timer which inserts rows top of the list if new data is detected


demo :

vendredi 11 février 2011

My first jQuery Plugin

English version

jQuery.UnlimitedScroll.js est un plugin basé sur jQuery qui :
  • Créé une liste d’élément à partir d’un appel Ajax
  • Ajoute des lignes à la fin à chaque fois que le scroll arrive à la fin de la page
  • Ajoute un Timer qui insère des lignes en début de liste s’il y a nouvelles données
Petite demo :


mercredi 9 février 2011

Back to the future

 The “client/server” is back !

Answering to the following questions, I realize there is just a little more than 10 years ago :
"Should we turn the page of the client-server?"

There was a question about the aggregation of "business process on servers and let the fat clients (WinForm/Win32 apps) which "heavily" manage the users behavior &interface.

10 years later, I think that, finally, we are back to good old  Heavy Client / server technologies.

I am currently working on web applications where clients are browsers and servers are "CloudServer Windows Azure" or internal corporate servers.

The technology that I am using for the client (ASP.NET MVC 3 + jQuery),  will give me a good real "fat" client, in the sense that I had explained in 2001, with so more possibilities and much easier development and deployment.
I dabbled in a bit of Silverlight + RIA , and there seems even stronger ...

Finally, for this small post, the loop is closed, a large parabola technology.///

jeudi 3 février 2011

Back to the future

le grand retour du client-serveur

Il y a un peu plus de 10 ans, je répondais à la question :
Il y était question de défendre la centralisation des traitements "business" sur des serveurs et de laisser les clients lourds (application WinForm/Win32) gérer "lourdement" les comportements utilisateurs.

10 ans plus tard, je me dis que finalement, nous sommes revenus au bon vieux client(lourd)/serveur.
Je travaille actuellement sur des applications Web où les clients des navigateurs Internet et les serveurs sont, ou des "CloudServer Windows Azure" ou des serveurs d'entreprise.

Je trouve que la technologie que j'utilise pour le client (ASP.NET MVC 3 + jQuery) va me donner un bon vrai client lourd, dans le sens où je l'entendais en 2001, avec autant de possibilités (voir plus) et beaucoup de facilitées de développement et de déploiement.
J'ai tâté un peu de Silverlight+RIA, et là cela semble encore plus fort...

En résumé, pour ce petit post, que la boucle est bouclée, une grande parabole technologique.///