Entry form in home page I have an entry form in home page which the home page already using the entry object.

And I am placing the entry form in home page when i call


  {%- if entry is defined %} value="{{ entry.title }}"{% endif -%}


and this will grab the home page title, and this is not the result i want.
I need when the form submit and error return with value.

By the way, any source to learn about entry form? I don't see much tutorial about entry form. Thanks.
It sounds like you've got your home page setup as a Single. Which is a great way to go, and that's what is automatically setting the entry variable.

Here's a great walkthrough on creating an "edit entry" form...


  http://buildwithcraft.com/docs/templating/entry-form


Keep in mind, that example uses entry to represent the entry being edited. That won't work for you, however, since entry is being automatically set as your home page Single.

So when you're attempting to modify another entry, I'd recommend setting it to a different variable name. Obviously you can't have your home page and other entry both be represented by a variable named entry.

{% set entryToEdit = craft.entries.slug('my-entry-to-edit').first %}


Then entryToEdit would replace any instances of entry in the documented example.