Results 1 to 4 of 4

Thread: Contact Agent Form: Subject line

  1. #1
    Join Date
    Feb 2006
    Posts
    11

    Default Contact Agent Form: Subject line

    Does anyone know how I can prevent people from being able to change the subject line in the form that is generated (i.e. In Reference to Listing #21) in the Contact Agent form?

    I have it setup so that I get copied on all enquires, but sometimes people change the automatic subject line ex. In Reference to Listing #21 to something else which prevents me from knowing what listing they are inquiring about.

    Thanks in advance.

  2. #2
    Join Date
    Apr 2006
    Location
    Argentina
    Posts
    13

    Thumbs up Re: Contact Agent Form: Subject line

    yeah! easy you must add READONLY to the input tag:

    find in \include\ the file contact.inc.php
    open with your text editor and find this line:
    <input id="subject" name="subject" value="'.$subject.'" type="text" size="50">
    and replace it with:
    <input id="subject" name="subject" value="'.$subject.'" type="text" size="50" readonly>

    hope it helps

  3. #3
    Join Date
    Apr 2006
    Posts
    4

    Default Re: Contact Agent Form: Subject line

    if i wanted to add some default in the message box etc

    Name :
    Tel :
    Nationality:

    etc.. where in the php file can i add this default comments so that it shows up in the contact message box?

  4. #4
    Join Date
    Jun 2006
    Posts
    1

    Default Re: Contact Agent Form: Subject line

    A word of CAUTION when adding "readonly" to the subject field in contact.inc.php

    Although this will prevent users from changing the predefined subject text, which is a useful thing, it can have adverse effects elsewhere.

    I tried the "readonly" directive and found that when you click "Contact Agent" from the agents bio page, the popup window displays the contact form without any subject as it's not related to a specific listing. When using the "readonly" directive, the user can not type text into the subject field. This is an issue because be default the contact page will not send a message without a subject. The user is now no-longer able to use this contact form, as there is no default text and new text cannot be typed so the page will constantly refresh asking that a subject be present.

    A work around would be to make sure that there is always a default text string for the subject field, however, I found it just easier to not use the "readonly" directive here, as users rarely change the subject line if it's prefilled for them.

    I hope this saves some of you from wasting time trying to figure out why the contact form doesn't work in some situations.

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •