- Posts: 21
COMMUNITY FORUM
Fill automatically "E-mail to" in k2.
- Leonardo L.
-
Topic Author
- Offline
- Junior Member
Is it possibile to change the parameter: "EMAIL_TO", through the e-mail link that appears when I'm seeing an article?
I mean that I would like to fill automatically the "email to" field with an existent email address, to use it to ask information about an article. I'm not good in php to do it by myself.
I'm attach an image to explain better what I mean.
Thanks a lot.
Please Log in or Create an account to join the conversation.
- BBC
-
- Offline
- Platinum Member
- Posts: 663
You see, that is not stupid idea. I am using Aiocontactsafe extension and plugin for that.
I vill test something later and see if it is difficult.
Please Log in or Create an account to join the conversation.
- Leonardo L.
-
Topic Author
- Offline
- Junior Member
- Posts: 21
hello, thansk to reply!
Yes exactly, I would like to change it to an option to contact the author of item...because it's more useful, imho, contact the author instead a "friend" (and anyway I need this option! :) )
Thanks for your hep.
Ps.If is not possible I'll send you a pm to know how to do it with aiocontactsafe.
Please Log in or Create an account to join the conversation.
- BBC
-
- Offline
- Platinum Member
- Posts: 663
I am not sure for K2 Item title, or URL of Item. Have not tested all. It is working OK if you show whole AIO form in Item.
But this tweak from your question is more interessting.
Please Log in or Create an account to join the conversation.
- BBC
-
- Offline
- Platinum Member
- Posts: 663
Please Log in or Create an account to join the conversation.
- BBC
-
- Offline
- Platinum Member
- Posts: 663
Please Log in or Create an account to join the conversation.
- BBC
-
- Offline
- Platinum Member
- Posts: 663
Please Log in or Create an account to join the conversation.
- BBC
-
- Offline
- Platinum Member
- Posts: 663
<input type="text" name="mailto" class="inputbox" size="25" value="This email address is being protected from spambots. You need JavaScript enabled to view it." readonly="readonly" style="visibility:hidden;display:none"/>
And comment or delete:
<?php echo JText::_('EMAIL_TO'); ?>:
Please Log in or Create an account to join the conversation.
- BBC
-
- Offline
- Platinum Member
- Posts: 663
It is working either way.
Please Log in or Create an account to join the conversation.
- Leonardo L.
-
Topic Author
- Offline
- Junior Member
- Posts: 21
I used your solution and it works, it loads automatically the email recipient! :)
Anyway I receive an error in "EMAIL_NOT_SENT" where I get "this email was not sent correctly".
Should be a problem of the code?
thanks again!
Please Log in or Create an account to join the conversation.
- BBC
-
- Offline
- Platinum Member
- Posts: 663
Please Log in or Create an account to join the conversation.
- Leonardo L.
-
Topic Author
- Offline
- Junior Member
- Posts: 21
Please Log in or Create an account to join the conversation.
- BBC
-
- Offline
- Platinum Member
- Posts: 663
I received 2 mails.
There is another problem. It needs message text field. But it is maybe easy to copy that piece of code from contact extension.
Please Log in or Create an account to join the conversation.
- Leonardo L.
-
Topic Author
- Offline
- Junior Member
- Posts: 21
And yes, if I would like to add a field text and a field phone, for example, what should I modify?
Thanks a lot for your support.
Please Log in or Create an account to join the conversation.
- BBC
-
- Offline
- Platinum Member
- Posts: 663
It never send at first click.
Please Log in or Create an account to join the conversation.
- BBC
-
- Offline
- Platinum Member
- Posts: 663
But why it wont send at first click.
Please Log in or Create an account to join the conversation.
- BBC
-
- Offline
- Platinum Member
- Posts: 663
Strange.
Please Log in or Create an account to join the conversation.
- BBC
-
- Offline
- Platinum Member
- Posts: 663
Not specified what adress of those two.
Please Log in or Create an account to join the conversation.
- BBC
-
- Offline
- Platinum Member
- Posts: 663
It raises questions. How can we check if someone is missusing this option ?
Not all has access to server logs. And you can get easy in spam black lists over the world. Then it is very diffcult to be removed from black lists.
Please Log in or Create an account to join the conversation.
- Leonardo L.
-
Topic Author
- Offline
- Junior Member
- Posts: 21
Please Log in or Create an account to join the conversation.