It's just like html.

In html you'd write

<form>
  <label>Username</label>
  <input name=“username” type=“text" />
  <label>Password</label>
  <input name=“password” type=“password />
</form>

In haml you'd write

%form
  %label Username
  %input(name: "username", type: "text")
  %label Password
  %input(name: "password", type: "password")

The translation is straight-forward and mechanistic. The advantages of
using haml is that in those attributes spots, you can use real ruby hashes,
etc...

Hope this helps!

On Mon, Dec 8, 2014 at 2:22 PM, BeeRich33 <[email protected]> wrote:

> Specifically I'm looking for a quick reference for form element input.
> The more complex elements like textareas, radio buttons and check boxes,
> pulldowns, multiple pulldowns.
>
> If there is nothing really different, I'm sure I could figure it out.  I
> just thought somewhere there would be some quick reference.  I don't trust
> a lot of translators that I find.
>
> On Monday, December 8, 2014 1:41:59 PM UTC-5, Norman Clarke wrote:
>>
>> I'm sorry I perceived your question as coming from a newbie. Given your
>> degree of experience with HTML I guess don't really understand what you're
>> looking for. Perhaps you are thinking that Haml does something different
>> from what it does.
>>
>> Haml is just a different way to write HTML. There's nothing special about
>> form tags in Haml; the same docs which show you how to write <div> and <p>
>> tags in Haml would apply to writing <form> or <input> tags. For that reason
>> there's no documentation that specifically describe how to work with forms.
>>
>> As I mentioned earlier, all the docs on Haml can be found on the
>> haml.info site. If you could show me an example of the kind of
>> documentation you'd like to see added we'd be happy to consider it.
>>
>> Regards,
>>
>> Norman
>>
>> z
>>
>> On Mon Dec 08 2014 at 3:24:26 PM BeeRich33 <[email protected]> wrote:
>>
>>> No.  I've been web developing for decades now.  Forms are something I
>>> have automated in some time.  I've recently taken up HAML and I can't find
>>> any reference to form syntax anywhere.
>>>
>>> I did ask a question in the group.  They pointed me to web development.
>>>
>>> I am specifically looking for any reference to tags that generate
>>> forms.  On their website, which I have checked many times, I have found
>>> nothing.
>>>
>>> Cheating means going off someone else's insight into tags that I can't
>>> find published anywhere.  Second, I've used these tools for various
>>> applications and they rarely work well, nor explain what's going on.
>>>
>>> Please note that when people are asking for some guidance on forms using
>>> haml, it's just that.  We have both asked for some links to where these
>>> tags are published so we can read up on them.
>>>
>>>
>>>
>>>
>>> On Monday, December 8, 2014 11:01:37 AM UTC-5, Norman Clarke wrote:
>>>
>>>> It sounds more like you're asking for help with web development in
>>>> general, rather than Haml. I think the best way to proceed would be to be
>>>> sure you have the knowledge of how to create a web form that does what you
>>>> want using normal HTML, and then try replacing the HTML part with Haml. If
>>>> you get stuck at that point, then feel free to ask questions in the group.
>>>>
>>>> If you want to jump right into Haml, though, the haml.info
>>>> <http://www.google.com/url?q=http%3A%2F%2Fhaml.info&sa=D&sntz=1&usg=AFQjCNH-uy7EdrM4XUicd009BNI6BYVzbw>
>>>> website has links to resources on how to work with Haml, as well as all of
>>>> its documentation.
>>>>
>>>> You can also "cheat" a bit when learning Haml by writing some HTML, and
>>>> then converting it to Haml to see how to translate it:
>>>>
>>>> http://htmltohaml.com/
>>>>
>>>> Regards,
>>>>
>>>> Norman
>>>>
>>>> On Mon Dec 08 2014 at 12:53:51 PM BeeRich33 <[email protected]> wrote:
>>>>
>>> I too am looking for some guidance.  I can't find anything online.
>>>>>
>>>>>
>>>>> On Monday, December 8, 2014 6:42:07 AM UTC-5, praveen kumar wrote:
>>>>>>
>>>>>> Hi all,
>>>>>>            How to create a simple login form using haml language?
>>>>>>
>>>>>> Sample:
>>>>>>
>>>>>> http://ui-cloud.com/res/designmoo/Clean_Simple_Login_Form/pr
>>>>>> eviews/loginform-270x300.jpg
>>>>>>
>>>>>>
>>>>>> Thanks,
>>>>>> Praveen RPK
>>>>>>
>>>>>  --
>>>>> You received this message because you are subscribed to the Google
>>>>> Groups "Haml" group.
>>>>>
>>>> To unsubscribe from this group and stop receiving emails from it, send
>>>>> an email to [email protected].
>>>>> To post to this group, send email to [email protected].
>>>>
>>>>
>>>>> Visit this group at http://groups.google.com/group/haml.
>>>>> For more options, visit https://groups.google.com/d/optout.
>>>>>
>>>>  --
> You received this message because you are subscribed to the Google Groups
> "Haml" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To post to this group, send email to [email protected].
> Visit this group at http://groups.google.com/group/haml.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Haml" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/haml.
For more options, visit https://groups.google.com/d/optout.

Reply via email to