magento : Your password reset link has expired - magento-1.9

I have an issue when I click on the reset password link url :
I have four website in one magento platform like : domain.com, domain.com/us/ domain.com/it/ domain.com/ca/
On my main site (domain.com) when I click on forgot password I get the email with reset password link . When I click on the reset password link I am successfully redirected to reset password url .
But when I follow same process with my other sites like domain.com/us , I am getting the forgot password email but when I click on the reset password link I am redirect on the Forgot password link (domain.com/us/customer/account/forgotpassword/) instead of reset password link and I am getting an error message stating "Your password reset link has expired".

Update app/design/frontend/your_theme_package/your_theme_name/layout/customer.xml file for your theme as shown in diff below (your_theme_package/your_theme_name is the name of your theme):
* Find <customer_account_resetpassword translate="label"> replaced by <customer_account_changeforgotten translate="label">
<label>Reset a Password</label>
<reference name="content">
* find <block type="customer/account_resetpassword" name="resetPassword" template="customer/form/resetforgottenpassword.phtml"/>
replaced by <block type="customer/account_changeforgotten" name="changeForgottenPassword" template="customer/form/resetforgottenpassword.phtml"/>
</reference>
* find </customer_account_resetpassword>
replaced </customer_account_changeforgotten>

Related

how to change phpmyadmin titlebar and show only domain?

In default PHPMyAdmin showing <domain> | <Table> <column> PHPMyAdmin 4.9.5deb on title bar in my browser,
I need to remove those things and show only domain www.example.com or index.php
I'm referring to this document: https://web.njit.edu/mysql/phpMyAdmin/doc/html/config.html#cfg_Servers_verbose
this one is my first Stackoverflow question, please guide me for this
Go to Setting/Features/Page titles and change the settings.
Or, alternativly, add this to config.inc.php:
$cfg['TitleDefault'] = "DEFAULT TITLE1";
$cfg['TitleTable'] = "DEFAULT TITLE2";
$cfg['TitleDatabase'] = "DEFAULT TITLE3";
$cfg['TitleServer'] = "DEFAULT TITLE4";
(and, of course, change the DEFAULT TITLEx to the thing you want to show).
Changing all default titles to "#HTTP_HOST#" will only show the hostname, in my case localhost.
And, finally, a link to the docs: https://docs.phpmyadmin.net/en/latest/config.html#page-titles

form embed on email (with default values)

I am trying to embed a form on a email with all the fields (inputs and textarea) filled. The mail seems good, but I find two problems:
1) The form submits clicking every input... Is it be embedded?
2) The main problem is that when I send the email the form tag (on hotmail) and the attribute "name" of the inputs and textarea, disappear (hotmail and ¿thunderbird?).
I am using Contact Form-7 (the wordpress plugin), and I configure it like this:
<form action="http://panel.1clicklawyers.net/userQuestions" method="POST">
De: <input value="[your-name]" name="user_name" style="border:0px; width:auto;"><input value="[your-email]" name="user_mail" style="border:0px; width:auto;">
Asunto: <input value="[your-subject]" name="subject" style="border:0px; width:auto;">
<h2>Cuerpo del mensaje:</h2>
<textarea value="[your-message]" name="question" style="border:0px">[your-message]</textarea>
<input type="submit" value="Enviar" style="background:#D8531D; color:#333; pading:15px;">
</form>
--
Este e-mail se ha enviado vía formulario de contacto desde 1clicklawyers http://www.1clicklawyers.net
On the side of the receiver everything seems good, but the names of the inputs and textarea disappear, and on the server side if I make:
var_dump($this->input->post()); //Using codeigniter.
var_dump($_POST); //I am not sure if this could work.
The result is bool(false).
MORE TESTINGS
I was making more tests, using different accounts and clients. The result is the next:
Hotmail: The form tag disappear (and too the attribute name of inputs and text area).
Hotmail on the android outlook client: When I click on the submit input, it opens a tab of the browser, but it sends me to the url base (panel.1clicklawyers.net) without the last segment (userQuestions).
ThunderBird: Using a 1clicklawyers.net account. Clicking on the submit it opens a new tab on the browser, but the var_dump shows "bool(false)". Could it be because thunderbird removes the attribute name??
Web Mailer: Using the same account of 1clicklawyers.net, but on the web (using the 1&1 webmailer). I have no problem... I click on the submit and everything works fine.
Gmail:No problem. A confirm window ask you for permissions to send info, accepting I can see how the var_dump is working fine. OK.
Is there any way to make it works on all clients??
Possible solution
One thing that maybe can solve this is use a link with the parameters, something like:
Send
But the get method has a limit of chars, and the message could be too much long for it.
Any other solution??
Thanks!!
Its not possible to make a form within an email. Email clients dont support this feature.
Most email clients takes it as phishing so they dont support it.
You can see a list here of who support it. link

send a parameter that execute a cmd line with

hi all i have a form with one parameter "Draft" , and i want to send draft with send button to execute a function in the command line.
C:\PDF>pdfprint.exe -printer "docPrint" -firstpage 1 -lastpage 1 -wtext "Draft"
-wo 100 -wa 50 -wf "Arial" C:\readme.pdf
the html form code
<FORM
ACTION="..........."
onReset="return confirm('Do you really want to reset the form?')" >
<INPUT TYPE=TEXT NAME="query">
<INPUT TYPE=SUBMIT>
<INPUT TYPE=RESET VALUE="Start All Over">
</FORM>
what should i insert in the action ?
Once that HTML is a part of regular web page, than you can't do that with only HTML/JS. You will also need some server side language which will accept browser's request, read posted form and do something based on received values (in your case - run printer from cmd line). Take a look at PHP, asp.net or anything else you like (besides, it will be printed on server, not on client machine. JS does not allow you to control what is happening on client PC outside your page). User may decide to print your page, and in that case you can add special style sheet link:
<link rel="stylesheet" type="text/css" media="print" href="/css/print_message.css" />
For instance, in my project I have this line when I do not want content on some page to be available for printing (print_message.css will hide all content and show a message about printing is restricted).

Primefaces password feedback text localization

I'm having a problem translating the ff text from primefaces's password field:
"Please enter a password", "Weak", "Good", "Strong", etc.
Any idea how to override the default translation values? I tried searching the primefaces jar but can't see them in Messages.properties file.
Thanks,
czetsuya
Look at the the showcase:
http://www.primefaces.org/showcase/ui/password.jsf
Here is the turkish example copied from there:
<p:password id="turkishFeedback" value="#{passwordBean.password3}" feedback="true"
promptLabel="Lütfen şifre giriniz"
weakLabel="Zayıf"
goodLabel="Orta seviye"
strongLabel="Güçlü" />

Input Type URL - Says "Please enter a URL" if HTTP is not included

I've been working on a form and run into a snag. I've been using input type="url" so that iPad and iPhones etc all pull up the correct keyboard - and to try and follow the new standards.
I've run into an issue though. On a form where the web address is not required - if a user types in www.theiraddress.com most browsers outline it in red/yellow to notify the user they need to enter "http://" before it.
I've used input:invalid css to remove that outline.
However now when the user submits the form, the browser throws an error saying "Please enter a URL".
The field isn't required - I just wanted to make it easier for folks to enter their addresses - but still display the right keyboards on mobile devices etc.
Is there a way to remove this annoying tooltip that prevents users from submitting the form?
You can add a novalidate attribute to the form element. Fx:
<form method="post" action="/foo" novalidate>...</form>
See https://www.w3.org/TR/html5/sec-forms.html#element-attrdef-form-novalidate
Taken from this answer:
https://stackoverflow.com/a/3094185/1497627
As far as I know, according to the standard, the protocol is required (Url input field implementation state). You could alternatively use a regexp to validate that field such as /^(?:(http|https|ftp):\/\/)?(?:[\w-]+\.)+[a-z]{2,6}(\/)?/i
According to the bottom of the referenced page (http://www.wufoo.com/html5/types/3-url.html) you can use the text input type and the inputmode attribute (http://www.wufoo.com/html5/attributes/23-inputmode.html) to get to the keyboard on mobile devices without being fussy about the text field.
If I understand correctly, you want that when a user enters the url without http://, automatically adds http:// front of the url so as not to report error
Try this:
//PUT THIS IN HEAD
function check_url(){
//Get input value
var elem = document.getElementById("url_input");
var input_value = elem.value;
//Set input value to lower case so HTTP or HtTp become http
input_value = input_value.toLowerCase();
//Check if string starts with http:// or https://
var regExr = /^(http:|https:)\/\/.*$/m;
//Test expression
var result = regExr.test(input_value);
//If http:// or https:// is not present add http:// before user input
if (!result){
var new_value = "http://"+input_value;
elem.value=new_value;
}
}
Try to input www.myurl.com<br />
Try to input http://www.myurl.com<br />
Try to input https://www.myurl.com<br /><br />
URL INPUT:<br />
<input type="url" id="url_input" name="url_input" /><br /><br />
<input type="button" value="Submit!!" onclick="check_url()" />
Replace www.myurl.com with http://www.myurl.com
Nothing happens if http://www.myurl.com or https://www.myurl.com
Note: http://www.myurl.com automatically will be converted in https://www.myurl.com by browser if myurl.com domain support SSL(https:)
Working demo: http://jsfiddle.net/Yeti82/281a4hs8/