• Hi,
    Created a contact us form on our WP web site. The action URL is to a php file that I coded – “send.php”. Send.php grabs the message and sends it to an appropriate email address. IN testing the form, I receive the message that the web page is not found.

    I am a PHP programmer. I have done this numerous times for sites that I have developed from scratch. Usually I have the form’s content sent back to the same file. However, I am not sure about being able to enter PHP code within the WP admin edit interface for pages. Perhaps I am going about this the wrong way. Advise please. I simply want the message content to be sent out in an email to the organization for whom I am developing the site. This is my first experience developing within WP. Thank you to whoever answers.

    Devorah

Viewing 5 replies - 1 through 5 (of 5 total)
  • Why not just use a contact form plugin – such as https://www.ads-software.com/extend/plugins/contact-form-7/

    Thread Starter devorash

    (@devorash)

    Thank you for responding. First I solved the problem by making sure that the file was in the directory to where the domain name was pointing and hard coding the URL where the file was.

    My preference for coding rather than using plugins is because I am developing a WP site in Hebrew. It can be much harder to get the plugin to work in Hebrew than to write the code myself.

    Moderator bcworkz

    (@bcworkz)

    It could be, but in the case of contact form 7, it already has a Hebrew domain file, so no work involved in this case.

    Even without the proper text domain, a properly internationalized plugin would make creating a domain file easier than re-coding the same from scratch.

    That said, I understand the desire to develop a custom coded solution over activating yet another plugin with extra code we don’t really need. Something to be said for lean and mean.

    Thread Starter devorash

    (@devorash)

    Thank you for bringing that contact form 7 has a Hebrew domain file. With the contact form though, coding the action of a contact form is very simple, and I can make sure the action does exactly what I want it to do. One of the difficulties with Hebrew, exactly the same for Arabic, is the “right to left” of the languages. It is certainly worth while to check out whether there are already Hebrew versions of the plugins. But there are times when this challenge can take much energy to solve.

    Moderator bcworkz

    (@bcworkz)

    I’m sure it can. The WordPress team has identified proper internationalization (i18n) of themes and plugins as an important concept to promote to developers. When done properly, translating to a rtl language should be seamless. There are certainly a few quirks developers need to be aware of for rtl languages to work correctly, but it’s nothing that difficult.

    The biggest challenge is getting developers to realize i18n is an important issue. Once over that hurdle, properly setting up text strings to be easily translated is another significant issue. But once i18n is properly implemented, the actual translation into another language should be fairly straight forward.

    Unfortunately, we are a long way from universal i18n. I thought you might like to know that efforts are being made, even though you may not see significant results in published themes and plugins for some time.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Upload PHP file that posts messafe from form’ is closed to new replies.