ivandoric / Making-Websites-With-October-CMS

This is a repository for video tutorial series about making websites with October CMS. You can check out the series here: https://goo.gl/eW32CM
160 stars 52 forks source link

Failure to send data from front-end form in octobercms #21

Open gerbert92 opened 5 years ago

gerbert92 commented 5 years ago

Plz after following all the procedures in sending data from front-end the data is not sent. It is only appended in a url like:

http://localhost/diptech.co.tz/?fname=Gibson&lname=Willy&testimonial=The+Mobile+application+you+developed+for+us+helps+us+to+effectively+communicate+with+our+customers.

Would kindly appreciate any help form you..

ivandoric commented 5 years ago

Hi,

please provide more information if you want to get help, like what are you trying to do, what episode of the tutorial is this in relation to, show me your code, etc.

From this I can only conclude that your data is actually sent, using GET method, that is why you are getting it appended to URL.

gerbert92 commented 5 years ago

Am having a testimonial component within a Menu Plugin trying to send a testimonial ( with fname,lname and testimonial) from the front-end. Here are my component default.htm,Component (Testimonials.php), Model(Testimonial) and Plugin.php.

Maybe I didn't define my single table relationship in my Model as required. Please help me to understand If there is a need to define a relationship in my model if I just want to send data to a single table (with no relationship).

On Sat, Dec 22, 2018 at 11:52 AM Ivan Dorić notifications@github.com wrote:

Hi,

please provide more information if you want to get help, like what are you trying to do, what episode of the tutorial is this in relation to, show me your code, etc.

From this I can only conclude that your data is actually sent, using GET method, that is why you are getting it appended to URL.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/ivandoric/Making-Websites-With-October-CMS/issues/21#issuecomment-449555976, or mute the thread https://github.com/notifications/unsubscribe-auth/AlUUJutldtajv2cm4kAKm5-UC86xQ7Xjks5u7fK9gaJpZM4ZeFZS .

gerbert92 commented 5 years ago

The basic idea is I want a user to send a testimony from my website and get them saved to my database. Actually, I haven't defined a relationship in my Model since I don't know how to define a relationship when I have a single model. Your help will be much appreciated.

On Sat, Dec 22, 2018 at 12:05 PM Gerald Hubert gerbertleo@gmail.com wrote:

Am having a testimonial component within a Menu Plugin trying to send a testimonial ( with fname,lname and testimonial) from the front-end. Here are my component default.htm,Component (Testimonials.php), Model(Testimonial) and Plugin.php.

Maybe I didn't define my single table relationship in my Model as required. Please help me to understand If there is a need to define a relationship in my model if I just want to send data to a single table (with no relationship).

On Sat, Dec 22, 2018 at 11:52 AM Ivan Dorić notifications@github.com wrote:

Hi,

please provide more information if you want to get help, like what are you trying to do, what episode of the tutorial is this in relation to, show me your code, etc.

From this I can only conclude that your data is actually sent, using GET method, that is why you are getting it appended to URL.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/ivandoric/Making-Websites-With-October-CMS/issues/21#issuecomment-449555976, or mute the thread https://github.com/notifications/unsubscribe-auth/AlUUJutldtajv2cm4kAKm5-UC86xQ7Xjks5u7fK9gaJpZM4ZeFZS .