ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

SAEF: how to disable using title with same name as template is?

July 13, 2007 6:48am

Subscribe [2]
  • #1 / Jul 13, 2007 6:48am

    Riverboy

    2993 posts

    I know - i have to rename my SAEF-template name now cos everytime when user is going for that page it automaticly inserts the title to it and it is the same as my SAEF templatename is. So it redirect reader to SAEF when the entry is published and rader clicks the link to it.

    i.e my SAEF templatename is like “test” and it adds title “test” to SAEF when submittin the form. So it generates the link to “test” and here we are, again at the SAEF-page and not in that entry page what was submitted!

    So i think that only way to stop this happening is to make the SAEF templatename so weird that nobody Ever submit entry with that title (something like “ttttt”)

    Is there any other way to prevent this to happend?

    ———————————————————————————

  • #2 / Jul 13, 2007 6:53am

    Riverboy

    2993 posts

    Is there any code that i can use to automaticly add single title to entries submitted via SAEF?

    That would be nice way to handle this. Just by removing the “Title” box and leaving the rest there (body etc.)

    Cheers:
    - Tuittu

  • #3 / Jul 13, 2007 7:18am

    allgood2

    427 posts

    it sounds like your url title isn’t getting properly adjusted.  If multiple users enter in the same title, EE will typically automatically adjust the url title, so that they end up, test1, test2, test3, test4, etc.  Typically speaking, I don’t believe the post name has anything to do with where the user is redirected after posting.  The code to activate the form, is where you tell it what should happen after submission

    {exp:weblog:entry_form weblog="test-contact" return="test/contact-success" preview="test/preview-contact"}

    Is it possible your return statement is pointing back to the same form?

  • #4 / Jul 13, 2007 7:18am

    silenz

    1651 posts

    Yes there is.

    Replace the standard title-inputs in your SAEF-template with

    <input type="hidden" name="title" id="title" value="{title}" />
    <input type="hidden" name="url_title" id='url_title' value="{url_title}" />

    Goto Admin ›  Weblog Administration ›  Weblog Management
    Choose the weblog that is used for SAEF-entries, click “Edit Preferences”.
    Click “Publish Page Customization”
    There at the bottom you can set a “Default Entry Title”. Do this.
    You can also enter a “URL Title Prefix” if you want, but it’s not necessary.

    Now when someone posts with the SAEF, your “Default Entry Title” is used and a unique URL-title is automatically created.

    Hope that made sense.

  • #5 / Jul 13, 2007 7:29am

    Riverboy

    2993 posts

    it sounds like your url title isn’t getting properly adjusted.  If multiple users enter in the same title, EE will typically automatically adjust the url title, so that they end up, test1, test2, test3, test4, etc.  Typically speaking, I don’t believe the post name has anything to do with where the user is redirected after posting.  The code to activate the form, is where you tell it what should happen after submission

    {exp:weblog:entry_form weblog="test-contact" return="test/contact-success" preview="test/preview-contact"}

    Is it possible your return statement is pointing back to the same form?


    I do have that right. I ment that when user submits entry (first time) with the same title as my templatename is then the automated entrypage does not generate correct! ( link will redirect to the SAEF template).

  • #6 / Jul 13, 2007 7:38am

    Riverboy

    2993 posts

    Thanks silenz. That helped!

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases