Slices & Articles Get by the slice or add to your own ebook
|Anne Ginger||Karnac Books||ePub|
The purpose of psychotherapy is not obviously to change the events themselves, but rather to change one’s perspective on them. It does not transform objectively either the past, or even the present, but makes a subjective “re-vision” of both possible. One then does not see the glass as being half-empty anymore, but rather half-full. (cf. “reframing” in NLP, “cognitive restructu ring” in TCC, the life scenario in TA, the “counter-enhancements” in motivational psychology, etc.).
Let us now suggest you go for a short walk, randomly, in the garden of your daily life, with a new way of looking at everything, without any a priori, in order to discover new facets of our familiar settings, or of some of our preconceptions—that are sometimes “introjected” without further questioning (S. Ginger, 2006a).
In order to look after one’s garden, one should undoubtedly uproot the weeds and get rid of the rocks and stones invading the flower-beds.
The problem is that those weeds keep on growing back up tirelessly. However hard one tries to remove the stones, there are always some left: the more we dig, the more there seem to be, the soil is chock full of them.See All Chapters
|Sean M. Burke||O'Reilly Media||ePub|
Much of the interesting data of the Web is accessible only through HTML forms. This chapter shows you how to write programs to submit form data and get the resulting page. In covering this unavoidably complex topic, we consider packing form data into GET and POST requests, how each type of HTML form element produces form data, and how to automate the process of submitting form data and processing the responses.
The basic model for the Web is that the typical item is a "document" with a known URL, and when you want to access it (whether it's the Rhoda episode guide, or the front page of today's Boston Globe), you just get it, no questions asked. Even when there are cookies or HTTP authentication involved, these are basically just addenda to the process of requesting the known URL from the appropriate server. But some web resources require parameters beyond just their URL, parameters that are generally fed in by the user through HTML forms, and that the browser then sends either as dynamic parts of a URL (in the case of a GET request) or as content of a POST request.See All Chapters
|Grovier, Kelly||Carcanet Press Ltd.|
|Cuno Pfister||Maker Media, Inc||ePub|
Moreover, the main message of this book is that HTTP is not black magic and requires neither high-powered computers nor huge, complex web frameworks. Using the
To send a sample to Pachube, you can use the code in Example8-1.
This example starts in the same way as
|Michael Snoyman||O'Reilly Media||ePub|
If we look at Yesod as a model-view-controller framework, routing and handlers make up the controller. For contrast, let’s describe two other routing approaches used in other web development environments:
Dispatch based on filename. This is how PHP and ASP work, for example.
Have a centralized routing function that parses routes based on regular expressions. Django and Rails follow this approach.
Yesod is closer in principle to the latter technique. Even so, there are significant differences. Instead of using regular expressions, Yesod matches on pieces of a route. Instead of having a one-way route-to-handler mapping, Yesod has an intermediate data type (called the route or type-safe URL data type) and creates two-way conversion functions.
Coding this more advanced system manually is tedious and error prone. Therefore, Yesod defines a domain-specific language (DSL) for specifying routes, and provides Template Haskell functions to convert this DSL to Haskell code. This chapter will explain the syntax of the routing declarations, give you a glimpse of what code is generated for you, and explain the interaction between routing and handler functions.See All Chapters
Business & Economics